Lines Matching +full:- +full:- +full:revert
3 if [ $# -ne 1 ]; then
5 echo "$0 <rNNNNNN | git-hash>"
9 if [ -n "$(git status -uno -s --porcelain)" ]; then
10 echo "You have unstashed changes. Please stash and then revert."
11 git status -uno
16 OTHER=$(git svn find-rev "$COMMIT")
17 if [ $? -ne 0 ] || [ "$OTHER" = "" ]; then
23 echo " * This commit in in another three (llvm, clang, compiler-rt, etc)"
27 if [ -n "$(echo $COMMIT | grep '^r[0-9]\+')" ]; then
28 SVN=`echo $COMMIT | sed -e 's/^r//'`
35 # Grab the one line message for our revert commit message.
36 ONE_LINE_MSG=$(git log --oneline $GIT -1 | cut -f2- -d " ")
38 # Revert the commit.
39 git revert --no-commit $GIT 2>/dev/null
40 if [ $? -ne 0 ]; then
41 echo "Error! Failed to revert commit r$SVN. Resetting to head."
42 git reset --hard HEAD
47 TEMPLATE="`git rev-parse --git-dir`/git-svn-revert-template"
49 Revert "$ONE_LINE_MSG"
55 git commit --file="$TEMPLATE" --edit
56 if [ $? -ne 0 ]; then
58 git reset --hard HEAD
59 rm -rf $TEMPLATE
63 rm -rf $TEMPLATE