This patch series adds builtin command check-mailmap, similar to
check-attr and check-ignore, which allows direct testing of .mailmap
configuration.  More importantly, as plumbing accessible to scripts
and other porcelain, check-mailmap publishes the stable, well-tested
.mailmap functionality employed by built-in Git commands.

It is RFC because it lacks documentation; because its utility as a
check-foo command is minimal compared to check-attr and check-ignore
(although its utility as plumbing for scripts and porcelain is more
significant); and because I want to make sure that the project is
willing to accept yet another check-foo command.

The idea and motivation for git-check-mailmap arose from the effort to
implement .mailmap support for git-contacts [1] (presently at
es/contacts in 'pu').

Felipe's Ruby implementation of .mailmap support for his git-related
script is introduced in patch 9/15 [2] of v5, and is augmented in patch
10/15 [3] to support invocation from within a subdirectory. His version
supports configuration variable mailmap.file, but not mailmap.blob.

Rather than rewriting the functionality yet again, this time in Perl,
along with all the details and nuances of the C version employed by
Git builtins, I decided that it made more sense to expose the
well-tested and polished C implementation as plumbing, thus allowing
any script or porcelain to take advantage of it.


Eric Sunshine (4):
  builtin: add git-check-mailmap command
  t4203: test check-mailmap command invocation
  t4203: test mailmap functionality directly rather than indirectly
  t4203: consolidate test-repository setup

 .gitignore                             |   1 +
 Makefile                               |   1 +
 builtin.h                              |   1 +
 builtin/check-mailmap.c                |  73 ++++++++++
 command-list.txt                       |   1 +
 contrib/completion/git-completion.bash |   1 +
 git.c                                  |   1 +
 t/                     | 246 +++++++++++++++++----------------
 8 files changed, 209 insertions(+), 116 deletions(-)
 create mode 100644 builtin/check-mailmap.c


To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to
More majordomo info at

Reply via email to