This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
# Get the current branch name. | |
branch=`git rev-parse --abbrev-ref HEAD` | |
# Determine the commit at which the current branch diverged. | |
ancestor=`git merge-base qa HEAD` | |
# Stash any uncommited, changed files. | |
git stash --all | |
# Revert the branch back to the ancestor SHA. |