blob: 51dc3257486b07edaec71fe98fed6533e17e1a77 [file] [log] [blame]
Junio C Hamano1a4e8412005-12-27 08:17:231git-mailinfo(1)
2===============
3
4NAME
5----
Junio C Hamano7c73c662007-01-19 00:37:506git-mailinfo - Extracts patch and authorship from a single e-mail message
Junio C Hamano1a4e8412005-12-27 08:17:237
8
9SYNOPSIS
10--------
Junio C Hamano15567bc2011-07-23 00:51:5911[verse]
Junio C Hamano2bd8a742009-12-01 21:16:5912'git mailinfo' [-k|-b] [-u | --encoding=<encoding> | -n] [--scissors] <msg> <patch>
Junio C Hamano1a4e8412005-12-27 08:17:2313
14
15DESCRIPTION
16-----------
Junio C Hamano54bf1e22008-12-20 06:30:1117Reads a single e-mail message from the standard input, and
Junio C Hamano1a4e8412005-12-27 08:17:2318writes the commit log message in <msg> file, and the patches in
19<patch> file. The author name, e-mail and e-mail subject are
Junio C Hamano1aa40d22010-01-21 17:46:4320written out to the standard output to be used by 'git am'
Junio C Hamano1a4e8412005-12-27 08:17:2321to create a commit. It is usually not necessary to use this
Junio C Hamano35738e82008-01-07 07:55:4622command directly. See linkgit:git-am[1] instead.
Junio C Hamano1a4e8412005-12-27 08:17:2323
24
25OPTIONS
26-------
27-k::
28Usually the program 'cleans up' the Subject: header line
29to extract the title line for the commit log message,
30among which (1) remove 'Re:' or 're:', (2) leading
31whitespaces, (3) '[' up to ']', typically '[PATCH]', and
32then prepends "[PATCH] ". This flag forbids this
Junio C Hamanofce7c7e2008-07-02 03:06:3833munging, and is most useful when used to read back
Junio C Hamano1aa40d22010-01-21 17:46:4334'git format-patch -k' output.
Junio C Hamano1a4e8412005-12-27 08:17:2335
Junio C Hamano2bd8a742009-12-01 21:16:5936-b::
37When -k is not in effect, all leading strings bracketed with '['
38and ']' pairs are stripped. This option limits the stripping to
39only the pairs whose bracketed string contains the word "PATCH".
40
Junio C Hamano1a4e8412005-12-27 08:17:2341-u::
Junio C Hamano27eacdb2007-01-10 05:37:4742The commit log message, author name and author email are
43taken from the e-mail, and after minimally decoding MIME
Junio C Hamanod8c8c562010-06-14 05:18:2544transfer encoding, re-coded in the charset specified by
45i18n.commitencoding (defaulting to UTF-8) by transliterating
Junio C Hamano27eacdb2007-01-10 05:37:4746them. This used to be optional but now it is the default.
47+
48Note that the patch is always used as-is without charset
49conversion, even with this flag.
Junio C Hamano1a4e8412005-12-27 08:17:2350
51--encoding=<encoding>::
Junio C Hamanod8c8c562010-06-14 05:18:2552Similar to -u. But when re-coding, the charset specified here is
53used instead of the one specified by i18n.commitencoding or UTF-8.
Junio C Hamano1a4e8412005-12-27 08:17:2354
Junio C Hamano46a38aa2008-07-14 03:13:2755-n::
56Disable all charset re-coding of the metadata.
57
Junio C Hamanoc28068f2009-09-08 00:55:2358--scissors::
59Remove everything in body before a scissors line. A line that
60mainly consists of scissors (either ">8" or "8<") and perforation
61(dash "-") marks is called a scissors line, and is used to request
62the reader to cut the message at that line. If such a line
63appears in the body of the message before the patch, everything
64before it (including the scissors line itself) is ignored when
65this option is used.
66+
67This is useful if you want to begin your message in a discussion thread
68with comments and suggestions on the message you are responding to, and to
69conclude it with a patch submission, separating the discussion and the
70beginning of the proposed commit log message with a scissors line.
Junio C Hamanocf5b7732009-09-11 23:28:3271+
72This can enabled by default with the configuration option mailinfo.scissors.
73
74--no-scissors::
75Ignore scissors lines. Useful for overriding mailinfo.scissors settings.
Junio C Hamanoc28068f2009-09-08 00:55:2376
Junio C Hamano1a4e8412005-12-27 08:17:2377<msg>::
78The commit log message extracted from e-mail, usually
79except the title line which comes from e-mail Subject.
80
81<patch>::
82The patch extracted from e-mail.
83
Junio C Hamano1a4e8412005-12-27 08:17:2384GIT
85---
Junio C Hamanof7c042d2008-06-06 22:50:5386Part of the linkgit:git[1] suite