From b158af745e55e0c525e329a3bc39bd953b4b0c41 Mon Sep 17 00:00:00 2001 From: syuilo Date: Thu, 26 Jan 2017 12:12:37 +0900 Subject: [PATCH] Refactor: Add @otofune's note https://github.com/syuilo/misskey/pull/75#issue-203103115 --- src/utils/dependencyInfo.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/utils/dependencyInfo.ts b/src/utils/dependencyInfo.ts index c7c1441ec1..8c3014d302 100644 --- a/src/utils/dependencyInfo.ts +++ b/src/utils/dependencyInfo.ts @@ -16,6 +16,8 @@ export default class { show(serviceName: string, command: string, transform: (x: string) => RegExpMatchArray): void { try { + // ステータス0以外のときにexecSyncはstderrをコンソール上に出力してしまうので + // プロセスからのstderrをすべて無視するように stdio オプションをセット const x = execSync(command, { stdio: ['pipe', 'pipe', 'ignore'] }); const ver = transform(x.toString()); if (ver != null) {