Add Pause Codebase On Start setting (#1788)

* Add a skipInitialSync function

* Add pauseInitialCodebaseIndex

* docs

* version bump

* Rename to pauseCodebaseIndexOnStart
This commit is contained in:
Josh Vera 2024-07-22 17:19:49 -04:00 • committed by GitHub
parent a758d75c4a
commit b26bde73a2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 17 additions and 1 deletions

View file

@ -142,9 +142,17 @@ export class Core {
),
);
// Index on initialization
this.ide
.getWorkspaceDirs()
.then((dirs) => this.refreshCodebaseIndex(dirs));
.then((dirs) => {
// Respect pauseCodebaseIndexOnStart user settings
if (ideSettings.pauseCodebaseIndexOnStart) {
return;
}
this.refreshCodebaseIndex(dirs);
});
});
const getLlm = async () => {

1
core/index.d.ts vendored
View file

@ -422,6 +422,7 @@ export interface IdeSettings {
remoteConfigSyncPeriod: number;
userToken: string;
enableControlServerBeta: boolean;
pauseCodebaseIndexOnStart: boolean
enableDebugLogs: boolean
}

View file

@ -38,6 +38,7 @@ class FileSystemIde implements IDE {
remoteConfigSyncPeriod: 60,
userToken: "",
enableControlServerBeta: false,
pauseCodebaseIndexOnStart: false,
enableDebugLogs: false,
};
}

View file

@ -94,6 +94,11 @@
"default": false,
"markdownDescription": "Pause Continue's tab autocomplete feature when your battery is low."
},
"continue.pauseCodebaseIndexOnStart": {
"type": "boolean",
"default": false,
"markdownDescription": "Pause Continue's codebase index on start."
},
"continue.enableDebugLogs": {
"type": "boolean",
"default": false,

View file

@ -522,6 +522,7 @@ class VsCodeIde implements IDE {
),
userToken: settings.get<string>("userToken", ""),
enableControlServerBeta: internalBetaPathExists(),
pauseCodebaseIndexOnStart: settings.get<boolean>("pauseCodebaseIndexOnStart", false),
enableDebugLogs: settings.get<boolean>("enableDebugLogs", false),
// settings.get<boolean>(
// "enableControlServerBeta",