Skip to content

Instantly share code, notes, and snippets.

@saml
Created May 22, 2013 14:33
Show Gist options
  • Save saml/5627996 to your computer and use it in GitHub Desktop.
Save saml/5627996 to your computer and use it in GitHub Desktop.
for city in newyork boston chicago losangeles philadelphia sanfrancisco
do
if [[ -d "$basedir/$city" ]]
then
baseurl="http://$city.$domain"
if [[ "newyork" = "$city" ]]
then
baseurl="http://www.$domain"
fi
./sitemap.pl --base_url="$baseurl" --root_dir="$basedir/$city" --output_dir="$basedir/$city" "$@"
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment