Skip to content

Commit bcc6305

Browse files
afc163claude
andauthored
build: bundle dependencies to eliminate 180+ transitive deps (#64)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 4bde8ef commit bcc6305

2 files changed

Lines changed: 9 additions & 4 deletions

File tree

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,13 @@
4343
"access": "public"
4444
},
4545
"dependencies": {
46-
"@modelcontextprotocol/sdk": "^1.27.1",
47-
"commander": "~13.1.0",
4846
"oxc-parser": "^0.121.0"
4947
},
5048
"devDependencies": {
49+
"@modelcontextprotocol/sdk": "^1.27.1",
5150
"@types/node": "^25.5.0",
5251
"@vitest/coverage-v8": "^3.2.4",
52+
"commander": "~13.1.0",
5353
"gray-matter": "^4.0.3",
5454
"tsup": "^8.4.0",
5555
"tsx": "^4.19.0",

tsup.config.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,17 @@ export default defineConfig({
1010
outDir: 'dist',
1111
clean: true,
1212
splitting: false,
13-
sourcemap: true,
13+
sourcemap: false,
1414
dts: true,
1515
banner: {
16-
js: '#!/usr/bin/env node',
16+
js: [
17+
'#!/usr/bin/env node',
18+
'import { createRequire } from "node:module";',
19+
'const require = createRequire(import.meta.url);',
20+
].join('\n'),
1721
},
1822
define: {
1923
__CLI_VERSION__: JSON.stringify(version),
2024
},
25+
noExternal: ['commander', '@modelcontextprotocol/sdk'],
2126
});

0 commit comments

Comments
 (0)