Skip to content

Commit 8861fc7

Browse files
author
Kapil Borle
committed
Show powershell status only for powershell documents
1 parent 711c52b commit 8861fc7

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/session.ts

+9
Original file line numberDiff line numberDiff line change
@@ -383,6 +383,15 @@ export class SessionManager {
383383

384384
this.statusBarItem.command = this.ShowSessionMenuCommandName;
385385
this.statusBarItem.show();
386+
vscode.window.onDidChangeActiveTextEditor(textEditor => {
387+
if (textEditor === undefined
388+
|| textEditor.document.languageId !== "powershell") {
389+
this.statusBarItem.hide();
390+
}
391+
else {
392+
this.statusBarItem.show();
393+
}
394+
})
386395
}
387396
}
388397

0 commit comments

Comments
 (0)