File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed
Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change 3434 env :
3535 INTERCOM_API_KEY : ${{ secrets.INTERCOM_API_KEY }}
3636
37+ publish :
38+ needs : [ compile, test ]
39+ if : github.event_name == 'push' && contains(github.ref, 'refs/tags/')
40+ runs-on : ubuntu-latest
41+ steps :
42+ - name : Checkout repo
43+ uses : actions/checkout@v3
44+ - name : Set up node
45+ uses : actions/setup-node@v3
46+ - name : Install dependencies
47+ run : yarn install
48+ - name : Build
49+ run : yarn build
50+
51+ - name : Publish to npm
52+ run : |
53+ npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN}
54+ if [[ ${GITHUB_REF} == *alpha* ]]; then
55+ npm publish --access public --tag alpha
56+ elif [[ ${GITHUB_REF} == *beta* ]]; then
57+ npm publish --access public --tag beta
58+ else
59+ npm publish --access public
60+ fi
61+ env :
62+ NPM_TOKEN : ${{ secrets.FERN_NPM_TOKEN }}
You can’t perform that action at this time.
0 commit comments