File tree Expand file tree Collapse file tree 1 file changed +17
-10
lines changed Expand file tree Collapse file tree 1 file changed +17
-10
lines changed Original file line number Diff line number Diff line change 44 push :
55 branches :
66 - main
7- pull_request :
8- branches :
9- - main
107
118jobs :
129 versioning :
1310 runs-on : ubuntu-latest
1411 steps :
1512 # Checkout the code
1613 - name : Checkout code
17- uses : actions/checkout@v2
14+ uses : actions/checkout@v3
1815
1916 # Set up Node.js environment
2017 - name : Set up Node.js
2118 uses : actions/setup-node@v3
2219 with :
2320 node-version : ' 20'
21+ registry-url : ' https://registry.npmjs.org/'
2422
25- # Install dependencies
23+ # Install all dependencies (including devDependencies for lint/test/build)
2624 - name : Install dependencies
27- run : yarn install --frozen-lockfile --production
25+ run : yarn install
2826
2927 # Run linting
3028 - name : Run lint
@@ -38,19 +36,28 @@ jobs:
3836 - name : Build client
3937 run : yarn build-client
4038
39+ - name : Verify NPM_TOKEN
40+ run : |
41+ echo "NPM_TOKEN: $NPM_TOKEN"
42+ curl -H "Authorization: Bearer $NPM_TOKEN" https://registry.npmjs.org/-/whoami
43+
4144 # Semantic release step: Automatically determine the version and release
4245 - name : Semantic Release for versioning
4346 env :
4447 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
4548 NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
46- run : |
47- yarn release
49+ run : yarn release
4850
49- # Optionally, you can include a job to deploy to npm
5051 publish :
51- needs : release
52+ needs : versioning
5253 runs-on : ubuntu-latest
5354 steps :
55+ - name : Checkout code
56+ uses : actions/checkout@v3
57+
58+ - name : Install production dependencies
59+ run : yarn install --frozen-lockfile --production
60+
5461 # Publish to npm
5562 - name : Publish to npm
5663 run : yarn publish --non-interactive
You can’t perform that action at this time.
0 commit comments