mason-larobina/luakit-plugins — pull request #2 by Szunti (2012-08-10 19:00:37+00:00)
Title: Allow empty url ("") as first argument in adblock-update.sh

This is a request.

If the first argument to adblock-update.sh is empty ("") it will fail with:

basename: missing operand
Try 'basename --help' for more information.
wget: missing URL
Usage: wget [OPTION]... [URL]...

Try `wget --help' for more options.
Error: List Download Failed!

I would like if the empty argument would be the same (updating "easylist.txt") as without argument.
This way I could make a script like this:

LISTS=(
"" #easylist
"filter-list-url" #another filter
...
)

for l in "${LISTS[@]}"; do
"$UPDATER" "$l"
done