Skip to content

Bring "format-patch --notes" closer to a real feature

Junio C Hamano git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest6 patches 11 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6pretty: remove reencode_commit_message()builtin/blame.c commit.h pretty.c+5 -150 replies
2/6format_note(): simplify APInotes.c notes.h pretty.c +1 more+11 -150 replies
3/6pretty: prepare notes message at a centralized placecommit.h log-tree.c pretty.c+18 -74 replies
4/6pretty_print_commit(): do not append notes messagelog-tree.c pretty.c+3 -30 replies
5/6format-patch: append --signature after noteslog-tree.c t/t4014-format-patch.sh+14 -40 replies
6/6format-patch --notes: show notes after three-dasheslog-tree.c revision.h t/t4014-format-patch.sh+17 -64 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/6] Bring "format-patch --notes" closer to a real feature

This replaces the earlier "wip" with a real thing.

We never advertised the "--notes" option to format-patch (or anything related to the pretty format options for that matter) because the behaviour of these options was whatever they happened to do, not what they were designed to do.

It had a few obvious glitches:

* The notes section was appended immediately after the log message, and then the three-dash line was added. Such a supplimental material should come after the three-dash line.

* The logic to append a new sign-off with "format-patch --signoff" worked on the message after the note was added, which made the detection of existing sign-off lines incorrect.

This updates the handling of "--notes" option to correct these, in an attempt to bring it closer to a real feature.

Junio C Hamano (6):
pretty: remove reencode_commit_message() format_note(): simplify API
pretty: prepare notes message at a centralized place pretty_print_commit(): do not append notes message
format-patch: append --signature after notes format-patch --notes: show notes after three-dashes

 builtin/blame.c         |  5 +++--
 commit.h                |  4 +---
 log-tree.c              | 32 ++++++++++++++++++++++++++++----
 notes.c                 | 13 +++++++------
 notes.h                 |  6 +-----
 pretty.c                | 22 ++++------------------
 revision.c              |  2 +-
 revision.h              |  1 +
 t/t4014-format-patch.sh | 15 +++++++++++++--
 9 files changed, 59 insertions(+), 41 deletions(-)
Signature · 1 line
1.8.0.rc3.112.gdb88a5e