Skip to content

Commit

Permalink
Do not publish if not main branch
Browse files Browse the repository at this point in the history
  • Loading branch information
dahlia committed Apr 26, 2024
1 parent 5b6d761 commit d99575c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,13 @@ jobs:
files: npm/*.tgz
generate_release_notes: false
discussion_category_name: Announcements
- if: github.event_name == 'push'
- if: |
github.event_name == 'push' &&
github.ref_type == 'tag' || github.ref == 'refs/heads/main'
run: deno task publish --allow-dirty
- if: github.event_name == 'push'
- if: |
github.event_name == 'push' &&
github.ref_type == 'tag' || github.ref == 'refs/heads/main'
run: |
set -ex
npm config set //registry.npmjs.org/:_authToken "$NPM_AUTH_TOKEN"
Expand Down

0 comments on commit d99575c

Please sign in to comment.