1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-02 01:20:54 +00:00

Allow running this with a negative revision number, to backout a commit.

Sponsored by:	Absolight
This commit is contained in:
Mathieu Arnold 2015-12-18 15:29:38 +00:00
parent 428aed10a2
commit d984ba9704
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=403975

View File

@ -63,7 +63,7 @@ for rev in $@
do
rev=${rev##r} # remove a leading "r"
case ${rev} in
''|*[!0-9]*) err "revision \"${rev}\" should be a number" ;;
''|*[!-0-9]*) err "revision \"${rev}\" should be a number" ;;
esac
done
@ -102,7 +102,7 @@ do
f=${f%/*}
filelist="${filelist}${LF}${f}"
done
"${svn}" log -r${rev} ${svnserver}/ports/head | sed '1,2d;$d;/^MFH:/d' \
"${svn}" log -r${rev##-} ${svnserver}/ports/head | sed '1,2d;$d;/^MFH:/d' \
| sed '$d' >> commit.txt
done
filelist=$(printf '%s\n' "${filelist}" | sort -u)