From b29945a0dd82faef5c620d70a185e86a0d9f8556 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CLucas?= Date: Thu, 5 Oct 2023 10:41:27 -0300 Subject: [PATCH] refactor gitflow --- .github/worflows/ci.yml | 14 +++++++------- .github/worflows/publish.yml | 18 ++++-------------- 2 files changed, 11 insertions(+), 21 deletions(-) diff --git a/.github/worflows/ci.yml b/.github/worflows/ci.yml index ee587484..b1dfc53b 100644 --- a/.github/worflows/ci.yml +++ b/.github/worflows/ci.yml @@ -1,19 +1,19 @@ -name: Node.js CI +name: CI on: push: - branches: [ "master", "master-v2" ] + branches: [ "master" ] pull_request: - branches: [ "*" ] + branches: [ "master" ] jobs: - build: - + test: + name: Test on Node v${{ matrix.node-version }} runs-on: ubuntu-latest strategy: matrix: - node-version: [12.x, 14.x, 16.x, 18.x] + node-version: [12.x, 14.x, 16.x, 18.x, 19.x] steps: - uses: actions/checkout@v3 @@ -22,5 +22,5 @@ jobs: with: node-version: ${{ matrix.node-version }} cache: 'npm' - - run: npm ci + - run: npm ci --legacy-peer-deps - run: npm test diff --git a/.github/worflows/publish.yml b/.github/worflows/publish.yml index 14e43784..bd711ed7 100644 --- a/.github/worflows/publish.yml +++ b/.github/worflows/publish.yml @@ -1,22 +1,11 @@ -name: Node.js Publish Package +name: Publish to NPM on: release: types: [created] jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 18 - - run: npm ci - - run: npm test - - publish-npm: - needs: build + publish: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 @@ -24,7 +13,8 @@ jobs: with: node-version: 18 registry-url: https://registry.npmjs.org/ - - run: npm ci + - run: npm ci --legacy-peer-deps + - run: npm run build - run: npm publish env: NODE_AUTH_TOKEN: ${{secrets.npm_token}}