From 2ea19b66e94fa7ad28278277bda096394181a9d1 Mon Sep 17 00:00:00 2001 From: Marc Weber Date: Fri, 21 Nov 2008 10:05:30 +0100 Subject: [PATCH] Pass -- to rev-list for branch/filename disambiguation While playing around it happened that I called the topic branch and a file "foo"... Here is a small incomplete patch: I've not tried to catch all of these errors.. Signed-off-by: martin f. krafft --- tg.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tg.sh b/tg.sh index d8b6213..8c23d26 100644 --- a/tg.sh +++ b/tg.sh @@ -63,8 +63,8 @@ measure_branch() _bname="$1"; _base="$2" [ -n "$_base" ] || _base="refs/top-bases/$_bname" # The caller should've verified $name is valid - _commits="$(git rev-list "$_bname" ^"$_base" | wc -l)" - _nmcommits="$(git rev-list --no-merges "$_bname" ^"$_base" | wc -l)" + _commits="$(git rev-list "$_bname" ^"$_base" -- | wc -l)" + _nmcommits="$(git rev-list --no-merges "$_bname" ^"$_base" -- | wc -l)" if [ $_commits -gt 1 ]; then _suffix="commits" else -- 2.30.2