summaryrefslogtreecommitdiffstats
path: root/retrieveAdBlocklists.sh
diff options
context:
space:
mode:
authorlookshe <github@lookshe.org>2019-03-16 13:20:01 +0100
committerlookshe <github@lookshe.org>2019-03-16 13:20:01 +0100
commitc9e52a5d16939c054eab947a3b66e9124e33773b (patch)
treebe3de051219dfc82cfdc4b6f9ab15198e1ba64f6 /retrieveAdBlocklists.sh
parentbfbd9ded98aae2995f60270e6c4a36cf47435c96 (diff)
use awk a bit smarter
Diffstat (limited to 'retrieveAdBlocklists.sh')
-rwxr-xr-xretrieveAdBlocklists.sh5
1 files changed, 2 insertions, 3 deletions
diff --git a/retrieveAdBlocklists.sh b/retrieveAdBlocklists.sh
index 480ee48..38643c0 100755
--- a/retrieveAdBlocklists.sh
+++ b/retrieveAdBlocklists.sh
@@ -1,4 +1,3 @@
#!/bin/bash
-while read p; do
- echo "$p" | awk '{split($0,a,"|"); system("curl -s " a[2] " > adlists/"a[1])}'
-done < adfilelist.txt
+rm -rf adlists/*
+awk -F'|' '{system("wget -q -O adlists/" $1 " " $2)}' adfilelist.txt