MCPcopy Index your code
hub / github.com/Waishnav/devspace / grepFilesTool

Function grepFilesTool

src/pi-tools.ts:100–105  ·  view source on GitHub ↗
(input: GrepToolInput, context: ToolContext)

Source from the content-addressed store, hash-verified

98}
99
100export async function grepFilesTool(input: GrepToolInput, context: ToolContext): Promise<ToolResponse> {
101 if (input.path) resolveAllowedPath(input.path, context.cwd, [context.root]);
102 const tool = createGrepTool(context.cwd);
103
104 return runTool((params) => tool.execute("grep_files", params), input, context);
105}
106
107export async function findFilesTool(input: FindToolInput, context: ToolContext): Promise<ToolResponse> {
108 if (input.path) resolveAllowedPath(input.path, context.cwd, [context.root]);

Callers 1

createMcpServerFunction · 0.85

Calls 2

resolveAllowedPathFunction · 0.85
runToolFunction · 0.85

Tested by

no test coverage detected