Skip to content

Instantly share code, notes, and snippets.

@oremj
Created October 20, 2010 17:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oremj/636856 to your computer and use it in GitHub Desktop.
Save oremj/636856 to your computer and use it in GitHub Desktop.
#!/bin/bash
function checkretval()
{
retval=$?
if [[ $retval -gt 0 ]]
then
$error "Error!!! Exit status of the last command was $retval"
exit $retval
fi
}
INPUT_DIR="/data/dekiwiki_python/src/developer.mozilla.org/mdn"
VENDOR_DIR="$INPUT_DIR/vendor"
SYNC_DIR="/data/dekiwiki/www/django/developer.mozilla.org/mdn"
echo -e "Updating vendor..."
cd $VENDOR_DIR
git pull
git submodule update --init
echo -e "Updating mdn..."
cd $INPUT_DIR
git fetch origin
git checkout origin/prod
git submodule update --init
/data/dekiwiki_python/deploy
cd $SYNC_DIR
schematic migrations
checkretval
if [ -d $SYNC_DIR/migrations/sites ]; then
schematic migrations/sites
checkretval
fi
/data/bin/omg_push_deki_live.sh .
/data/bin/issue-multi-command.py dekiwiki 'service httpd reload'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment