File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11name : Build release
22
33on :
4+ workflow_dispatch :
45 push :
56 branches :
67 - main
@@ -26,26 +27,38 @@ jobs:
2627 with :
2728 app-id : ${{ env.DEPLOYMENT_APP_ID }}
2829 private-key : ${{ secrets.DEPLOYMENT_APP_PRIVATE_KEY }}
29- - name : Checkout Git repository
30+
31+ - name : Checkout
32+ id : checkout
3033 uses : actions/checkout@v4
31- - name : Install pnpm
32- uses : pnpm/action-setup@v4
3334 with :
34- version : 9
35- - name : Install Node.js
36- uses : actions/setup-node@v4
35+ token : ${{ steps.app-token.outputs.token }}
36+ fetch-depth : 1 # shallow copy
37+
38+ - name : Fetch Refs
39+ run : |
40+ git fetch origin --depth 1 ${{ github.ref_name }}
41+
42+ - uses : actions/setup-node@v4
3743 with :
38- node-version : 20.x
39- registry-url : https://registry.npmjs.org
40- cache : pnpm
41- - name : Install dependencies
42- run : pnpm install
44+ node-version-file : package.json
45+ registry-url : ' https://registry.npmjs.org'
46+
47+ # Ensure npm 11.5.1 or later is installed - required for OIDC
48+ - name : Update npm
49+ run : npm install -g npm@latest
50+
4351 - name : Build release artifact
44- run : pnpm run build
52+ run : |
53+ cd packages/cli
54+ npm run publish
55+
4556 - name : Get package version
4657 id : version
4758 run : |
59+ cd packages/cli
4860 echo "VERSION=$(npm run --silent version)" >> $GITHUB_OUTPUT
61+
4962 - name : Create Release
5063 id : create_release
5164 uses : actions/create-release@latest
5770 release_name : ${{ steps.version.outputs.VERSION }}
5871 draft : false
5972 prerelease : false
60- # Ensure npm 11.5.1 or later is installed - required for OIDC
61- - name : Update npm
62- run : npm install -g npm@latest
73+
6374 - name : Publish package
6475 run : |
6576 cd packages/cli
You can’t perform that action at this time.
0 commit comments