@@ -13,11 +13,13 @@ export class TaskExtension {
1313 private _watcher : vscode . FileSystemWatcher ;
1414 private _changeTimeout : NodeJS . Timeout | null = null ;
1515 private _nesting : boolean ;
16+ private _status : boolean ;
1617
1718 constructor ( ) {
1819 this . _activityBar = new ActivityBar ( ) ;
1920 this . _watcher = vscode . workspace . createFileSystemWatcher ( "**/*.{yml,yaml}" ) ;
2021 this . _nesting = settings . tree . nesting ;
22+ this . _status = settings . tree . status ;
2123 }
2224
2325 public async update ( checkForUpdates ?: boolean ) : Promise < void > {
@@ -36,7 +38,7 @@ export class TaskExtension {
3638 // Read taskfiles
3739 let p : Promise < Namespace | undefined > [ ] = [ ] ;
3840 vscode . workspace . workspaceFolders ?. forEach ( ( folder ) => {
39- p . push ( taskfileSvc . read ( folder . uri . fsPath , this . _nesting ) ) ;
41+ p . push ( taskfileSvc . read ( folder . uri . fsPath , this . _nesting , this . _status ) ) ;
4042 } ) ;
4143
4244 return Promise . allSettled ( p ) ;
@@ -288,6 +290,10 @@ export class TaskExtension {
288290 log . info ( "Detected changes to configuration" ) ;
289291 if ( event . affectsConfiguration ( "task" ) ) {
290292 settings . update ( ) ;
293+ this . _nesting = settings . tree . nesting ;
294+ this . _status = settings . tree . status ;
295+ this . refresh ( false ) ;
296+ vscode . commands . executeCommand ( 'setContext' , 'vscode-task:treeNesting' , this . _nesting ) ;
291297 }
292298 }
293299}
0 commit comments