continue-custom/core/tools/implementations/readFile.ts
2024-11-29 08:38:26 -08:00

14 lines
319 B
TypeScript

import { getBasename } from "../../util";
import { ToolImpl } from ".";
export const readFileImpl: ToolImpl = async (args, extras) => {
const content = await extras.ide.readFile(args.filepath);
return [
{
name: getBasename(args.filepath),
description: args.filepath,
content,
},
];
};