diff --git a/package.json b/package.json index 6158f48dfc..6881897aec 100644 --- a/package.json +++ b/package.json @@ -1047,7 +1047,7 @@ "default": false, "markdownDescription": "Do not show the startup banner in the PowerShell Extension Terminal." }, - "powershell.suppressTerminalStoppedNotification": { + "powershell.integratedConsole.suppressTerminalStoppedNotification": { "type": "boolean", "default": false, "markdownDescription": "Do not show a notification when the PowerShell Extension Terminal has stopped." diff --git a/src/session.ts b/src/session.ts index 2908f6d27f..2f9e65f04f 100644 --- a/src/session.ts +++ b/src/session.ts @@ -1159,13 +1159,9 @@ Type 'help' to get help. } private async promptForRestart(): Promise { - // Check user configuration before showing notification - const suppressNotification = - vscode.workspace - .getConfiguration("powershell") - .get("suppressTerminalStoppedNotification") ?? false; - - if (suppressNotification) { + if ( + getSettings().integratedConsole.suppressTerminalStoppedNotification + ) { return; } @@ -1186,7 +1182,7 @@ Type 'help' to get help. prompt: "Don't Show Again", action: async (): Promise => { await changeSetting( - "suppressTerminalStoppedNotification", + "integratedConsole.suppressTerminalStoppedNotification", true, true, this.logger, diff --git a/src/settings.ts b/src/settings.ts index 93e9c672f0..75c3673b2c 100644 --- a/src/settings.ts +++ b/src/settings.ts @@ -133,6 +133,7 @@ class IntegratedConsoleSettings extends PartialSettings { useLegacyReadLine = false; forceClearScrollbackBuffer = false; suppressStartupBanner = false; + suppressTerminalStoppedNotification = false; startLocation = StartLocation.Panel; }