Skip to content

Commit 2dd5fa8

Browse files
Remove popup when extension updates (#4105)
VS Code team asked us to remove this as it is unnecessarily noisy and not inline with extension guidelines. They are working on a coordinated "your extensions updated!" workflow.
1 parent 6352fe5 commit 2dd5fa8

File tree

1 file changed

+0
-32
lines changed

1 file changed

+0
-32
lines changed

src/main.ts

-32
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,6 @@ export async function activate(context: vscode.ExtensionContext): Promise<IPower
6464
"'PowerShell' and 'PowerShell Preview' are both enabled. Please disable one for best performance.");
6565
}
6666

67-
// This displays a popup and a changelog after an update.
68-
checkForUpdatedVersion(context, PackageJSON.version);
69-
7067
// Load and validate settings (will prompt for 'cwd' if necessary).
7168
await Settings.validateCwdSetting();
7269
const extensionSettings = Settings.load();
@@ -184,35 +181,6 @@ export async function activate(context: vscode.ExtensionContext): Promise<IPower
184181
};
185182
}
186183

187-
function checkForUpdatedVersion(context: vscode.ExtensionContext, version: string) {
188-
189-
const showReleaseNotes = "Show Release Notes";
190-
const powerShellExtensionVersionKey = "powerShellExtensionVersion";
191-
192-
const storedVersion = context.globalState.get(powerShellExtensionVersionKey);
193-
194-
if (!storedVersion) {
195-
// TODO: Prompt to show User Guide for first-time install
196-
} else if (version !== storedVersion) {
197-
vscode
198-
.window
199-
.showInformationMessage(
200-
`The PowerShell extension has been updated to version ${version}!`,
201-
showReleaseNotes)
202-
.then((choice) => {
203-
if (choice === showReleaseNotes) {
204-
vscode.commands.executeCommand(
205-
"markdown.showPreview",
206-
vscode.Uri.file(path.resolve(__dirname, "../CHANGELOG.md")));
207-
}
208-
});
209-
}
210-
211-
context.globalState.update(
212-
powerShellExtensionVersionKey,
213-
version);
214-
}
215-
216184
export function deactivate(): void {
217185
// Clean up all extension features
218186
languageClientConsumers.forEach((languageClientConsumer) => {

0 commit comments

Comments
 (0)