diff --git a/libs/remixd/src/bin/remixd.ts b/libs/remixd/src/bin/remixd.ts index d0f52556e3..9c561c5e65 100644 --- a/libs/remixd/src/bin/remixd.ts +++ b/libs/remixd/src/bin/remixd.ts @@ -63,6 +63,7 @@ function errorHandler (error: any, service: string) { .description('Establish a two-way websocket connection between the local computer and Remix IDE for a folder') .option('-u, --remix-ide ', 'URL of remix instance allowed to connect') .option('-s, --shared-folder ', 'Folder to share with Remix IDE (Default: CWD)') + .option('-i, --install ', 'Module name to install locally (Supported: ["slither"])') .option('-r, --read-only', 'Treat shared folder as read-only (experimental)') .on('--help', function () { console.log('\nExample:\n\n remixd -s ./shared_project -u http://localhost:8080') @@ -71,6 +72,11 @@ function errorHandler (error: any, service: string) { await warnLatestVersion() + if(program.install && !program.readOnly) { + if (program.install.toLowerCase() === 'slither') require('./../scripts/installSlither') + process.exit(0) + } + if (!program.remixIde) { console.log('\x1b[33m%s\x1b[0m', '[WARN] You can only connect to remixd from one of the supported origins.') } else {