diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 2177524d..3555615f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -2,6 +2,8 @@ name: Publish on: push: + branches: + - master paths-ignore: - README.md - .gitignore @@ -17,7 +19,7 @@ jobs: node-version: 12 - run: npm install - run: npm run test -- --coverage --watchAll=false - + - name: Setup GIT run: | git reset --hard @@ -26,8 +28,8 @@ jobs: git config user.email "$GH_EMAIL" git config user.name "Francisco Hodge" env: - GH_EMAIL: ${{secrets.GH_EMAIL}} - + GH_EMAIL: ${{secrets.GH_EMAIL}} + - name: Bump version run: | git reset --hard @@ -38,10 +40,10 @@ jobs: git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$GITHUB_REPOSITORY" env: GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} - + - name: npm publish run: | npm config set //registry.npmjs.org/:_authToken=$NODE_AUTH_TOKEN npm run trypublish env: - NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}} + NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}