Skip to content

Commit 33eaeb7

Browse files
author
flmeyer
committed
Fix GitHub context not being refreshed on config change
1 parent 49c6dcd commit 33eaeb7

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/configuration/configuration.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import * as vscode from "vscode";
22
import {deactivateLanguageServer, initLanguageServer} from "../workflow/languageServer";
3+
import {resetGitHubContext} from "../git/repository";
34

45
const settingsKey = "github-actions";
56
const DEFAULT_GITHUB_API = "https://api.github.com";
@@ -11,9 +12,12 @@ export function initConfiguration(context: vscode.ExtensionContext) {
1112
pinnedWorkflowsChangeHandlers.forEach(h => h());
1213
} else if (
1314
e.affectsConfiguration(getSettingsKey("use-enterprise")) ||
14-
e.affectsConfiguration("github-enterprise.uri")
15+
(isUseEnterprise() &&
16+
(e.affectsConfiguration("github-enterprise.uri") || e.affectsConfiguration(getSettingsKey("remote-name"))))
1517
) {
1618
updateLanguageServerApiUrl(context);
19+
resetGitHubContext();
20+
vscode.commands.executeCommand("github-actions.explorer.refresh");
1721
}
1822
})
1923
);

0 commit comments

Comments
 (0)