@@ -34,6 +34,7 @@ import { VSCodeWorkspace } from './parts/vscodeWorkspace';
34
34
import { makeSettable } from './utils/observablesUtils' ;
35
35
36
36
const TRIGGER_INLINE_EDIT_ON_ACTIVE_EDITOR_CHANGE = false ; // otherwise, eg, NES would trigger just when going through search results
37
+ const useEnhancedNotebookNESContextKey = 'github.copilot.chat.enableEnhancedNotebookNES' ;
37
38
38
39
export class InlineEditProviderFeature extends Disposable implements IExtensionContribution {
39
40
@@ -75,13 +76,17 @@ export class InlineEditProviderFeature extends Disposable implements IExtensionC
75
76
@IEnvService private readonly _envService : IEnvService ,
76
77
@ILogService private readonly _logService : ILogService ,
77
78
@IInstantiationService private readonly _instantiationService : IInstantiationService ,
79
+ @IExperimentationService _experimentationService : IExperimentationService ,
78
80
) {
79
81
super ( ) ;
80
82
81
83
const tracer = createTracer ( [ 'NES' , 'Feature' ] , ( s ) => this . _logService . trace ( s ) ) ;
82
84
const constructorTracer = tracer . sub ( 'constructor' ) ;
83
-
84
85
const hasUpdatedNesSettingKey = 'copilot.chat.nextEdits.hasEnabledNesInSettings' ;
86
+ const enableEnhancedNotebookNES = this . _configurationService . getExperimentBasedConfig ( ConfigKey . Internal . UseAlternativeNESNotebookFormat , _experimentationService ) || this . _configurationService . getExperimentBasedConfig ( ConfigKey . UseAlternativeNESNotebookFormat , _experimentationService ) ;
87
+
88
+ commands . executeCommand ( 'setContext' , useEnhancedNotebookNESContextKey , enableEnhancedNotebookNES ) ;
89
+
85
90
this . _register ( autorun ( ( reader ) => {
86
91
const copilotToken = this . _copilotToken . read ( reader ) ;
87
92
0 commit comments