gitk: Add a "Copy commit summary" command
commitd835dbb91fe246d123dc81f6a317d73518ecef46
authorBeat Bolli <dev+git@drbeat.li>
Sat, 18 Jul 2015 11:15:39 +0000 (18 13:15 +0200)
committerPaul Mackerras <paulus@samba.org>
Thu, 13 Aug 2015 03:47:43 +0000 (13 13:47 +1000)
tree1327b151b385a3a1e56408a8ff1d8d806c06facc
parentdfed7f917e54d09349a14dc2d6410815504a8266
gitk: Add a "Copy commit summary" command

When referring to earlier commits in commit messages or other text, one
of the established formats is

    <abbrev-sha> ("<summary>", <author-date>)

Add a "Copy commit summary" command to the context menu that puts this
text for the currently selected commit on the clipboard. This makes it
easy for our users to create well-formatted commit references.

The <abbrev-sha> is produced with the %h format specifier to make it
unique. Its length can be controlled with the gitk preference
"Auto-select SHA1 (length)", or, if this preference is set to its
default value (40), with the Git config setting core.abbrev.

Signed-off-by: Beat Bolli <dev+git@drbeat.li>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
gitk