feat: add --show_memory_usage flag to display memory usage in status bar (#606)

This commit is contained in:
Jacob Richman
2025-05-30 22:18:01 +00:00
committed by GitHub
parent 3291ffbe09
commit 01768d7759
10 changed files with 205 additions and 12 deletions

View File

@@ -54,6 +54,7 @@ export interface ConfigParameters {
geminiMdFileCount?: number;
alwaysSkipModificationConfirmation?: boolean;
vertexai?: boolean;
showMemoryUsage?: boolean;
}
export class Config {
@@ -75,6 +76,7 @@ export class Config {
private geminiMdFileCount: number;
private alwaysSkipModificationConfirmation: boolean;
private readonly vertexai: boolean | undefined;
private readonly showMemoryUsage: boolean;
constructor(params: ConfigParameters) {
this.apiKey = params.apiKey;
@@ -95,6 +97,7 @@ export class Config {
this.alwaysSkipModificationConfirmation =
params.alwaysSkipModificationConfirmation ?? false;
this.vertexai = params.vertexai;
this.showMemoryUsage = params.showMemoryUsage ?? false;
this.toolRegistry = createToolRegistry(this);
}
@@ -181,6 +184,10 @@ export class Config {
getVertexAI(): boolean | undefined {
return this.vertexai;
}
getShowMemoryUsage(): boolean {
return this.showMemoryUsage;
}
}
function findEnvFile(startDir: string): string | null {