File tree Expand file tree Collapse file tree 3 files changed +13
-0
lines changed Expand file tree Collapse file tree 3 files changed +13
-0
lines changed Original file line number Diff line number Diff line change 143143 "scope" : " resource" ,
144144 "default" : true ,
145145 "description" : " enable or disable quick commands in the context menu"
146+ },
147+ "coverage-gutters.watchOnActivate" : {
148+ "type" : " boolean" ,
149+ "scope" :" resource" ,
150+ "default" : false ,
151+ "description" : " automatically watch coverage files and visible editors on extension activation (workspace open)"
146152 }
147153 }
148154 },
Original file line number Diff line number Diff line change @@ -49,4 +49,8 @@ export function activate(context: vscode.ExtensionContext) {
4949 context . subscriptions . push ( removeWatch ) ;
5050 context . subscriptions . push ( gutters ) ;
5151 context . subscriptions . push ( outputChannel ) ;
52+
53+ if ( configStore . watchOnActivate ) {
54+ gutters . watchCoverageAndVisibleEditors ( ) ;
55+ }
5256}
Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ export class Config {
2020 public ignoredPathGlobs ! : string ;
2121 public remotePathResolve ! : string [ ] ;
2222 public manualCoverageFilePaths ! : string [ ] ;
23+ public watchOnActivate ! : boolean ;
2324
2425 private context : ExtensionContext ;
2526
@@ -149,6 +150,8 @@ export class Config {
149150
150151 // Add the manual coverage file path(s) if present
151152 this . manualCoverageFilePaths = rootConfig . get ( "manualCoverageFilePaths" ) as string [ ] ;
153+
154+ this . watchOnActivate = rootConfig . get ( "watchOnActivate" ) as boolean ;
152155 }
153156
154157 /**
You can’t perform that action at this time.
0 commit comments