build: replace bun install/build with pnpm/esbuild
This commit is contained in:
parent
3e96007f1f
commit
cd3749b07e
4 changed files with 1113 additions and 244 deletions
21
package.json
21
package.json
|
|
@ -4,24 +4,21 @@
|
|||
"type": "module",
|
||||
"private": true,
|
||||
"bin": {
|
||||
"lmc": "out/index.js",
|
||||
"ttsc": "out/tts.js"
|
||||
"lmc": "dist/index.js",
|
||||
"ttsc": "dist/tts.js"
|
||||
},
|
||||
"scripts": {
|
||||
"dev": "bun run index.ts",
|
||||
"prod": "bun run out/index.js",
|
||||
"check": "bunx --bun @biomejs/biome check --write && bun run tc",
|
||||
"build:js": "bun run check && bun run --parallel build:bundle build:tts && bun run --parallel shebang shebang:tts",
|
||||
"build:bundle": "bun build --target=bun --production --sourcemap --outdir=out index.ts",
|
||||
"build:tts": "bun build --target=bun --production --sourcemap --outdir=out tts.ts",
|
||||
"build:bin": "bun build --compile --outfile=out/lmc index.ts",
|
||||
"shebang": "sed -i '1i#!\\/usr\\/bin\\/env bun' out/index.js",
|
||||
"shebang:tts": "sed -i '1i#!\\/usr\\/bin\\/env bun' out/tts.js",
|
||||
"dev": "tsx index.ts",
|
||||
"prod": "node dist/index.js",
|
||||
"check": "biome check --write && pnpm run tc",
|
||||
"build": "pnpm run check && pnpm run bundle",
|
||||
"bundle": "esbuild index.ts --bundle --outdir=dist --platform=node --target=node18 --format=esm --packages=external",
|
||||
"tc": "tsc --noEmit --incremental"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@biomejs/biome": "2.4.12",
|
||||
"@types/bun": "latest"
|
||||
"@types/bun": "latest",
|
||||
"esbuild": "0.28.0"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"typescript": "^5"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue