Update blocklist #118
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
on: | |
workflow_dispatch: | |
push: | |
paths: | |
- '**.txt' | |
name: Update lists with ABP syntax | |
jobs: | |
abp-syntax: | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout repo content | |
uses: actions/checkout@v3 | |
- name: create ABP lists | |
run: | | |
sed 's/^/\|\|/;s/$/\^/' blocklist.txt > blocklist_ABP.txt | |
sed 's/^/\|\|/;s/$/\^$all/' blocklist.txt > blocklist_UBO.txt | |
sed 's/^/*:\/\/*./;s/$/\/*/' blocklist.txt > blocklist_UBL.txt | |
- name: commit files | |
run: | | |
git config --local user.email "action@github.com" | |
git config --local user.name "GitHub Action" | |
git add -A | |
git diff --name-only --cached --exit-code || ( git commit -am "Update ABP blocklists" && git push ) |