Skip to content

Commit a7b3992

Browse files
author
Alex Wang
committed
chore: do not send slack notification for draft
1 parent eddaf15 commit a7b3992

1 file changed

Lines changed: 2 additions & 6 deletions

File tree

.github/workflows/notify_slack.yml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,14 @@ on:
44
issues:
55
types: [opened, reopened]
66
pull_request_target:
7-
types: [opened, reopened]
7+
types: [opened, reopened, ready_for_review]
88

99
permissions: {}
1010

1111
jobs:
1212
notify:
1313
runs-on: ubuntu-latest
1414
steps:
15-
- name: Use Node.js
16-
uses: actions/setup-node@v6
17-
with:
18-
node-version: '24.x'
1915
- name: Send issue notification to Slack
2016
if: github.event_name == 'issues'
2117
uses: slackapi/slack-github-action@45a88b9581bfab2566dc881e2cd66d334e621e2c # v3.0.3
@@ -30,7 +26,7 @@ jobs:
3026
}
3127
3228
- name: Send pull request notification to Slack
33-
if: github.event_name == 'pull_request_target'
29+
if: github.event_name == 'pull_request_target' && github.event.pull_request.draft == false
3430
uses: slackapi/slack-github-action@45a88b9581bfab2566dc881e2cd66d334e621e2c # v3.0.3
3531
with:
3632
webhook: ${{ secrets.SLACK_WEBHOOK_URL_PR }}

0 commit comments

Comments
 (0)