-
Notifications
You must be signed in to change notification settings - Fork 1
36 lines (31 loc) · 969 Bytes
/
Copy pathnotify.yml
File metadata and controls
36 lines (31 loc) · 969 Bytes
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
name: Send Commit Notification
on:
push:
branches:
- main
jobs:
notify:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
cache-dependency-path: 'scripts/requirements.txt'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r scripts/requirements.txt
- name: Send CV2 Webhook
env:
IMGBB_API_KEY: ${{ secrets.IMGBB_API_KEY }}
run: |
python3 scripts/send_cv2_webhook.py \
"${{ secrets.DISCORD_WEBHOOK }}" \
"${{ github.event.head_commit.author.name }}" \
"${{ github.event.head_commit.message }}" \
"${{ github.sha }}" \
"${{ github.event.repository.html_url }}" \
"${{ github.event.head_commit.url }}"