Skip to content

Commit

Permalink
Run workflow on PR merge
Browse files Browse the repository at this point in the history
  • Loading branch information
ryancooley committed Apr 28, 2024
1 parent 85181d1 commit 94ad9b9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/update.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
name: Publish Package

on:
push:
pull_request:
types: [closed]
branches:
- main

jobs:
publish:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- name: Checkout code
Expand All @@ -29,7 +31,7 @@ jobs:
run: npm version patch

- name: Push version change
run: git push --tags
run: git push && git push --tags

- name: Publish to npm
run: npm publish
Expand Down

0 comments on commit 94ad9b9

Please sign in to comment.