diff --git a/src/vs/code/electron-main/main.ts b/src/vs/code/electron-main/main.ts index 8299843bf7dc0a7fe19c74fc31e42cf0f8c31e3f..ee22837dd1364dc88d88df5437fcf4d2edabc458 100644 --- a/src/vs/code/electron-main/main.ts +++ b/src/vs/code/electron-main/main.ts @@ -127,13 +127,16 @@ function setupIPC(accessor: ServicesAccessor): TPromise { function setup(retry: boolean): TPromise { return serve(environmentService.mainIPCHandle).then(server => { - if (platform.isMacintosh) { - app.dock.show(); // dock might be hidden at this case due to a retry - } // Print --status usage info if (environmentService.args.status) { logService.warn('Warning: The --status argument can only be used if Code is already running. Please run it again after Code has started.'); + throw new ExpectedError('Terminating...'); + } + + // dock might be hidden at this case due to a retry + if (platform.isMacintosh) { + app.dock.show(); } // Set the VSCODE_PID variable here when we are sure we are the first