From 938624ae038f9900c58bab990abfd6489346b8d9 Mon Sep 17 00:00:00 2001 From: pllearns Date: Tue, 7 Jan 2020 16:23:45 -0800 Subject: [PATCH 1/2] fix release workflow to get gpr-npm to work --- .github/workflows/actions.yml | 5 ++++- .github/workflows/release.yml | 38 ++++++++++++++++++++--------------- .npmrc | 2 +- 3 files changed, 27 insertions(+), 18 deletions(-) diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml index 0aa7ba88..ac92b514 100644 --- a/.github/workflows/actions.yml +++ b/.github/workflows/actions.yml @@ -1,6 +1,9 @@ name: CI -on: [push] +on: + push: + branches-ignore: + - 'master' jobs: build: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e2112a77..364c8e2f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,21 +6,27 @@ on: - 'v*' jobs: - build: + build: runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v1 + steps: + - uses: actions/checkout@v2 - uses: actions/setup-node@v1 - with: - node-version: 10.15.0 - registry-url: https://npm.pkg.github.com/ - scope: '@xyoraclenetwork' - - name: Build and Test - run: | - yarn install - yarn build - yarn test - - name: publish - run: yarn publish - env: - NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} \ No newline at end of file + with: + node-version: 10.15.0 + - run: npm ci + - run: npm test + + publish-gpr: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v1 + with: + node-version: 10.15.0 + registry-url: https://npm.pkg.github.com/ + scope: '@xyoraclenetwork' + - run: npm ci + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} \ No newline at end of file diff --git a/.npmrc b/.npmrc index 9d0b3731..d751d01f 100644 --- a/.npmrc +++ b/.npmrc @@ -1 +1 @@ -registry=https://npm.pkg.github.com/@xyoraclenetwork \ No newline at end of file +registry=https://npm.pkg.github.com/ \ No newline at end of file From fbe14add92a8448afdf42b5ea7ac48c7f36a4d4f Mon Sep 17 00:00:00 2001 From: pllearns Date: Tue, 7 Jan 2020 16:25:35 -0800 Subject: [PATCH 2/2] syntax fix --- .github/workflows/release.yml | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 364c8e2f..a01a1c8a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -17,16 +17,16 @@ jobs: - run: npm test publish-gpr: - needs: build - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 - with: - node-version: 10.15.0 - registry-url: https://npm.pkg.github.com/ - scope: '@xyoraclenetwork' - - run: npm ci - - run: npm publish - env: - NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} \ No newline at end of file + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v1 + with: + node-version: 10.15.0 + registry-url: https://npm.pkg.github.com/ + scope: '@xyoraclenetwork' + - run: npm ci + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} \ No newline at end of file