author | Johan Herland <johan@herland.net> | |
Sun, 14 Nov 2010 23:57:17 +0000 (00:57 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Wed, 17 Nov 2010 21:22:53 +0000 (13:22 -0800) | ||
commit | a6a09095a08339afc8468d053ff978ed4662a1d5 | |
tree | 915beb0e1f4fbe5fe5932b8188a1ac983c7ed786 | tree | snapshot |
parent | 6cfd6a9dea889707fa207ee2003010c3b56b2131 | commit | diff |
git notes merge: Add another auto-resolving strategy: "cat_sort_uniq"
This new strategy is similar to "concatenate", but in addition to
concatenating the two note candidates, this strategy sorts the resulting
lines, and removes duplicate lines from the result. This is equivalent to
applying the "cat | sort | uniq" shell pipeline to the two note candidates.
This strategy is useful if the notes follow a line-based format where one
wants to avoid duplicate lines in the merge result.
Note that if either of the note candidates contain duplicate lines _prior_
to the merge, these will also be removed by this merge strategy.
The patch also contains tests and documentation for the new strategy.
Signed-off-by: Johan Herland <johan@herland.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This new strategy is similar to "concatenate", but in addition to
concatenating the two note candidates, this strategy sorts the resulting
lines, and removes duplicate lines from the result. This is equivalent to
applying the "cat | sort | uniq" shell pipeline to the two note candidates.
This strategy is useful if the notes follow a line-based format where one
wants to avoid duplicate lines in the merge result.
Note that if either of the note candidates contain duplicate lines _prior_
to the merge, these will also be removed by this merge strategy.
The patch also contains tests and documentation for the new strategy.
Signed-off-by: Johan Herland <johan@herland.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>