-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (31 loc) · 1.01 KB
/
random.yml
File metadata and controls
36 lines (31 loc) · 1.01 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
name: Random Dare
# every month on the first day at 00:00
on:
schedule:
- cron: '0 0 1 * *'
workflow_dispatch:
jobs:
radom_dare:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install
run: pip install -r requirements.txt
- name: Random Dare
env:
# GH_TOKEN needs repo + read:project + project scopes
GH_TOKEN: ${{ secrets.GH_TOKEN }}
TELEGRAM_BOT_TOKEN: ${{ secrets.TELEGRAM_BOT_TOKEN }}
TELEGRAM_CHANNEL_ID: ${{ secrets.TELEGRAM_CHANNEL_ID }}
run: python3 rand.py
- name: Commit
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: |
git config --local user.email "i@niracler.com"
git config --local user.name "niracler"
git add README.md table.csv
git commit -m "docs: random dare $(date +'%Y-%m-%d')"
git remote set-url origin "https://$GH_TOKEN@github.com/niracler/random.git"
git push origin main