Skip to content

Commit b52e116

Browse files
committed
fix: restart language server on secrets configuration change
1 parent abfaf75 commit b52e116

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/configuration/configuration.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ export function initConfiguration(context: vscode.ExtensionContext) {
1818
await updateLanguageServerApiUrl(context);
1919
resetGitHubContext();
2020
await vscode.commands.executeCommand("github-actions.explorer.refresh");
21+
} else if (e.affectsConfiguration(getSettingsKey("validation.secrets"))) {
22+
await restartLanguageServer(context);
2123
}
2224
})
2325
);
@@ -87,3 +89,8 @@ async function updateLanguageServerApiUrl(context: vscode.ExtensionContext) {
8789

8890
await initLanguageServer(context);
8991
}
92+
93+
async function restartLanguageServer(context: vscode.ExtensionContext) {
94+
await deactivateLanguageServer();
95+
await initLanguageServer(context);
96+
}

0 commit comments

Comments
 (0)