Initial auto-fixing of linting errors.

- This is the result of runing `npm lint -- -fix`
This commit is contained in:
Taylor Mullen
2025-04-18 10:53:16 -04:00
committed by N. Taylor Mullen
parent cb30351403
commit e0339993ae
20 changed files with 37 additions and 50 deletions

View File

@@ -351,7 +351,7 @@ export class GrepTool extends BaseTool<GrepToolParams, GrepToolResult> {
results.push({
// Use relative path, or just the filename if it's in the base path itself
filePath: relativeFilePath || path.basename(absoluteFilePath),
lineNumber: lineNumber,
lineNumber,
line: lineContent, // Use the full extracted line content
});
}
@@ -555,7 +555,7 @@ export class GrepTool extends BaseTool<GrepToolParams, GrepToolResult> {
path.relative(absolutePath, fileAbsolutePath) ||
path.basename(fileAbsolutePath),
lineNumber: index + 1,
line: line,
line,
});
}
});

View File

@@ -36,7 +36,7 @@ export class ReadFileTool extends BaseTool<
ReadFileToolParams,
ReadFileToolResult
> {
public static readonly Name: string = 'read_file';
static readonly Name: string = 'read_file';
// Maximum number of lines to read by default
private static readonly DEFAULT_MAX_LINES = 2000;

View File

@@ -127,7 +127,7 @@ export class TerminalTool extends BaseTool<
TerminalToolParams,
TerminalToolResult
> {
public static Name: string = 'execute_bash_command';
static Name: string = 'execute_bash_command';
private readonly rootDirectory: string;
private readonly outputLimit: number;
@@ -387,7 +387,7 @@ Use this tool for running build steps (\`npm install\`, \`make\`), linters (\`es
const confirmationDetails: ToolExecuteConfirmationDetails = {
title: 'Confirm Shell Command',
command: params.command,
rootCommand: rootCommand,
rootCommand,
description: `Execute in '${this.currentCwd}':\n${description}`,
onConfirm: async (outcome: ToolConfirmationOutcome) => {
if (outcome === ToolConfirmationOutcome.ProceedAlways) {

View File

@@ -76,10 +76,10 @@ export abstract class BaseTool<
* @param parameterSchema JSON Schema defining the parameters
*/
constructor(
public readonly name: string,
public readonly displayName: string,
public readonly description: string,
public readonly parameterSchema: Record<string, unknown>,
readonly name: string,
readonly displayName: string,
readonly description: string,
readonly parameterSchema: Record<string, unknown>,
) {}
/**

View File

@@ -37,7 +37,7 @@ export class WriteFileTool extends BaseTool<
WriteFileToolParams,
WriteFileToolResult
> {
public static readonly Name: string = 'write_file';
static readonly Name: string = 'write_file';
private shouldAlwaysWrite = false;
/**