diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2019-02-03 01:33:34 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2019-02-03 01:33:34 +0900 |
| commit | a3e37294e5d4f381e7dfaefae823a7e3ef0a4203 (patch) | |
| tree | 789f2f0a38c33062534a13e3bda756136bd5fd99 /src/index.ts | |
| parent | Refactoring of logger (diff) | |
| download | misskey-a3e37294e5d4f381e7dfaefae823a7e3ef0a4203.tar.gz misskey-a3e37294e5d4f381e7dfaefae823a7e3ef0a4203.tar.bz2 misskey-a3e37294e5d4f381e7dfaefae823a7e3ef0a4203.zip | |
Better logs
Diffstat (limited to 'src/index.ts')
| -rw-r--r-- | src/index.ts | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/index.ts b/src/index.ts index 1c54246c41..8ec8a2744b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -72,6 +72,9 @@ function main() { async function masterMain() { let config: Config; + bootLogger.info('Welcome to Misskey!'); + bootLogger.info(`Misskey v${pkg.version}`, true); + try { // initialize app config = await init(); @@ -133,8 +136,8 @@ function showEnvironment(): void { logger.info(typeof env == 'undefined' ? 'NODE_ENV is not set' : `NODE_ENV: ${env}`); if (env !== 'production') { - logger.warn('The environment is not in production mode'); - logger.warn('Do not use for production purpose'); + logger.warn('The environment is not in production mode.'); + logger.warn('Do not use for production purpose!', true); } logger.info(`You ${isRoot() ? '' : 'do not '}have root privileges`); @@ -144,8 +147,7 @@ function showEnvironment(): void { * Init app */ async function init(): Promise<Config> { - bootLogger.info('Welcome to Misskey!'); - bootLogger.info(`<<< Misskey v${pkg.version} >>>`); + showEnvironment(); const nodejsLogger = bootLogger.createSubLogger('nodejs'); @@ -157,7 +159,6 @@ async function init(): Promise<Config> { } await showMachine(); - showEnvironment(); const configLogger = bootLogger.createSubLogger('config'); let config; |