Skip to content

Commit

Permalink
chore: Fix publishing to npm registry
Browse files Browse the repository at this point in the history
  • Loading branch information
SvanBoxel committed Sep 23, 2019
1 parent c2304de commit 0c58022
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,20 @@ jobs:

release-and-deploy:
name: Release to NPM registry
if: github.ref == 'master'
needs: [build-and-test, sonarcloud-scan]
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
steps:
- uses: actions/checkout@v1
- name: publish and deploy
- name: publish
run: |
npm install
npm run semantic-release
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: deploy
run: |
now="npx now --debug --token=$NOW_TOKEN"
echo "$ now rm --safe --yes delete-merged-branch"
$now rm --safe --yes delete-merged-branch
Expand All @@ -56,6 +61,6 @@ jobs:
echo "$ now alias"
$now alias
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NOW_TOKEN: ${{ secrets.NOW_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 0c58022

Please sign in to comment.