Skip to content

Commit

Permalink
Signal insiders version in product name
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanp413 committed Oct 6, 2021
1 parent d433013 commit 2d181c1
Showing 1 changed file with 18 additions and 14 deletions.
32 changes: 18 additions & 14 deletions src/vs/gitpod/browser/workbench/workbench.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,20 @@ interface ICredential {
password: string;
}

interface WorkspaceInfoResponse {
workspaceId: string
instanceId: string
checkoutLocation: string
workspaceLocationFile?: string
workspaceLocationFolder?: string
userHome: string
gitpodHost: string
gitpodApi: { host: string }
workspaceContextUrl: string
workspaceClusterHost: string
ideAlias: string
}

function doCreateUri(path: string, queryValues: Map<string, string>): URI {
let query: string | undefined = undefined;

Expand Down Expand Up @@ -357,20 +371,7 @@ async function doStart(): Promise<IDisposable> {

const subscriptions = new DisposableStore();

const info: {
workspaceId: string
instanceId: string
checkoutLocation: string
workspaceLocationFile?: string
workspaceLocationFolder?: string
userHome: string
gitpodHost: string
gitpodApi: {
host: string
}
workspaceContextUrl: string
workspaceClusterHost: string
} = await infoResponse.json();
const info: WorkspaceInfoResponse = await infoResponse.json();
if (_state as any === 'terminated') {
return Disposable.None;
}
Expand Down Expand Up @@ -825,6 +826,9 @@ async function doStart(): Promise<IDisposable> {
urlCallbackProvider: new PollingURLCallbackProvider(),
credentialsProvider,
productConfiguration: {
nameShort: product.nameShort + (info.ideAlias === 'code-latest' ? ' - Insiders' : ''),
nameLong: product.nameLong + (info.ideAlias === 'code-latest' ? ' - Insiders' : ''),
version: product.version + (info.ideAlias === 'code-latest' ? '-insider' : ''),
linkProtectionTrustedDomains: [
...(product.linkProtectionTrustedDomains || []),
gitpodDomain
Expand Down

0 comments on commit 2d181c1

Please sign in to comment.