File tree 2 files changed +5
-4
lines changed
2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ import { RequestType0 } from "vscode-languageclient";
6
6
import { LanguageClient } from "vscode-languageclient/node" ;
7
7
import { Logger } from "../logging" ;
8
8
import { LanguageClientConsumer } from "../languageClientConsumer" ;
9
+ import { getSettings } from "../settings" ;
9
10
10
11
interface ICommand {
11
12
name : string ;
@@ -68,8 +69,8 @@ export class GetCommandsFeature extends LanguageClientConsumer {
68
69
return ;
69
70
}
70
71
await this . languageClient . sendRequest ( GetCommandRequestType ) . then ( ( result ) => {
71
- const SidebarConfig = vscode . workspace . getConfiguration ( "powershell .sideBar" ) ;
72
- const excludeFilter = ( SidebarConfig . CommandExplorerExcludeFilter ) . map ( ( filter : string ) => filter . toLowerCase ( ) ) ;
72
+ const exclusions = getSettings ( ) . sideBar . CommandExplorerExcludeFilter ;
73
+ const excludeFilter = exclusions . map ( ( filter : string ) => filter . toLowerCase ( ) ) ;
73
74
result = result . filter ( ( command ) => ( excludeFilter . indexOf ( command . moduleName . toLowerCase ( ) ) === - 1 ) ) ;
74
75
this . commandsExplorerProvider . powerShellCommands = result . map ( toCommand ) ;
75
76
this . commandsExplorerProvider . refresh ( ) ;
Original file line number Diff line number Diff line change @@ -102,7 +102,7 @@ class DebuggingSettings extends PartialSettings {
102
102
}
103
103
104
104
class DeveloperSettings extends PartialSettings {
105
- featureFlags = [ ] ;
105
+ featureFlags : string [ ] = [ ] ;
106
106
// From `<root>/out/main.js` we go to the directory before <root> and
107
107
// then into the other repo.
108
108
bundledModulesPath = "../../PowerShellEditorServices/module" ;
@@ -130,8 +130,8 @@ class IntegratedConsoleSettings extends PartialSettings {
130
130
}
131
131
132
132
class SideBarSettings extends PartialSettings {
133
- // TODO: add CommandExplorerExcludeFilter
134
133
CommandExplorerVisibility = true ;
134
+ CommandExplorerExcludeFilter : string [ ] = [ ] ;
135
135
}
136
136
137
137
class PesterSettings extends PartialSettings {
You can’t perform that action at this time.
0 commit comments