Skip to content

Commit 676695e

Browse files
committed
Add new Persian Blocker sources
#74
1 parent 7692cf0 commit 676695e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

scripts/generate-ad-domains.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
#!/bin/bash
22

3-
gh api https://api.github.com/repos/MasterKia/PersianBlocker/contents/PersianBlockerHosts.txt -H "Accept: application/vnd.github.raw" | sed -e 's/^\(|\|\*\|\.\|\-\|0\.0\.0\.0\|127\.0\.0\.1\)*//g' -e 's/\^.*$//g' -e '/!\|?\|@\|#\|\*\|_\|\\\|\/\|\[\|]\|\[\|\([0-9]\{1,3\}\.\)\{3\}[0-9]\{1,3\}/d' -e '/\.$/d' -e '/^\s*$/d' | awk '{$1=$1};1' | dos2unix | idn2 --no-alabelroundtrip --no-tr46 | LC_ALL=C sort -u > ads.txt
4-
gh api https://api.github.com/repos/MasterKia/PersianBlocker/contents/PersianBlockerHosts.txt -H "Accept: application/vnd.github.raw" > category-ads-all-raw.txt
3+
gh api https://api.github.com/repos/MasterKia/PersianBlocker/contents/PersianBlockerAds-Domains.txt -H "Accept: application/vnd.github.raw" > ads-raw.txt
4+
gh api https://api.github.com/repos/MasterKia/PersianBlocker/contents/PersianBlockerTrackers-Domains.txt -H "Accept: application/vnd.github.raw" >> ads-raw.txt
5+
cat ads-raw.txt | sed -e 's/^\(|\|\*\|\.\|\-\|0\.0\.0\.0\|127\.0\.0\.1\)*//g' -e 's/\^.*$//g' -e '/!\|?\|@\|#\|\*\|_\|\\\|\/\|\[\|]\|\[\|\([0-9]\{1,3\}\.\)\{3\}[0-9]\{1,3\}/d' -e '/\.$/d' -e '/^\s*$/d' | awk '{$1=$1};1' | dos2unix | idn2 --no-alabelroundtrip --no-tr46 | LC_ALL=C sort -u > ads.txt
6+
cat ads-raw.txt > category-ads-all-raw.txt
57
gh api https://api.github.com/repos/hagezi/dns-blocklists/contents/wildcard/light-onlydomains.txt -H "Accept: application/vnd.github.raw" >> category-ads-all-raw.txt
68
gh api https://api.github.com/repos/jerryn70/GoodbyeAds/contents/Extension/GoodbyeAds-Samsung-AdBlock.txt -H "Accept: application/vnd.github.raw" >> category-ads-all-raw.txt
79
gh api https://api.github.com/repos/jerryn70/GoodbyeAds/contents/Extension/GoodbyeAds-Xiaomi-Extension.txt -H "Accept: application/vnd.github.raw" >> category-ads-all-raw.txt

0 commit comments

Comments
 (0)