\e[1mOPTIONS:\e[0m
-l, --list
- Text file where each line contains a url and filename separated by a space. Filename is optional.
+ Text file where each line contains a url and filename separated by a space. Filename is optional. Lines starting with # are ignored.
Default: ./queue.txt
-h, --help
while read -r url filename; do
+ # Ignore if line is commented
+ [[ "$url" =~ ^\s*#.* ]] && continue
+
# parse output filename
destarg='' # placeholder for -O argument (output filename)
if [ -z "$filename" ] || [ "filename" = "" ]; then