Andrew's git
/
scripts.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
Merge branch 'master' of /tank/andrew/code/scripts
author
Andrew Lorimer
<andrew@charles.cortex>
Mon, 24 Dec 2018 04:22:02 +0000
(15:22 +1100)
committer
Andrew Lorimer
<andrew@charles.cortex>
Mon, 24 Dec 2018 04:22:02 +0000
(15:22 +1100)
update-blocklist.sh
patch
|
blob
|
history
raw
(from parent 1:
f63497a
)
diff --git
a/update-blocklist.sh
b/update-blocklist.sh
index 7630cc306ce7f94c3c16715665438df524a3ae00..2c1207073a8a4f4384609a1a4f4537758ccefad1 100644
(file)
--- a/
update-blocklist.sh
+++ b/
update-blocklist.sh
@@
-1,10
+1,10
@@
# simple blacklist updater for OpenWRT
-#! /bin/
ba
sh
+#! /bin/sh
set -e
-blacklist=http
://www.squidblacklist.org/downloads/dg-ads.acl
+blacklist=http
s://v.firebog.net/hosts/Easylist.txt
mkdir -p /tmp/dnsmasq-blocklist
-curl -s --max-filesize 20M -o /tmp/dnsmasq-blocklist/sbl-dg-ads.hosts
-$blacklist
+wget --cut-dirs=100 -np -nH -O /tmp/dnsmasq-blocklist/ads $blacklist
+sed -i -e 's/^/0.0.0.0 /' /tmp/dnsmasq-blocklist/ads
/etc/init.d/dnsmasq restart