Skip to content

Commit

Permalink
Github Actions - Use Yarn instead of npm
Browse files Browse the repository at this point in the history
Signed-off-by: Mehmet Baker <mehmet@mehmetbaker.dev>
  • Loading branch information
mehmetb authored Mar 22, 2020
1 parent 90b1d97 commit 97fc7bb
Showing 1 changed file with 4 additions and 16 deletions.
20 changes: 4 additions & 16 deletions .github/workflows/npmpublish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,32 +8,20 @@ on:
types: [created]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12
- run: npm ci
- run: npm test

publish-npm:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12
registry-url: https://registry.npmjs.org/
- run: npm ci
- run: npm publish
- run: yarn
- run: yarn publish
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}

publish-gpr:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand All @@ -42,7 +30,7 @@ jobs:
node-version: 12
registry-url: https://npm.pkg.github.com/
scope: '@mehmetb'
- run: npm ci
- run: npm publish
- run: yarn
- run: yarn publish
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}

0 comments on commit 97fc7bb

Please sign in to comment.