-
Notifications
You must be signed in to change notification settings - Fork 214
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
62 changed files
with
1,604 additions
and
295 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
export const environment = { | ||
production: true | ||
production: true, | ||
disableTelemetry: false | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
import { ExtensionContext } from 'vscode'; | ||
import { Store } from '@nrwl/angular-console-enterprise-electron'; | ||
|
||
export class VSCodeStorage implements Store { | ||
static fromContext(context: ExtensionContext): VSCodeStorage { | ||
const store = new VSCodeStorage(context.globalState); | ||
return store; | ||
} | ||
|
||
constructor(private readonly state: VSCGlobalState) {} | ||
|
||
get<T>(key: string, defaultValue?: T): T | null { | ||
const value = this.state.get(key, defaultValue); | ||
return value || defaultValue || null; | ||
} | ||
|
||
set<T>(key: string, value: T): void { | ||
this.state.update(key, value); | ||
} | ||
|
||
delete(key: string): void { | ||
this.state.update(key, undefined); | ||
} | ||
} | ||
|
||
export interface VSCGlobalState { | ||
get<T>(key: string): T | undefined; | ||
get<T>(key: string, defaultValue: T): T; | ||
update(key: string, value: any): void; | ||
} | ||
|
||
export class SubstituteGlobalState implements VSCGlobalState { | ||
state: { [key: string]: any } = {}; | ||
|
||
get<T>(key: string, defaultValue?: T): T { | ||
return this.state[key] || defaultValue; | ||
} | ||
|
||
update<T>(key: string, value: T): void { | ||
this.state[key] = value; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
export const environment = { | ||
production: true | ||
production: true, | ||
disableTelemetry: false | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.