Skip to content

Commit

Permalink
ci: fix issue with release github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
bardisg committed Dec 14, 2022
1 parent f3f4a0f commit 82550c2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deploy-npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
deploy-tag:
name: Deploy to NPM
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/v') || startsWith(github.ref, 'refs/heads/main') || github.event.pull_request.merged == true
if: (startsWith(github.ref, 'refs/tags/v') || startsWith(github.ref, 'refs/heads/main')) || ((startsWith(github.event.pull_request.head.ref, 'release/') || startsWith(github.event.pull_request.head.ref, 'hotfix-release/')) && github.event.pull_request.merged == true) # only merged pull requests must trigger this job
steps:
- name: Checkout source branch
uses: actions/checkout@v3
Expand Down Expand Up @@ -57,7 +57,7 @@ jobs:
PROJECT_NAME: 'Gatsby Plugin Rudderstack'
NPM_PACKAGE_URL: 'https://www.npmjs.com/package/rudder-sdk-js'
with:
channel-id: ${{ secrets.SLACK_CHANNEL_ID }}
channel-id: ${{ secrets.SLACK_RELEASE_CHANNEL_ID }}
payload: |
{
"blocks": [
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish-new-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
release:
name: Publish new release
runs-on: ubuntu-latest
if: startsWith(github.event.pull_request.head.ref, 'main') || ((startsWith(github.event.pull_request.head.ref, 'release/') || startsWith(github.event.pull_request.head.ref, 'hotfix-release/')) && github.event.pull_request.merged == true) # only merged pull requests must trigger this job
if: startsWith(github.ref, 'refs/heads/main') || ((startsWith(github.event.pull_request.head.ref, 'release/') || startsWith(github.event.pull_request.head.ref, 'hotfix-release/')) && github.event.pull_request.merged == true) # only merged pull requests must trigger this job
steps:
- name: Extract version from branch name (for release branches)
id: extract-version
Expand Down Expand Up @@ -85,7 +85,7 @@ jobs:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
PROJECT_NAME: 'Gatsby Rudderstack Plugin'
with:
channel-id: ${{ secrets.SLACK_CHANNEL_ID }}
channel-id: ${{ secrets.SLACK_RELEASE_CHANNEL_ID }}
payload: |
{
"blocks": [
Expand Down

0 comments on commit 82550c2

Please sign in to comment.