Refactor CLI and file handling tools for improved functionality. Update CLI interrogation command for better clarity and adjust logging format. Modify list_files.js to enhance path display logic and update read_file.js schema to allow null values for optional parameters, improving flexibility in file reading operations.

This commit is contained in:
sebseb7
2025-08-21 12:58:14 +00:00
parent 6e8a336143
commit eb3f58b2e6
3 changed files with 10 additions and 7 deletions

View File

@@ -159,7 +159,10 @@ export async function run(args) {
return { err: `Path does not exist${inputPath ? `: ${inputPath}` : ""}` };
}
const cwd = path.relative(chrootResolved, stat.isFile() ? path.dirname(resolvedBase) : resolvedBase) || ".";
const cwd = toDisplayPath(
stat.isFile() ? path.dirname(resolvedBase) : resolvedBase,
chrootResolved
);
// Handle single file case
if (stat.isFile()) {