Skip to content

Instantly share code, notes, and snippets.

@Jd007
Created May 8, 2013 22:35
Show Gist options
  • Save Jd007/5544216 to your computer and use it in GitHub Desktop.
Save Jd007/5544216 to your computer and use it in GitHub Desktop.
#!/bin/sh
echo
echo "Executing Fabric deploy command"
echo
cd /path/to/fabfiles
branch=$(git rev-parse --symbolic --abbrev-ref $1)
if [ $branch = "dev" ]
then
/path/to/fabexec/bin/fab deploy_dev_fabfile
else
/path/to/fabexec/bin/fab deploy_prod_fabfile
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment