-
Notifications
You must be signed in to change notification settings - Fork 0
44 lines (35 loc) · 1.1 KB
/
notify.yml
File metadata and controls
44 lines (35 loc) · 1.1 KB
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
name: Notify
on:
push:
branches:
- main
- develop
pull_request:
types: [opened, closed, reopened, merged]
issues:
types: [opened, closed, reopened]
env:
NODE_VERSION: 20
TELEGRAM_BOT_TOKEN: ${{ secrets.TELEGRAM_BOT_TOKEN }}
TELEGRAM_CHAT_ID: ${{ secrets.TELEGRAM_CHAT_ID }}
GITHUB_ACTOR: ${{ github.actor }}
GITHUB_EVENT_NAME: ${{ github.event_name }}
GITHUB_REPOSITORY: ${{ github.repository }}
GITHUB_REF: ${{ github.ref }}
GITHUB_SHA: ${{ github.sha }}
GITHUB_EVENT_PATH: ${{ github.event_path }}
jobs:
telegram-notify:
name: Telegram Notification
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
- name: Install dependencies
run: npm install node-fetch
- name: Send Telegram notification
run: node scripts/telegram-notify.js