Skip to content

Commit 01a159a

Browse files
ci-botyann300
authored andcommitted
conditionnally use some tool and comment
1 parent ff45e45 commit 01a159a

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

libs/remix-ai-core/src/remix-mcp-server/RemixMCPServer.ts

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,8 @@ import { ValidationMiddleware } from './middleware/ValidationMiddleware';
6767
import { FilePermissionMiddleware } from './middleware/FilePermissionMiddleware';
6868
import { MCPConfigManager } from './config/MCPConfigManager';
6969

70+
import isElectron from 'is-electron'
71+
7072
/**
7173
* Main Remix MCP Server implementation
7274
*/
@@ -852,21 +854,26 @@ export class RemixMCPServer extends EventEmitter implements IRemixMCPServer {
852854
this._tools.registerBatch(tutorialTools);
853855

854856
// Register Amp tools
857+
/*
855858
const ampTools = createAmpTools();
856859
this._tools.registerBatch(ampTools);
860+
*/
857861

858862
// Register Math Utils tools
859863
const mathUtilsTools = createMathUtilsTools();
860864
this._tools.registerBatch(mathUtilsTools);
861865

862866
// Register Foundry and Hardhat tools
863-
const foundryHardhatTools = createFoundryHardhatTools();
864-
this._tools.registerBatch(foundryHardhatTools);
867+
if (isElectron()) {
868+
const foundryHardhatTools = createFoundryHardhatTools();
869+
this._tools.registerBatch(foundryHardhatTools);
870+
}
865871

866872
// Register Chartjs tool
873+
/*
867874
const chartJsTools = createChartJsTools();
868875
this._tools.registerBatch(chartJsTools);
869-
876+
*/
870877
const totalTools = this._tools.list().length;
871878

872879
} catch (error) {

0 commit comments

Comments
 (0)