File tree Expand file tree Collapse file tree 1 file changed +40
-0
lines changed Expand file tree Collapse file tree 1 file changed +40
-0
lines changed Original file line number Diff line number Diff line change 1+ name : " npm"
2+
3+ on :
4+ workflow_run :
5+ workflows :
6+ - " Release"
7+ types :
8+ - completed
9+ permissions :
10+ contents : read
11+ jobs :
12+ pack :
13+ if : ${{ github.event_name == 'release' && github.event.action == 'published' }}
14+ name : " Pack"
15+ runs-on : ubuntu-latest
16+ steps :
17+ # Checkout
18+ - name : Checkout
19+ uses : actions/checkout@v5
20+ with :
21+ fetch-depth : 0
22+ # Setup Bun
23+ - uses : oven-sh/setup-bun@v2
24+ with :
25+ bun-version : 1.3.1
26+ # Install dependencies
27+ - name : Install dependencies
28+ run : bun install
29+ # Set Version
30+ - name : Set TAG variable
31+ run : echo "TAG=${{ github.event.release.tag_name }}" >> $GITHUB_ENV
32+ - name : Set VERSION variable
33+ run : echo "VERSION=${TAG#v}" >> $GITHUB_ENV
34+ - name : Set Version
35+ run : npm version $VERSION --no-git-tag-version
36+ # Publish
37+ - name : Publish
38+ run : npm publish --access public
39+ env :
40+ NPM_CONFIG_TOKEN : ${{ secrets.NPM_TOKEN }}
You can’t perform that action at this time.
0 commit comments