#!/bin/sh if [ "x${1}" != "x" ] then d="cd ${1}";shift url='http://www.snafu.de/~phpr/' if [ "x${1}" != "x" ] ; then url="${1}";shift;fi p= if [ "x${1}" != "x" ] ; then p="--http-passwd ${1}";shift;fi u= if [ "x${1}" != "x" ] ; then u="--http-user ${1}";shift;fi pushd `pwd` ${d} rm -f ${0}.log wget ${u} ${p} --dont-remove-listing --passive-ftp --no-parent \ --continue --mirror --relative ${*} ${url} 2>&1 | tee ${0}.log popd else test -z "`type -p wget`" &> /dev/null || man wget echo -e "\n\n\"`basename ${0}`\" - usage: local-dir [ url [ pass [ login [other \"wget\"-options ]]]]" echo "fetching and sub-dir's to , logging to \"`pwd`/`basename ${0}.log`\"" echo -e 'pre-set "wget"-options:\n\t--dont-remove-listing --passive-ftp --no-parent --continue --mirror' echo -e 'some other "wget"-options:\n\t--convert-links (to relative), --recursive, --level(s of recursions),\n\t--no-clobber (w/o --mirror!), --quota (nn), etc.' exit 1 fi
Make your own free website on Tripod.com