Skip to content

Instantly share code, notes, and snippets.

@oschwab
Created April 6, 2018 08:16
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oschwab/fd0e1f927f0412b79f98cfb41f95c7f1 to your computer and use it in GitHub Desktop.
Save oschwab/fd0e1f927f0412b79f98cfb41f95c7f1 to your computer and use it in GitHub Desktop.
DCSS morgue retrieval
#!/bin/bash
function helptext {
echo "Usage : $0 [server] [user] [destination] "
echo " where server is : cdo, cao, cdo, cbro, lld, cwz, cxc, cpo "
}
if [ "$#" -ne 3 ]; then
helptext
exit 1
fi
case $1 in
cdo)
server="crawl.develz.org"
;;
cao)
server="crawl.akrasiac.org"
;;
cdo)
server="underhound.eu"
;;
cbro)
server="crawl.beRotato.org"
;;
lld)
server="lazy-life.ddo.jp"
;;
cwz)
server="webzook.net"
;;
cxc)
server="crawl.xtahua.com"
;;
cpo)
server="crawl.project357.org"
;;
*)
server=""
esac
if [$server -eq ""]; then
echo "Invalid server : $1"
helptext
exit 1
fi
echo "Retrieving $2 user data from $server"
chem=$PWD
cd $3
wget -nd -r -np -P . -A lst,map,txt -N https://$server/morgue/$2/
cd $chem
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment