Skip to content

Commit 7f1592d

Browse files
jrngitster
authored andcommitted
examples/commit: use --abbrev for commit summary
After v1.7.1.1~17^2~3 (pretty: Respect --abbrev option, 2010-05-03), plumbing users do not abbreviate %h hashes by default any more. Noticed while investigating the bug fixed by v1.7.1.1~17^2 (commit::print_summary(): don't use format_commit_message(), 2010-06-12). Cc: Will Palmer <[email protected]> Signed-off-by: Jonathan Nieder <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent dcbeac4 commit 7f1592d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contrib/examples/git-commit.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -631,7 +631,7 @@ then
631631
if test -z "$quiet"
632632
then
633633
commit=`git diff-tree --always --shortstat --pretty="format:%h: %s"\
634-
--summary --root HEAD --`
634+
--abbrev --summary --root HEAD --`
635635
echo "Created${initial_commit:+ initial} commit $commit"
636636
fi
637637
fi

0 commit comments

Comments
 (0)