( _args: string, context: ToolUseContext, )
| 5 | import { cacheKeys } from '../../utils/fileStateCache.js' |
| 6 | |
| 7 | export async function call( |
| 8 | _args: string, |
| 9 | context: ToolUseContext, |
| 10 | ): Promise<LocalCommandResult> { |
| 11 | const files = context.readFileState ? cacheKeys(context.readFileState) : [] |
| 12 | |
| 13 | if (files.length === 0) { |
| 14 | return { type: 'text' as const, value: 'No files in context' } |
| 15 | } |
| 16 | |
| 17 | const fileList = files.map(file => relative(getCwd(), file)).join('\n') |
| 18 | return { type: 'text' as const, value: `Files in context:\n${fileList}` } |
| 19 | } |
| 20 | |
| 21 |