-
Notifications
You must be signed in to change notification settings - Fork 34
48 lines (38 loc) · 1014 Bytes
/
new.yml
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
name: Automatic Commit
on:
# push推送时触发
push:
# 定时任务触发
schedule:
# 每天北京时间1点运行
- cron: '0 1 * * *'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install
run: pip install requests wget
- name: Update
run: python ./scripts/tools/adblock.py
- name: Commit
env:
TZ: Asia/Shanghai
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add -A
git commit -m \
":pencil: Update at \
$(date +"%Y-%m-%d %H:%M") \
"
- name: Push
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.PRIVATE_TOKEN }}