Skip to content

Commit 41e79c9

Browse files
author
Junio C Hamano
committed
sample update-hook: sanely handle a new branch head.
Instead of showing all the history since the beginning of time leading to the the branch head, show only the changes this new branch brings to the world. This originally came from Linus and tested by Andreas Ericsson. Signed-off-by: Junio C Hamano <junkio@cox.net>
1 parent 8a3ee7c commit 41e79c9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

templates/hooks--update

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ then
6868
refs/heads/*)
6969
branch="${1##refs/heads/}"
7070
echo "New branch '$branch' available with the following commits:"
71-
git-rev-list --pretty "$3"
71+
git-rev-list --pretty "$3" $(git-rev-parse --not --all)
7272
;;
7373
esac
7474
else

0 commit comments

Comments
 (0)