File tree Expand file tree Collapse file tree 3 files changed +7
-10
lines changed Expand file tree Collapse file tree 3 files changed +7
-10
lines changed Original file line number Diff line number Diff line change 229
229
"order" : 14
230
230
},
231
231
"refactai.activeGroup" : {
232
- "type" : " object" ,
232
+ "type" : [ " object" , " null " ] ,
233
233
"default" : null ,
234
- "description" : " A hidden setting only editable via settings.json" ,
235
- "scope" : " machine-overridable"
234
+ "description" : " Active selected group in your Team Workspace. Modify via settings.json in your workspace" ,
235
+ "scope" : " machine-overridable" ,
236
+ "included" : false
236
237
}
237
238
}
238
239
},
Original file line number Diff line number Diff line change @@ -308,8 +308,6 @@ export function activate(context: vscode.ExtensionContext)
308
308
} ) ;
309
309
context . subscriptions . push ( settingsCommand ) ;
310
310
311
- const activeGroup = vscode . workspace . getConfiguration ( ) . get ( 'refactai.activeGroup' ) ;
312
-
313
311
let logout = vscode . commands . registerCommand ( 'refactaicmd.logout' , async ( ) => {
314
312
context . globalState . update ( 'codifyFirstRun' , false ) ;
315
313
await vscode . workspace . getConfiguration ( ) . update ( 'refactai.apiKey' , undefined , vscode . ConfigurationTarget . Global ) ;
Original file line number Diff line number Diff line change @@ -816,20 +816,18 @@ export class PanelWebview implements vscode.WebviewViewProvider {
816
816
}
817
817
818
818
async handleSetActiveGroup ( group :TeamsGroup ) {
819
- await vscode . workspace . getConfiguration ( ) . update (
819
+ await this . context . workspaceState . update (
820
820
'refactai.activeGroup' ,
821
821
group ,
822
- vscode . ConfigurationTarget . Workspace
823
822
) ;
824
823
console . log ( `[DEBUG]: updated locally active group in ./.vscode/settings.json: ` , group ) ;
825
824
this . handleSettingsChange ( ) ;
826
825
}
827
826
828
827
async handleClearActiveGroup ( ) {
829
- await vscode . workspace . getConfiguration ( ) . update (
828
+ await this . context . workspaceState . update (
830
829
'refactai.activeGroup' ,
831
830
undefined ,
832
- vscode . ConfigurationTarget . Workspace
833
831
) ;
834
832
this . handleSettingsChange ( ) ;
835
833
}
@@ -986,7 +984,7 @@ export class PanelWebview implements vscode.WebviewViewProvider {
986
984
const ast = vscode . workspace . getConfiguration ( ) ?. get < boolean > ( "refactai.ast" ) ?? false ;
987
985
const apiKey = vscode . workspace . getConfiguration ( ) ?. get < string > ( "refactai.apiKey" ) ?? "" ;
988
986
const addressURL = vscode . workspace . getConfiguration ( ) ?. get < string > ( "refactai.addressURL" ) ?? "" ;
989
- const activeTeamsGroup = vscode . workspace . getConfiguration ( ) ? .get < TeamsGroup > ( " refactai.activeGroup" ) ?? null ;
987
+ const activeTeamsGroup = this . context . workspaceState . get < TeamsGroup > ( ' refactai.activeGroup' ) ?? null ;
990
988
const port = global . rust_binary_blob ?. get_port ( ) ?? 8001 ;
991
989
const completeManual = await getKeyBindingForChat ( "refactaicmd.completionManual" ) ;
992
990
const shiftEnterToSubmit = vscode . workspace . getConfiguration ( ) ?. get < boolean > ( "refactai.shiftEnterToSubmit" ) ?? false ;
You can’t perform that action at this time.
0 commit comments