Skip to content

update_hosts.py

update_hosts.py #234

Workflow file for this run

name: update_hosts.py
on:
workflow_dispatch:
schedule:
- cron: 0 15 * * *
permissions: write-all
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: pip install requests
- name: Run update_hosts.py
env:
VIRUSTOTAL_API_KEY: ${{ secrets.VIRUSTOTAL_API_KEY }}
run: python update_hosts.py
- name: Commit & Push
run: |
git config user.email [email protected]
git config user.name github-actions
git add .
git commit -m "更新 APP 去广告 hosts"
git pull --rebase
git push
continue-on-error: true