Skip to content

.github/workflows/iptv.yml #10

.github/workflows/iptv.yml

.github/workflows/iptv.yml #10

Workflow file for this run

name: up iptv
on:
# schedule:
# - cron: '0 10 * * *' # UTC时间10点,即北京时间18点
workflow_dispatch: # 允许手动触发工作流
jobs:
sync_files:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.10' # 使用Python 3.10版本
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install requests beautifulsoup4 PyGithub
- name: Run the main.py
run: |
python main.py
- name: List files
run: ls -la # 列出文件,方便调试
- name: Commit and push changes
run: |
git config --local user.email "csszue@gmail.com"
git config --local user.name "MemoryCollection"
git add *.txt
git commit -m "Sync TXT files" || echo "No changes to commit"
git push --force # 强制推送