summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOlcan <[email protected]>2025-05-08 14:14:09 -0700
committerGitHub <[email protected]>2025-05-08 14:14:09 -0700
commit3b025883b6f0bb3d9adacfbe31b51d85ac119df9 (patch)
tree60d7b282d637aaa90963f5b9347c3a94cea9001a
parent5db1b7622aa2e1662cf9c4edec0d874e173816f9 (diff)
fix json import warning (#291)
-rw-r--r--packages/server/src/tools/shell.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/packages/server/src/tools/shell.ts b/packages/server/src/tools/shell.ts
index bf19b37c..fd8a6b1a 100644
--- a/packages/server/src/tools/shell.ts
+++ b/packages/server/src/tools/shell.ts
@@ -16,7 +16,6 @@ import {
ToolExecuteConfirmationDetails,
ToolConfirmationOutcome,
} from './tools.js';
-import toolParameterSchema from './shell.json' with { type: 'json' };
import { SchemaValidator } from '../utils/schemaValidator.js';
export interface ShellToolParams {
command: string;
@@ -33,6 +32,8 @@ export class ShellTool extends BaseTool<ShellToolParams, ToolResult> {
const toolDisplayName = 'Shell';
const descriptionUrl = new URL('shell.md', import.meta.url);
const toolDescription = fs.readFileSync(descriptionUrl, 'utf-8');
+ const schemaUrl = new URL('shell.json', import.meta.url);
+ const toolParameterSchema = JSON.parse(fs.readFileSync(schemaUrl, 'utf-8'));
super(
ShellTool.Name,
toolDisplayName,