Closes #1328, initialize auto completion list at a later point in time

This commit is contained in:
Mario Zechner 2026-02-06 13:16:39 +01:00
parent 6822691a81
commit b170341b14

View file

@ -361,10 +361,6 @@ export class InteractiveMode {
this.defaultEditor.setAutocompleteProvider(this.autocompleteProvider); this.defaultEditor.setAutocompleteProvider(this.autocompleteProvider);
} }
private rebuildAutocomplete(): void {
this.setupAutocomplete(this.fdPath);
}
async init(): Promise<void> { async init(): Promise<void> {
if (this.isInitialized) return; if (this.isInitialized) return;
@ -373,7 +369,6 @@ export class InteractiveMode {
// Setup autocomplete with fd tool for file path completion // Setup autocomplete with fd tool for file path completion
this.fdPath = await ensureTool("fd"); this.fdPath = await ensureTool("fd");
this.setupAutocomplete(this.fdPath);
// Add header container as first child // Add header container as first child
this.ui.addChild(this.headerContainer); this.ui.addChild(this.headerContainer);
@ -1062,7 +1057,7 @@ export class InteractiveMode {
}); });
setRegisteredThemes(this.session.resourceLoader.getThemes().themes); setRegisteredThemes(this.session.resourceLoader.getThemes().themes);
this.rebuildAutocomplete(); this.setupAutocomplete(this.fdPath);
const extensionRunner = this.session.extensionRunner; const extensionRunner = this.session.extensionRunner;
if (!extensionRunner) { if (!extensionRunner) {
@ -3022,7 +3017,7 @@ export class InteractiveMode {
}, },
onEnableSkillCommandsChange: (enabled) => { onEnableSkillCommandsChange: (enabled) => {
this.settingsManager.setEnableSkillCommands(enabled); this.settingsManager.setEnableSkillCommands(enabled);
this.rebuildAutocomplete(); this.setupAutocomplete(this.fdPath);
}, },
onSteeringModeChange: (mode) => { onSteeringModeChange: (mode) => {
this.session.setSteeringMode(mode); this.session.setSteeringMode(mode);
@ -3726,7 +3721,7 @@ export class InteractiveMode {
} }
this.ui.setShowHardwareCursor(this.settingsManager.getShowHardwareCursor()); this.ui.setShowHardwareCursor(this.settingsManager.getShowHardwareCursor());
this.ui.setClearOnShrink(this.settingsManager.getClearOnShrink()); this.ui.setClearOnShrink(this.settingsManager.getClearOnShrink());
this.rebuildAutocomplete(); this.setupAutocomplete(this.fdPath);
const runner = this.session.extensionRunner; const runner = this.session.extensionRunner;
if (runner) { if (runner) {
this.setupExtensionShortcuts(runner); this.setupExtensionShortcuts(runner);