-
Notifications
You must be signed in to change notification settings - Fork 72
57 lines (57 loc) · 1.91 KB
/
labeler.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: Issue and PRs Labeler
on:
issues:
types: [opened, edited]
pull_request:
types:
- opened
- reopened
- synchronize
- ready_for_review
jobs:
labeler:
name: Add Label to PRs and Issues
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write # Needed by labeler
issues: write # Needed by labeler
steps:
- name: Checkout repo
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Add Labels
uses: srvaroa/labeler@1eec6d9e7c5fa5864840279978680302f955fc37
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
with:
config_path: .github/labeler.yaml
use_local_config: true
slack-notification-doc-team:
needs: labeler
if: ${{ github.event.label.name == 'need-doc-review' }}
runs-on: ubuntu-latest
permissions:
pull-requests: write # Needed by sticky-pull-request-comment
steps:
- uses: slackapi/slack-github-action@70cd7be8e40a46e8b0eced40b0de447bdb42f68e
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL_DOCS }}
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK
with:
payload: |
{
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "hey ${{ secrets.SLACK_DOCS_TAG }}, this is APIx Bot :aileafy:, could you please review <${{ github.event.pull_request.html_url }}|PR ${{ github.event.pull_request.number }}> :pretty-please:? thanks a lot!"
}
}
]
}
- uses: marocchino/sticky-pull-request-comment@331f8f5b4215f0445d3c07b4967662a32a2d3e31
with:
header: pr-title-slack-doc
append: true
message: "APIx Bot :bowtie:: a message has been sent to Docs Slack channel :rocket:."