-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
422f02a
commit 5732fc4
Showing
1 changed file
with
39 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: Update Blacklist Stats | ||
|
||
on: | ||
schedule: | ||
# Run once a day at midnight UTC | ||
- cron: '0 0 * * *' | ||
workflow_dispatch: # Allows manual triggering | ||
|
||
jobs: | ||
update_stats: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.11' | ||
|
||
- name: Install dependencies | ||
run: | | ||
pip install --upgrade pip | ||
- name: Download blacklist file | ||
run: wget -O blacklist.txt https://github.com/fabriziosalmi/blacklists/releases/download/latest/blacklist.txt | ||
|
||
- name: Generate stats and update markdown | ||
run: | | ||
python scripts/generate_stats.py | ||
- name: Commit and push changes | ||
uses: EndBug/add-and-commit@v7 | ||
with: | ||
author_name: 'GitHub Action' | ||
author_email: '[email protected]' | ||
message: 'Update blacklist stats' | ||
add: 'stats.md' |