]>
Commit | Line | Data |
---|---|---|
42957af0 ÆAB |
1 | gitmailmap(5) |
2 | ============= | |
3 | ||
4 | NAME | |
5 | ---- | |
6 | gitmailmap - Map author/committer names and/or E-Mail addresses | |
7 | ||
8 | SYNOPSIS | |
9 | -------- | |
10 | $GIT_WORK_DIR/.mailmap | |
11 | ||
12 | ||
13 | DESCRIPTION | |
14 | ----------- | |
15 | ||
7d48e9e6 | 16 | If the file `.mailmap` exists at the toplevel of the repository, or at |
4f2ee994 ÆAB |
17 | the location pointed to by the `mailmap.file` or `mailmap.blob` |
18 | configuration options (see linkgit:git-config[1]), it | |
7d48e9e6 MSO |
19 | is used to map author and committer names and email addresses to |
20 | canonical real names and email addresses. | |
21 | ||
42957af0 ÆAB |
22 | |
23 | SYNTAX | |
24 | ------ | |
25 | ||
fcafb753 ÆAB |
26 | The '#' character begins a comment to the end of line, blank lines |
27 | are ignored. | |
28 | ||
7d48e9e6 MSO |
29 | In the simple form, each line in the file consists of the canonical |
30 | real name of an author, whitespace, and an email address used in the | |
b89510f0 | 31 | commit (enclosed by '<' and '>') to map to the name. For example: |
7d48e9e6 MSO |
32 | -- |
33 | Proper Name <commit@email.xx> | |
34 | -- | |
35 | ||
b89510f0 | 36 | The more complex forms are: |
7d48e9e6 MSO |
37 | -- |
38 | <proper@email.xx> <commit@email.xx> | |
39 | -- | |
b89510f0 | 40 | which allows mailmap to replace only the email part of a commit, and: |
7d48e9e6 MSO |
41 | -- |
42 | Proper Name <proper@email.xx> <commit@email.xx> | |
43 | -- | |
44 | which allows mailmap to replace both the name and the email of a | |
b89510f0 | 45 | commit matching the specified commit email address, and: |
7d48e9e6 MSO |
46 | -- |
47 | Proper Name <proper@email.xx> Commit Name <commit@email.xx> | |
48 | -- | |
49 | which allows mailmap to replace both the name and the email of a | |
50 | commit matching both the specified commit name and email address. | |
51 | ||
42957af0 ÆAB |
52 | |
53 | EXAMPLES | |
54 | -------- | |
55 | ||
7d48e9e6 MSO |
56 | Example 1: Your history contains commits by two authors, Jane |
57 | and Joe, whose names appear in the repository under several forms: | |
58 | ||
59 | ------------ | |
60 | Joe Developer <joe@example.com> | |
61 | Joe R. Developer <joe@example.com> | |
62 | Jane Doe <jane@example.com> | |
63 | Jane Doe <jane@laptop.(none)> | |
64 | Jane D. <jane@desktop.(none)> | |
65 | ------------ | |
66 | ||
67 | Now suppose that Joe wants his middle name initial used, and Jane | |
68 | prefers her family name fully spelled out. A proper `.mailmap` file | |
69 | would look like: | |
70 | ||
71 | ------------ | |
72 | Jane Doe <jane@desktop.(none)> | |
73 | Joe R. Developer <joe@example.com> | |
74 | ------------ | |
75 | ||
f430ed8b | 76 | Note how there is no need for an entry for `<jane@laptop.(none)>`, because the |
b89510f0 | 77 | real name of that author is already correct. |
7d48e9e6 MSO |
78 | |
79 | Example 2: Your repository contains commits from the following | |
80 | authors: | |
81 | ||
82 | ------------ | |
83 | nick1 <bugs@company.xx> | |
84 | nick2 <bugs@company.xx> | |
85 | nick2 <nick2@company.xx> | |
86 | santa <me@company.xx> | |
87 | claus <me@company.xx> | |
88 | CTO <cto@coompany.xx> | |
89 | ------------ | |
90 | ||
b89510f0 | 91 | Then you might want a `.mailmap` file that looks like: |
7d48e9e6 MSO |
92 | ------------ |
93 | <cto@company.xx> <cto@coompany.xx> | |
94 | Some Dude <some@dude.xx> nick1 <bugs@company.xx> | |
95 | Other Author <other@author.xx> nick2 <bugs@company.xx> | |
96 | Other Author <other@author.xx> <nick2@company.xx> | |
97 | Santa Claus <santa.claus@northpole.xx> <me@company.xx> | |
98 | ------------ | |
99 | ||
42957af0 ÆAB |
100 | |
101 | ||
102 | SEE ALSO | |
103 | -------- | |
104 | linkgit:git-check-mailmap[1] | |
105 | ||
106 | ||
107 | GIT | |
108 | --- | |
109 | Part of the linkgit:git[1] suite |