File tree Expand file tree Collapse file tree 4 files changed +60
-3
lines changed
src/templates/backend/fastify Expand file tree Collapse file tree 4 files changed +60
-3
lines changed Original file line number Diff line number Diff line change 1+ name : Release
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+
8+ concurrency : ${{ github.workflow }}-${{ github.ref }}
9+
10+ permissions : {} # reset
11+
12+ jobs :
13+ release :
14+ name : Release
15+ # IMPORTANT: prevent this action from running on forks
16+ if : github.repository == 'victormicco/todoroki'
17+ permissions :
18+ contents : write # to create release (changesets/action)
19+ pull-requests : write # to create pull request (changesets/action)
20+ runs-on : ubuntu-latest
21+ strategy :
22+ matrix :
23+ node-version : [lts/*]
24+ steps :
25+ - name : Checkout Repo
26+ uses : actions/checkout@v4
27+ with :
28+ fetch-depth : 0
29+
30+ - uses : pnpm/action-setup@v3
31+ with :
32+ version : 8.15.5
33+
34+ - name : Use Node.js ${{ matrix.node-version }}
35+ uses : actions/setup-node@v4
36+ with :
37+ node-version : ${{ matrix.node-version }}
38+ cache : " pnpm"
39+
40+ - name : Install dependencies
41+ run : pnpm install --frozen-lockfile --ignore-scripts
42+
43+ - name : Build project
44+ run : pnpm run build
45+
46+ - name : Publish to npm
47+ id : changesets
48+ uses : changesets/action@v1
49+ with :
50+ publish : pnpm release
51+ commit : " chore: new release"
52+ env :
53+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
54+ NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
Original file line number Diff line number Diff line change 11node_modules
2- dist
2+ dist
3+ .env
Original file line number Diff line number Diff line change 77 "main" : " index.js" ,
88 "scripts" : {
99 "dev" : " tsc -w" ,
10- "build" : " tsc " ,
10+ "build" : " tsup " ,
1111 "postbuild" : " echo '#!/usr/bin/env node' | cat - dist/index.js > temp && mv temp dist/index.js" ,
1212 "link-cli" : " (yarn --global unlink practice-cli || true) && chmod +x ./dist/index.js && yarn --global link" ,
13- "lint" : " pnpm biome check --write"
13+ "lint" : " pnpm biome check --write" ,
14+ "release" : " pnpm build && changeset publish"
1415 },
1516 "keywords" : [],
1617 "author" : " victormicco" ,
Original file line number Diff line number Diff line change 1616 "test:debug" : " vitest --inspect-brk --inspect --logHeapUsage --threads=false" ,
1717 "test:e2e" : " vitest run --config ./vitest-e2e-config.ts" ,
1818 "type-check" : " tsc"
19+
1920 },
2021 "devDependencies" : {
2122 "@biomejs/biome" : " ^1.6.3" ,
You can’t perform that action at this time.
0 commit comments