File tree Expand file tree Collapse file tree 4 files changed +16
-4
lines changed Expand file tree Collapse file tree 4 files changed +16
-4
lines changed Original file line number Diff line number Diff line change 11# vscode-powershell Release History
22
3+ ## 0.12.1
4+ ### Tuesday, April 4, 2017
5+
6+ - Fixed [ #648 ] ( https://github.com/PowerShell/vscode-powershell/issues/648 ) -
7+ Resolved an error when launching an untitled script file in a workspace
8+ with no launch.json or in a window without a workspace path
9+
310## 0.12.0
411### Tuesday, April 4, 2017
512
Original file line number Diff line number Diff line change 1- version : ' 0.12.0 -insiders-{build}'
1+ version : ' 0.12.1 -insiders-{build}'
22image : Visual Studio 2017
33clone_depth : 10
44skip_tags : true
Original file line number Diff line number Diff line change 11{
22 "name" : " PowerShell" ,
33 "displayName" : " PowerShell" ,
4- "version" : " 0.12.0 " ,
4+ "version" : " 0.12.1 " ,
55 "publisher" : " ms-vscode" ,
66 "description" : " Develop PowerShell scripts in Visual Studio Code!" ,
77 "engines" : {
Original file line number Diff line number Diff line change @@ -25,13 +25,19 @@ export class DebugSessionFeature implements IFeature {
2525
2626 private startDebugSession ( config : any ) {
2727
28+ let currentDocument = vscode . window . activeTextEditor . document ;
29+
2830 if ( ! config . request ) {
2931 // No launch.json, create the default configuration
3032 config . type = 'PowerShell' ;
3133 config . name = 'PowerShell Launch Current File' ;
3234 config . request = 'launch' ;
3335 config . args = [ ] ;
34- config . script = vscode . window . activeTextEditor . document . fileName ;
36+
37+ config . script =
38+ currentDocument . isUntitled
39+ ? currentDocument . uri . toString ( )
40+ : currentDocument . fileName ;
3541 }
3642
3743 if ( config . request === 'launch' ) {
@@ -41,7 +47,6 @@ export class DebugSessionFeature implements IFeature {
4147 // For launch of "current script", don't start the debugger if the current file
4248 // is not a file that can be debugged by PowerShell
4349 if ( config . script === "${file}" ) {
44- let currentDocument = vscode . window . activeTextEditor . document ;
4550
4651 if ( currentDocument . isUntitled ) {
4752 if ( currentDocument . languageId === 'powershell' ) {
You can’t perform that action at this time.
0 commit comments