llvm.org GIT mirror llvm / 276b854
Use 'git svn find-rev' in git-svnrevert instead of shell script fu. Thanks Chandler! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@180592 91177308-0d34-0410-b5e6-96231b3b80d8 Michael Gottesman 6 years ago
1 changed file(s) with 3 addition(s) and 4 deletion(s). Raw diff Collapse all Expand all
1313
1414 COMMIT=$1
1515
16 SVN_REVISION=$(git log -1 $COMMIT | grep git-svn-id | tr -s "@" " " | cut -f 4 -d " ")
17
18 if [ -z "$SVN_REVISION" ]; then
19 echo "Error! Given commit is not a git-svn revision!"
16 SVN_REVISION=$(git svn find-rev "$COMMIT")
17 if [ $? -ne 0 ]; then
18 echo "Error! Could not find an svn revision for commit $COMMIT!"
2019 exit 1
2120 fi
2221