From 778d0d98bba94c2b56026243de360f4dda6c3977 Mon Sep 17 00:00:00 2001 From: Michael Amaral Date: Sun, 19 Jul 2020 18:42:58 -0300 Subject: [PATCH] added Github Packages to publish workflow --- .github/workflows/publish.yml | 24 ++++++++++++++++-------- package.json | 2 +- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index c0eae7b..61b71a4 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -7,19 +7,27 @@ on: jobs: publish: runs-on: ubuntu-latest - name: Publish to npm steps: - - name: Checkout Repo - uses: actions/checkout@master - - name: Setup Node - uses: actions/setup-node@v1 + - uses: actions/checkout@v2 + # Setup .npmrc file to publish to npm + - uses: actions/setup-node@v1 with: - node-version: 13 - registry-url: https://registry.npmjs.org/ + node-version: '14.x' + registry-url: 'https://registry.npmjs.org/' - name: Install - run: yarn install + run: npm install + # Publish to npm - name: Publish run: npm publish env: NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} + # Setup .npmrc file to publish to GitHub Packages + - uses: actions/setup-node@v1 + with: + registry-url: 'https://npm.pkg.github.com' + scope: '@platformbuilders' + # Publish to GitHub Packages + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/package.json b/package.json index 212861a..5fab6c9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@platformbuilders/helpers", - "version": "0.2.1", + "version": "0.2.2", "description": "Platfom builders helpers library", "main": "dist/index.js", "types": "dist/index.d.ts",