From 508003d9d37508b87dbbc03dcba47d048fdaa57e Mon Sep 17 00:00:00 2001 From: Cole Bemis Date: Tue, 29 Mar 2022 16:07:02 -0700 Subject: [PATCH 1/4] chore: Add ci.yml workflow --- .github/workflows/ci.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..a91dbfa --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,19 @@ +name: CI + +on: push + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Use Node.js 16.x + uses: actions/setup-node@v3 + with: + node-version: 16.x + cache: 'npm' + - run: npm ci + - run: npm run all + - name: Release + if: github.ref_name == 'master' + run: npx semantic-release From d657e8aa5601558d5d74e0406361c84c2bb8760a Mon Sep 17 00:00:00 2001 From: Cole Bemis Date: Tue, 29 Mar 2022 16:15:31 -0700 Subject: [PATCH 2/4] Add env variables --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a91dbfa..7e9fa22 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,3 +17,6 @@ jobs: - name: Release if: github.ref_name == 'master' run: npx semantic-release + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} From 7da295065337e6f27f249b4e0f8a6d3eef915286 Mon Sep 17 00:00:00 2001 From: Cole Bemis Date: Tue, 29 Mar 2022 16:23:24 -0700 Subject: [PATCH 3/4] Remove GITHUB_TOKEN env variable --- .github/workflows/ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7e9fa22..9afbf55 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,5 +18,4 @@ jobs: if: github.ref_name == 'master' run: npx semantic-release env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }} From a7e39d665f2ac4f62f5392c75e76b9249563e8a4 Mon Sep 17 00:00:00 2001 From: Cole Bemis Date: Tue, 29 Mar 2022 16:30:25 -0700 Subject: [PATCH 4/4] Update GITHUB_TOKEN permissions --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9afbf55..b03fb4f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,4 +18,5 @@ jobs: if: github.ref_name == 'master' run: npx semantic-release env: + GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }}