mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 16:57:46 +00:00
feat: allow custom filename for context files (#654)
Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com>
This commit is contained in:
@@ -19,7 +19,7 @@ import { ShellTool } from '../tools/shell.js';
|
||||
import { WriteFileTool } from '../tools/write-file.js';
|
||||
import { WebFetchTool } from '../tools/web-fetch.js';
|
||||
import { ReadManyFilesTool } from '../tools/read-many-files.js';
|
||||
import { MemoryTool } from '../tools/memoryTool.js';
|
||||
import { MemoryTool, setGeminiMdFilename } from '../tools/memoryTool.js';
|
||||
import { WebSearchTool } from '../tools/web-search.js';
|
||||
|
||||
export class MCPServerConfig {
|
||||
@@ -56,6 +56,7 @@ export interface ConfigParameters {
|
||||
alwaysSkipModificationConfirmation?: boolean;
|
||||
vertexai?: boolean;
|
||||
showMemoryUsage?: boolean;
|
||||
contextFileName?: string;
|
||||
}
|
||||
|
||||
export class Config {
|
||||
@@ -100,6 +101,10 @@ export class Config {
|
||||
this.vertexai = params.vertexai;
|
||||
this.showMemoryUsage = params.showMemoryUsage ?? false;
|
||||
|
||||
if (params.contextFileName) {
|
||||
setGeminiMdFilename(params.contextFileName);
|
||||
}
|
||||
|
||||
this.toolRegistry = createToolRegistry(this);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user