mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-05 02:40:55 -07:00
refactor: remove read-many-files tool from agent (#12796)
This commit is contained in:
@@ -10,7 +10,6 @@ import {
|
||||
CommandKind,
|
||||
} from './types.js';
|
||||
import { MessageType, type HistoryItemToolsList } from '../types.js';
|
||||
import { READ_MANY_FILES_TOOL_NAME } from '@google/gemini-cli-core';
|
||||
|
||||
export const toolsCommand: SlashCommand = {
|
||||
name: 'tools',
|
||||
@@ -45,10 +44,7 @@ export const toolsCommand: SlashCommand = {
|
||||
type: MessageType.TOOLS_LIST,
|
||||
tools: geminiTools.map((tool) => ({
|
||||
name: tool.name,
|
||||
displayName:
|
||||
tool.name === READ_MANY_FILES_TOOL_NAME
|
||||
? `${tool.displayName} (Deprecated)`
|
||||
: tool.displayName,
|
||||
displayName: tool.displayName,
|
||||
description: tool.description,
|
||||
})),
|
||||
showDescriptions: useShowDescriptions,
|
||||
|
||||
@@ -13,6 +13,7 @@ import {
|
||||
getErrorMessage,
|
||||
isNodeError,
|
||||
unescapePath,
|
||||
ReadManyFilesTool,
|
||||
} from '@google/gemini-cli-core';
|
||||
import type { HistoryItem, IndividualToolCallDisplay } from '../types.js';
|
||||
import { ToolCallStatus } from '../types.js';
|
||||
@@ -153,7 +154,7 @@ export async function handleAtCommand({
|
||||
};
|
||||
|
||||
const toolRegistry = config.getToolRegistry();
|
||||
const readManyFilesTool = toolRegistry.getTool('read_many_files');
|
||||
const readManyFilesTool = new ReadManyFilesTool(config);
|
||||
const globTool = toolRegistry.getTool('glob');
|
||||
|
||||
if (!readManyFilesTool) {
|
||||
|
||||
Reference in New Issue
Block a user