#! /bin/sh

curl http://www.phdcomics.com/comics/archive.php?comicid=[${1-1}-${2-1420}] 2> /dev/null | \
    perl -wnl -e 'print $1 if m|(http://.*?/phd[^/]*?\.gif)|' | \
    xargs -n 1 wget -nc -nd -P comics
