Skip to content

Commit 0e2913b

Browse files
apelissegitster
authored andcommitted
mailmap: add mailmap structure to rev_info and pp
Pass a mailmap from rev_info to pretty_print_context to so that the pretty printer can use rewritten name and email address when showing commits. Signed-off-by: Antoine Pelisse <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent ea02ffa commit 0e2913b

File tree

3 files changed

+3
-0
lines changed

3 files changed

+3
-0
lines changed

commit.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ struct pretty_print_context {
8989
char *notes_message;
9090
struct reflog_walk_info *reflog_info;
9191
const char *output_encoding;
92+
struct string_list *mailmap;
9293
};
9394

9495
struct userformat_want {

log-tree.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -671,6 +671,7 @@ void show_log(struct rev_info *opt)
671671
ctx.preserve_subject = opt->preserve_subject;
672672
ctx.reflog_info = opt->reflog_info;
673673
ctx.fmt = opt->commit_format;
674+
ctx.mailmap = opt->mailmap;
674675
pretty_print_commit(&ctx, commit, &msgbuf);
675676

676677
if (opt->add_signoff)

revision.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,7 @@ struct rev_info {
143143
const char *subject_prefix;
144144
int no_inline;
145145
int show_log_size;
146+
struct string_list *mailmap;
146147

147148
/* Filter by commit log message */
148149
struct grep_opt grep_filter;

0 commit comments

Comments
 (0)