Skip to content

Update AdBlock Rules Every 24 Hours #1387

Update AdBlock Rules Every 24 Hours

Update AdBlock Rules Every 24 Hours #1387

name: Update AdBlock Rules Every 24 Hours
on:
push:
branches: [ master ]
workflow_dispatch:
schedule:
- cron: '0 0 */1 * *'
jobs:
update-adblock-rules-then-push:
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/[email protected]
- name: Adguard Simplified Domain Names Filter
uses: carlosperate/[email protected]
with:
file-url: https://adguardteam.github.io/AdGuardSDNSFilter/Filters/filter.txt
file-name: AdGuard-Simplified-Domain-Names-Filter.txt
- name: EasyList China
uses: carlosperate/[email protected]
with:
file-url: https://easylist-downloads.adblockplus.org/easylistchina.txt
file-name: Easylist-China.txt
- name: EasyList Privacy
uses: carlosperate/[email protected]
with:
file-url: https://easylist.to/easylist/easyprivacy.txt
file-name: Easylist-Privacy.txt
- name: I dont care about cookies
uses: carlosperate/[email protected]
with:
file-url: https://www.i-dont-care-about-cookies.eu/abp/
file-name: I-dont-care-about-cookies.txt
- name: Commit Changes
run: |
if [ -z "$(git status --porcelain)" ]; then
exit 0
else
git add .
git config --local user.email "[email protected]"
git config --local user.name "github-action[bot]"
git commit -m "Updated at $(date)" -a
fi
- name: GitHub Push
uses: ad-m/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Purge CDN Cache
run: curl ${{ secrets.CDN_URL }}