Skip to content

Commit

Permalink
feat: update github actions (#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
onildoaguiar authored Dec 15, 2019
1 parent c4dd8fe commit f31c879
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 17 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/githubpackagespublish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: GitHub Packages

on:
release:
types: [created]

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

publish-github-packages:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12
registry-url: https://npm.pkg.github.com/
scope: '@onildoaguiar'
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.github_packages_token}}
19 changes: 2 additions & 17 deletions .github/workflows/npmpublish.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Node.js Package
name: NPM Package

on:
release:
Expand Down Expand Up @@ -27,19 +27,4 @@ jobs:
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}

publish-gpr:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12
registry-url: https://npm.pkg.github.com/
scope: '@your-github-username'
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.github_packages_token}}
NODE_AUTH_TOKEN: ${{secrets.npm_token}}

0 comments on commit f31c879

Please sign in to comment.