Skip to content

Commit

Permalink
feat(projects): use tsup replace unbuild
Browse files Browse the repository at this point in the history
  • Loading branch information
honghuangdc committed Jan 13, 2024
1 parent 5876728 commit bf99840
Show file tree
Hide file tree
Showing 7 changed files with 370 additions and 1,105 deletions.
14 changes: 0 additions & 14 deletions build.config.ts

This file was deleted.

10 changes: 6 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,18 @@
"module": "./dist/index.mjs",
"types": "./dist/index.d.ts",
"files": ["dist"],
"engines": {
"node": ">=14"
},
"scripts": {
"build": "unbuild && pnpm build-pkg",
"build": "tsup && pnpm build-pkg",
"build-pkg": "pnpm -r --filter='./packages/*' run build",
"cleanup": "soy cleanup",
"commit": "soy git-commit",
"lint": "eslint . --fix",
"prepare": "simple-git-hooks",
"publish-pkg": "pnpm -r publish --access public",
"release": "soy release",
"stub": "pnpm unbuild --stub",
"typecheck": "tsc --noEmit --skipLibCheck",
"update-pkg": "soy ncu"
},
Expand All @@ -60,9 +62,9 @@
"eslint": "8.56.0",
"lint-staged": "15.2.0",
"simple-git-hooks": "2.9.0",
"tsup": "^8.0.1",
"tsx": "4.7.0",
"typescript": "5.3.3",
"unbuild": "2.0.0"
"typescript": "5.3.3"
},
"simple-git-hooks": {
"commit-msg": "pnpm soy git-commit-verify",
Expand Down
10 changes: 0 additions & 10 deletions packages/githublogen/build.config.ts

This file was deleted.

10 changes: 4 additions & 6 deletions packages/githublogen/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,14 @@
},
"sideEffects": false,
"bin": {
"githublogen": "./dist/cli.mjs"
"githublogen": "./dist/cli.js"
},
"files": ["dist"],
"engines": {
"node": ">=12.0.0"
"node": ">=14"
},
"scripts": {
"build": "unbuild",
"stub": "pnpm unbuild --stub",
"build": "tsup",
"typecheck": "tsc --noEmit --skipLibCheck"
},
"dependencies": {
Expand All @@ -44,7 +43,6 @@
"devDependencies": {
"@soybeanjs/cli": "1.0.1",
"@types/node": "20.11.0",
"typescript": "5.3.3",
"unbuild": "2.0.0"
"typescript": "5.3.3"
}
}
12 changes: 12 additions & 0 deletions packages/githublogen/tsup.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { defineConfig } from 'tsup';

export default defineConfig({
entry: ['src/cli.ts'],
clean: true,
dts: true,
format: ['esm'],
shims: true,
cjsInterop: true,
target: 'node14'
// minify: true
});
Loading

0 comments on commit bf99840

Please sign in to comment.