-
Notifications
You must be signed in to change notification settings - Fork 49
35 lines (29 loc) · 897 Bytes
/
node.yml
File metadata and controls
35 lines (29 loc) · 897 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
name: Fetch Files from passcro
on:
workflow_dispatch:
schedule:
- cron: '0 */4 * * *' # 每4小时运行一次
jobs:
fetch_files:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.8.x'
- name: Install dependencies
run: |
pip install requests pyyaml
- name: Fetch files from passcro
run: python python/node.py
- name: Commit and push changes
run: |
git config --local user.email "actions@gmail.com"
git config --local user.name "GitHub Action"
git add speednodes.yaml speednodes.txt sing-box.json meta.yaml
git commit -m "Fetch latest files from passcro" || echo "No changes to commit"
git push
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}