File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change 9494
9595 - name : Push image
9696 run : docker push ghcr.io/${{ github.repository }}:latest
97+
98+ release :
99+ name : Release
100+ runs-on : ubuntu-latest
101+ needs : test
102+ if : startsWith(github.ref, 'refs/tags/v')
103+ permissions :
104+ contents : write
105+ steps :
106+ - name : Checkout code
107+ uses : actions/checkout@v3
108+ with :
109+ fetch-depth : 0
110+
111+ - name : Use Node.js 18
112+ uses : actions/setup-node@v3
113+ with :
114+ node-version : ' 18'
115+ registry-url : ' https://registry.npmjs.org/'
116+
117+ - name : Install dependencies
118+ run : npm install
119+
120+ - name : Publish to npm
121+ run : npm publish --access public
122+ env :
123+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
124+
125+ - name : Create GitHub Release
126+ uses : softprops/action-gh-release@v2
127+ with :
128+ generate_release_notes : true
129+ env :
130+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments