Skip to content

Commit ce26ad7

Browse files
author
Akash Satheesan
committed
refactor(lib/vscode): move commit to global constant
1 parent 8cb55b5 commit ce26ad7

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/vscode/src/vs/server/node/server.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ import { REMOTE_TERMINAL_CHANNEL_NAME } from 'vs/workbench/contrib/terminal/comm
5858
import { REMOTE_FILE_SYSTEM_CHANNEL_NAME } from 'vs/workbench/services/remote/common/remoteAgentFileSystemChannel';
5959
import { RemoteExtensionLogFileName } from 'vs/workbench/services/remote/common/remoteAgentService';
6060

61+
const commit = product.commit || 'development';
62+
6163
export class Vscode {
6264
public readonly _onDidClientConnect = new Emitter<ClientConnectionEvent>();
6365
public readonly onDidClientConnect = this._onDidClientConnect.event;
@@ -109,7 +111,7 @@ export class Vscode {
109111
remoteUserDataUri: transformer.transformOutgoing(URI.file(environment.userDataPath)),
110112
productConfiguration: product,
111113
nlsConfiguration: await getNlsConfiguration(environment.args.locale || await getLocaleFromConfig(environment.userDataPath), environment.userDataPath),
112-
commit: product.commit || 'development',
114+
commit,
113115
};
114116
}
115117

@@ -255,7 +257,6 @@ export class Vscode {
255257
instantiationService.invokeFunction((accessor) => {
256258
instantiationService.createInstance(LogsDataCleaner);
257259

258-
const commit = typeof product.commit === 'string' ? product.commit : 'unknown';
259260
let telemetryService: ITelemetryService;
260261
if (!environmentService.disableTelemetry) {
261262
telemetryService = new TelemetryService({

0 commit comments

Comments
 (0)