File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed
Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -128,7 +128,11 @@ export class TaskExtension {
128128 prompt : RUNTASKWITHARGS_PROMPT ,
129129 placeHolder : RUNTASKWITHARGS_PLACEHOLDER
130130 } ) . then ( ( cliArgsInput ) => {
131- services . taskfile . runTask ( treeItem . task . name , treeItem . workspace ) ;
131+ if ( cliArgsInput === undefined ) {
132+ vscode . window . showInformationMessage ( 'No Args Supplied' ) ;
133+ return ;
134+ }
135+ services . taskfile . runTask ( treeItem . task . name , treeItem . workspace , cliArgsInput ) ;
132136 } ) ;
133137 }
134138 } ) ) ;
Original file line number Diff line number Diff line change @@ -13,6 +13,11 @@ tasks:
1313 cmds :
1414 - echo "Hello World"
1515
16+ hello-with-args :
17+ desc : Print custom arguments from Run Task With Args
18+ cmds :
19+ - echo {{.CLI_ARGS}}
20+
1621 internal-task :
1722 desc : A task should not be visible in the tree view or executable
1823 cmds :
You can’t perform that action at this time.
0 commit comments