surf-adblock

Surf adblock web extension
git clone git://git.codemadness.org/surf-adblock
Log | Files | Refs | README | LICENSE

commit e9a15efd7acd1c68198a57d14acfff14a7d2d67d
parent be90f789e9aeb38836b88062cb3a11e344a59825
Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date:   Fri, 23 Sep 2016 13:05:42 +0200

surf-adblock-dl: simplify a bit, no need for read -r loop

Diffstat:
Msurf-adblock-dl | 27+++++++++++++--------------
1 file changed, 13 insertions(+), 14 deletions(-)

diff --git a/surf-adblock-dl b/surf-adblock-dl @@ -1,20 +1,19 @@ #!/bin/sh -# download adblock lists +# download Adblock/ublock lists and merge them. set -x -e -(while read -r l; do +for l in \ + https://easylist.github.io/easylist/easylist.txt\ + https://easylist.github.io/easylist/easyprivacy.txt\ + https://easylist-downloads.adblockplus.org/antiadblockfilters.txt\ + https://easylist-downloads.adblockplus.org/easylistdutch.txt\ + https://easylist.github.io/easylistgermany/easylistgermany.txt\ + https://easylist-downloads.adblockplus.org/liste_fr.txt\ + https://easylist.github.io/easylist/fanboy-annoyance.txt\ + https://easylist.github.io/easylist/fanboy-social.txt; do + curl -L "$l" echo "" # not all lists have line at EOF. -done <<! -https://easylist.github.io/easylist/easylist.txt -https://easylist.github.io/easylist/easyprivacy.txt -https://easylist-downloads.adblockplus.org/antiadblockfilters.txt -https://easylist-downloads.adblockplus.org/easylistdutch.txt -https://easylist.github.io/easylistgermany/easylistgermany.txt -https://easylist-downloads.adblockplus.org/liste_fr.txt -https://easylist.github.io/easylist/fanboy-annoyance.txt -https://easylist.github.io/easylist/fanboy-social.txt -! -) | awk '!x[$0]++' -# remove duplicate lines but keep the order. +done | awk '!x[$0]++' +# ^ remove duplicate lines but keep the order.