@@ -32,11 +32,11 @@ export function activate(context: ExtensionContext) {
32
32
} else {
33
33
p = "" ;
34
34
}
35
- var execution = new vscode . ShellExecution ( "plc --debug " + fspath ) ;
35
+ var execution = new vscode . ShellExecution ( "plc --debug -O0 " + fspath ) ;
36
36
var problemMatchers = [ "$myProblemMatcher" ] ;
37
37
return [
38
38
new vscode . Task ( { type : type } , vscode . TaskScope . Workspace ,
39
- "pl Build" , "pivot-lang" , execution , problemMatchers )
39
+ "pl Build debug " , "pivot-lang" , execution , problemMatchers )
40
40
] ;
41
41
} ,
42
42
resolveTask ( task : vscode . Task , token ?: vscode . CancellationToken ) {
@@ -88,12 +88,10 @@ export function activate(context: ExtensionContext) {
88
88
} ) ;
89
89
} ) ;
90
90
91
- vscode . commands . registerCommand ( "pivot-lang.run_current" , ( ) => {
91
+ vscode . commands . registerCommand ( "pivot-lang.run_current" , async ( ) => {
92
92
let fspath = vscode . window . activeTextEditor . document . uri . fsPath ;
93
- var execution = new vscode . ShellExecution ( "plc --debug" + fspath + " -o out && ./out" ) ;
94
- vscode . tasks . executeTask ( new vscode . Task ( { type : "plrun" } , vscode . TaskScope . Workspace , "build" , "pivot-lang" , execution ) ) . then ( ( value ) => {
95
-
96
- } ) ;
93
+ var execution = new vscode . ShellExecution ( "plc " + fspath + " -o out\n./out" ) ;
94
+ vscode . tasks . executeTask ( new vscode . Task ( { type : "plrun" } , vscode . TaskScope . Workspace , "build" , "pivot-lang" , execution ) ) ;
97
95
} ) ;
98
96
99
97
vscode . workspace . onDidChangeConfiguration ( ( e ) => {
@@ -149,7 +147,7 @@ class PLConfigurationProvider implements vscode.DebugConfigurationProvider {
149
147
return ;
150
148
}
151
149
config . preLaunchTask = {
152
- "task" : "pl Build" ,
150
+ "task" : "pl Build debug " ,
153
151
"type" : type
154
152
} ;
155
153
if ( ! config . request ) {
0 commit comments