diff options
author | Johan Herland <johan@herland.net> | 2009-10-09 12:22:09 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-10-19 19:00:24 -0700 |
commit | ef8db638cc96abaf166bbafe31752219f3d2cdc2 (patch) | |
tree | 4377d731875a2f2712697f39f9608dfde6f2d90b /t/t3303-notes-subtrees.sh | |
parent | 0057c0917d35f9f21e01f2122e7f2b9f169a8b02 (diff) | |
download | git-ef8db638cc96abaf166bbafe31752219f3d2cdc2.tar.gz |
Refactor notes code to concatenate multiple notes annotating the same object
Currently, having multiple notes referring to the same commit from various
locations in the notes tree is strongly discouraged, since only one of those
notes will be parsed and shown.
This patch teaches the notes code to _concatenate_ multiple notes that
annotate the same commit. Notes are concatenated by creating a new blob
object containing the concatenation of the notes in question, and
replacing them with the concatenated note in the internal notes tree
structure.
Getting the concatenation right requires being more proactive in unpacking
subtree entries in the internal notes tree structure, so that we don't return
a note prematurely (i.e. before having found all other notes that annotate
the same object). As such, this patch may incur a small performance penalty.
Suggested-by: Sam Vilain <sam@vilain.net>
Re-suggested-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Johan Herland <johan@herland.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t3303-notes-subtrees.sh')
0 files changed, 0 insertions, 0 deletions