We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 928d9d8 commit 49d6214Copy full SHA for 49d6214
src/features/DebugSession.ts
@@ -44,7 +44,15 @@ export class DebugSessionFeature implements IFeature {
44
let currentDocument = vscode.window.activeTextEditor.document;
45
46
if (currentDocument.isUntitled) {
47
- config.script = currentDocument.uri.toString();
+ if (currentDocument.languageId === 'powershell') {
48
+ config.script = currentDocument.uri.toString();
49
+ }
50
+ else {
51
+ let msg = "In order to debug '" + currentDocument.fileName +
52
+ "', set the document's language mode to PowerShell or save the file with a PowerShell extension.";
53
+ vscode.window.showErrorMessage(msg);
54
+ return;
55
56
}
57
else {
58
let isValidExtension = false;
0 commit comments