From 112736aea70a5241fcf638f4f6244cbeb2b32fdd Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Thu, 4 Aug 2022 22:23:12 +0430 Subject: updates --- .mongoshrc.js | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) (limited to '.mongoshrc.js') diff --git a/.mongoshrc.js b/.mongoshrc.js index 493e925..9533ee8 100644 --- a/.mongoshrc.js +++ b/.mongoshrc.js @@ -1,12 +1,26 @@ +"use strict"; + +config.set("editor", "vim"); +config.set("enableTelemetry", false); +config.set("inspectDepth", 8); +config.set("historyLength", 5000); + { const hostnameSymbol = Symbol("hostname"); prompt = () => { if (!db[hostnameSymbol]) db[hostnameSymbol] = db.serverStatus().host; - return `\x1b[38;5;22m${db.getName()}\x1b[38;5;24m@${ + return `\x1b[38;5;63m${ISODate().toLocaleTimeString()} \x1b[38;5;24m${db.getName()}\x1b[38;5;24m@${ db[hostnameSymbol] - }\x1b[38;5;22m:Uptime:${db.serverStatus().uptime}:Documents:${ + }\x1b[38;5;22m Uptime:${db.serverStatus().uptime}\x1b[38;5;26m Documents:${ db.stats().objects - } >>>\x1b[0m`; - ; + }\x1b[38;5;109m V:${db.version()} \n \x1b[38;5;30m>>>\x1b[0m`; }; } + +function get_mangas() { + return db.mangas.find(); +} + +function get_animes() { + return db.animes.find(); +} -- cgit v1.2.3