Skip to content

Commit d94942e

Browse files
committed
pr review
1 parent 39f18ee commit d94942e

1 file changed

Lines changed: 32 additions & 0 deletions

File tree

.github/workflows/pr_review.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: PR Notifications
2+
3+
on:
4+
pull_request_target:
5+
branches: [main]
6+
types: [opened, synchronize, edited, reopened, ready_for_review]
7+
8+
permissions:
9+
contents: read
10+
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.ref }}
13+
cancel-in-progress: true
14+
15+
jobs:
16+
check-needs:
17+
runs-on: ubuntu-latest
18+
if: github.event.pull_request.draft != true
19+
20+
notify:
21+
runs-on: ubuntu-latest
22+
needs: [check-needs]
23+
steps:
24+
- shell: bash
25+
run: |
26+
MESSAGE="\
27+
MR [!${{ github.event.pull_request.id }}](${{ github.event.pull_request.url }}) \
28+
от [!${{ github.event.pull_request.user.login }} (${{ github.event.pull_request.user.name }})]\
29+
(${{ github.event.pull_request.user.url }}) \
30+
(ветка: [${{ github.event.pull_request.head.ref }}]\
31+
(${{ github.event.pull_request.head.repo.branches_url }}) готов на ревью.\n
32+
curl -X POST -H "Content-Type: application/json" -d "{\"text\": \"$MESSAGE\"}" "${{ secrets.BUILD_CHAT_WEBHOOK }}"

0 commit comments

Comments
 (0)