From cd40939a3bdfe40967827631d699919e397e0ffd Mon Sep 17 00:00:00 2001 From: Marc Gutenberger Date: Sat, 21 Oct 2023 18:44:47 -0500 Subject: [PATCH] Update CI --- .github/workflows/ci.yml | 3 +++ .github/workflows/npm-publish.yml | 11 +++++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5ef773f..ebf4ab8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,9 @@ on: pull_request: branches: ["main"] +env: + WAKATIME_API_KEY: ${{secrets.wakatime_api_key}} + jobs: build: runs-on: ubuntu-latest diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 6cdebaf..d02431b 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -4,8 +4,13 @@ name: Node.js Package on: - release: - types: [created] + push: # Publish `main` branch to npm on release + branches: + - main + +env: + NODE_AUTH_TOKEN: ${{secrets.npm_token}} + WAKATIME_API_KEY: ${{secrets.wakatime_api_key}} jobs: build: @@ -29,5 +34,3 @@ jobs: registry-url: https://registry.npmjs.org/ - run: npm ci - run: npm publish - env: - NODE_AUTH_TOKEN: ${{secrets.npm_token}}