Skip to content

Instantly share code, notes, and snippets.

@rainulf
Created November 24, 2019 01:53
Show Gist options
  • Save rainulf/e3236fd8e379296dc42dd8d9e2f01085 to your computer and use it in GitHub Desktop.
Save rainulf/e3236fd8e379296dc42dd8d9e2f01085 to your computer and use it in GitHub Desktop.
#!/bin/sh
cd $1
git clean -df
git checkout -- .
git pull
git reset --hard origin/master
BUILD=$(git rev-parse --short=5 HEAD)
sed -i "s/BUILD=.*/BUILD=$BUILD/g" .env
#service gunicorn restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment