diff --git a/rollup.config.mjs b/rollup.config.mjs index b646d22..626df67 100644 --- a/rollup.config.mjs +++ b/rollup.config.mjs @@ -55,28 +55,6 @@ const config = [ json() ], }, - { - input: 'src/cli.ts', - output: [ - { - file: pkgJson.bin[pkgJson.name], - format: "cjs", - esModule: false, - banner: '#!/usr/bin/env node\n' - }, - ], - plugins: [ - esbuild({ - include: /\.[jt]sx?$/, - minify: false, - sourceMap: true, - target: 'es2016', - }), - commonjs(), - nodeResolve(), - json() - ], - }, { input: 'src/merkleTreeWorker.ts', output: [ diff --git a/webpack.config.js b/webpack.config.js index ea66b08..b265a9e 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -53,6 +53,26 @@ module.exports = [ minimize: false, } }, + { + mode: 'production', + module: { + rules: [esbuildLoader] + }, + entry: './src/cli.ts', + output: { + filename: 'cli.js', + path: path.resolve(__dirname, './dist'), + }, + target: 'node', + plugins: [], + resolve: { + extensions: ['.tsx', '.ts', '.js'], + alias: {} + }, + optimization: { + minimize: false, + } + }, { mode: 'production', module: {