blob: 62c6c76f2736e0ee2dd61d3ac25a4962a9db0fc7 [file] [log] [blame]
Junio C Hamano1a4e8412005-12-27 08:17:231git-send-email(1)
2=================
3
4NAME
5----
6git-send-email - Send a collection of patches as emails
7
8
9SYNOPSIS
10--------
Junio C Hamano15567bc2011-07-23 00:51:5911[verse]
Junio C Hamanoc9cb5172018-06-01 07:13:4412'git send-email' [<options>] <file|directory|rev-list options>...
Junio C Hamanoabb8a052015-12-04 22:43:1113'git send-email' --dump-aliases
Junio C Hamano1a4e8412005-12-27 08:17:2314
15
Junio C Hamano1a4e8412005-12-27 08:17:2316DESCRIPTION
17-----------
18Takes the patches given on the command line and emails them out.
Junio C Hamanob95b43d2009-06-12 08:57:2819Patches can be specified as files, directories (which will send all
20files in the directory), or directly as a revision list. In the
21last case, any format accepted by linkgit:git-format-patch[1] can
22be passed to git send-email.
Junio C Hamano1a4e8412005-12-27 08:17:2323
Junio C Hamanoe1aeb5e2014-06-06 19:16:2924The header of the email is configurable via command-line options. If not
Junio C Hamano1a4e8412005-12-27 08:17:2325specified on the command line, the user will be prompted with a ReadLine
26enabled interface to provide the necessary information.
27
Junio C Hamanoa6455f62009-02-20 08:33:0828There are two formats accepted for patch files:
29
301. mbox format files
31+
32This is what linkgit:git-format-patch[1] generates. Most headers and MIME
33formatting are ignored.
34
352. The original format used by Greg Kroah-Hartman's 'send_lots_of_email.pl'
36script
37+
38This format expects the first line of the file to contain the "Cc:" value
39and the "Subject:" of the message as the second line.
40
Junio C Hamanoa476efa2008-10-10 15:31:4241
Junio C Hamano1a4e8412005-12-27 08:17:2342OPTIONS
43-------
Junio C Hamanoa476efa2008-10-10 15:31:4244
45Composing
46~~~~~~~~~
Junio C Hamano1a4e8412005-12-27 08:17:2347
Junio C Hamano3d141512009-06-01 01:22:4048--annotate::
Junio C Hamanoea3b7522013-04-18 19:37:5349Review and edit each patch you're about to send. Default is the value
Junio C Hamano042f2142016-06-27 18:05:0550of `sendemail.annotate`. See the CONFIGURATION section for
51`sendemail.multiEdit`.
Junio C Hamano3d141512009-06-01 01:22:4052
Junio C Hamanod7ed4042015-08-03 19:43:0053--bcc=<address>,...::
Junio C Hamanoa476efa2008-10-10 15:31:4254Specify a "Bcc:" value for each email. Default is the value of
Junio C Hamano042f2142016-06-27 18:05:0555`sendemail.bcc`.
Junio C Hamanoa3fd83c2007-03-02 10:34:3656+
Junio C Hamanod7ed4042015-08-03 19:43:0057This option may be specified multiple times.
Junio C Hamano97f518c2006-06-22 19:49:3558
Junio C Hamanod7ed4042015-08-03 19:43:0059--cc=<address>,...::
Junio C Hamanoc9154122006-02-15 02:22:0660Specify a starting "Cc:" value for each email.
Junio C Hamano042f2142016-06-27 18:05:0561Default is the value of `sendemail.cc`.
Junio C Hamanoa3fd83c2007-03-02 10:34:3662+
Junio C Hamanod7ed4042015-08-03 19:43:0063This option may be specified multiple times.
Junio C Hamano97f518c2006-06-22 19:49:3564
Junio C Hamano86f75882006-02-06 02:27:2365--compose::
Junio C Hamano3b70d3c2009-11-21 17:37:3766Invoke a text editor (see GIT_EDITOR in linkgit:git-var[1])
67to edit an introductory message for the patch series.
Junio C Hamano610d1762008-11-28 06:27:1368+
Junio C Hamano92d80372016-07-13 22:00:0569When `--compose` is used, git send-email will use the From, Subject, and
Junio C Hamanoea82cff2009-03-18 01:54:4870In-Reply-To headers specified in the message. If the body of the message
71(what you type after the headers and a blank line) only contains blank
Junio C Hamanoe1aeb5e2014-06-06 19:16:2972(or Git: prefixed) lines, the summary won't be sent, but From, Subject,
Junio C Hamanoea82cff2009-03-18 01:54:4873and In-Reply-To headers will be used unless they are removed.
Junio C Hamano610d1762008-11-28 06:27:1374+
Junio C Hamanoea82cff2009-03-18 01:54:4875Missing From or In-Reply-To headers will be prompted for.
Junio C Hamano3d141512009-06-01 01:22:4076+
Junio C Hamano042f2142016-06-27 18:05:0577See the CONFIGURATION section for `sendemail.multiEdit`.
Junio C Hamano86f75882006-02-06 02:27:2378
Junio C Hamanob4a9ede2009-04-08 07:36:3279--from=<address>::
Junio C Hamano7ae18252009-05-23 09:53:3280Specify the sender of the emails. If not specified on the command line,
Junio C Hamano042f2142016-06-27 18:05:0581the value of the `sendemail.from` configuration option is used. If
82neither the command-line option nor `sendemail.from` are set, then the
Junio C Hamano7ae18252009-05-23 09:53:3283user will be prompted for the value. The default for the prompt will be
84the value of GIT_AUTHOR_IDENT, or GIT_COMMITTER_IDENT if that is not
85set, as returned by "git var -l".
Junio C Hamano86f75882006-02-06 02:27:2386
Junio C Hamano8b40d4b2018-03-15 22:52:3387--reply-to=<address>::
88Specify the address where replies from recipients should go to.
89Use this if replies to messages should go to another address than what
90is specified with the --from parameter.
91
Junio C Hamanob4a9ede2009-04-08 07:36:3292--in-reply-to=<identifier>::
Junio C Hamano97bcb482010-11-25 03:16:0793Make the first mail (or all the mails with `--no-thread`) appear as a
94reply to the given Message-Id, which avoids breaking threads to
95provide a new patch series.
96The second and subsequent emails will be sent as replies according to
Junio C Hamanocb06ef92017-03-21 22:40:1497the `--[no-]chain-reply-to` setting.
Junio C Hamano97bcb482010-11-25 03:16:0798+
99So for example when `--thread` and `--no-chain-reply-to` are specified, the
100second and subsequent patches will be replies to the first one like in the
101illustration below where `[PATCH v2 0/3]` is in reply to `[PATCH 0/2]`:
102+
103 [PATCH 0/2] Here is what I did...
104 [PATCH 1/2] Clean up and tests
105 [PATCH 2/2] Implementation
106 [PATCH v2 0/3] Here is a reroll
107 [PATCH v2 1/3] Clean up
108 [PATCH v2 2/3] New tests
109 [PATCH v2 3/3] Implementation
110+
111Only necessary if --compose is also set. If --compose
112is not set, this will be prompted for.
Junio C Hamano86f75882006-02-06 02:27:23113
Junio C Hamanob4a9ede2009-04-08 07:36:32114--subject=<string>::
Junio C Hamanoa476efa2008-10-10 15:31:42115Specify the initial subject of the email thread.
116Only necessary if --compose is also set. If --compose
117is not set, this will be prompted for.
Junio C Hamanoc9154122006-02-15 02:22:06118
Junio C Hamanod7ed4042015-08-03 19:43:00119--to=<address>,...::
Junio C Hamanoa476efa2008-10-10 15:31:42120Specify the primary recipient of the emails generated. Generally, this
121will be the upstream maintainer of the project involved. Default is the
Junio C Hamano042f2142016-06-27 18:05:05122value of the `sendemail.to` configuration value; if that is unspecified,
Junio C Hamano39c7a692010-10-27 06:08:54123and --to-cmd is not specified, this will be prompted for.
Junio C Hamanoa476efa2008-10-10 15:31:42124+
Junio C Hamanod7ed4042015-08-03 19:43:00125This option may be specified multiple times.
Junio C Hamano86f75882006-02-06 02:27:23126
Junio C Hamano4015aed2010-06-27 20:07:42127--8bit-encoding=<encoding>::
128When encountering a non-ASCII message or subject that does not
129declare its encoding, add headers/quoting to indicate it is
130encoded in <encoding>. Default is the value of the
131'sendemail.assume8bitEncoding'; if that is unspecified, this
132will be prompted for if any non-ASCII files are encountered.
133+
134Note that no attempts whatsoever are made to validate the encoding.
135
Junio C Hamanoa1295452012-11-13 22:32:04136--compose-encoding=<encoding>::
137Specify encoding of compose message. Default is the value of the
138'sendemail.composeencoding'; if that is unspecified, UTF-8 is assumed.
139
Junio C Hamano1ff03382018-07-25 22:10:48140--transfer-encoding=(7bit|8bit|quoted-printable|base64|auto)::
Junio C Hamano6df93d92014-12-22 22:48:09141Specify the transfer encoding to be used to send the message over SMTP.
1427bit will fail upon encountering a non-ASCII message. quoted-printable
143can be useful when the repository contains files that contain carriage
144returns, but makes the raw patch email file (as saved from a MUA) much
145harder to inspect manually. base64 is even more fool proof, but also
Junio C Hamano1ff03382018-07-25 22:10:48146even more opaque. auto will use 8bit when possible, and quoted-printable
147otherwise.
148+
149Default is the value of the `sendemail.transferEncoding` configuration
150value; if that is unspecified, default to `auto`.
Junio C Hamano6df93d92014-12-22 22:48:09151
Junio C Hamanoc9394b22015-01-07 22:45:48152--xmailer::
153--no-xmailer::
154Add (or prevent adding) the "X-Mailer:" header. By default,
155the header is added, but it can be turned off by setting the
156`sendemail.xmailer` configuration variable to `false`.
Junio C Hamanoa476efa2008-10-10 15:31:42157
158Sending
159~~~~~~~
160
Junio C Hamanob4a9ede2009-04-08 07:36:32161--envelope-sender=<address>::
Junio C Hamanoa476efa2008-10-10 15:31:42162Specify the envelope sender used to send the emails.
163This is useful if your default address is not the address that is
Junio C Hamano2bd8a742009-12-01 21:16:59164subscribed to a list. In order to use the 'From' address, set the
165value to "auto". If you use the sendmail binary, you must have
166suitable privileges for the -f parameter. Default is the value of the
Junio C Hamano042f2142016-06-27 18:05:05167`sendemail.envelopeSender` configuration variable; if that is
Junio C Hamanoa476efa2008-10-10 15:31:42168unspecified, choosing the envelope sender is left to your MTA.
169
Junio C Hamanob4a9ede2009-04-08 07:36:32170--smtp-encryption=<encryption>::
Junio C Hamanoa476efa2008-10-10 15:31:42171Specify the encryption to use, either 'ssl' or 'tls'. Any other
172value reverts to plain SMTP. Default is the value of
Junio C Hamano042f2142016-06-27 18:05:05173`sendemail.smtpEncryption`.
Junio C Hamanoa476efa2008-10-10 15:31:42174
Junio C Hamanocb39aea2010-05-09 07:24:48175--smtp-domain=<FQDN>::
176Specifies the Fully Qualified Domain Name (FQDN) used in the
177HELO/EHLO command to the SMTP server. Some servers require the
178FQDN to match your IP address. If not set, git send-email attempts
179to determine your FQDN automatically. Default is the value of
Junio C Hamano042f2142016-06-27 18:05:05180`sendemail.smtpDomain`.
Junio C Hamanocb39aea2010-05-09 07:24:48181
Junio C Hamanoa1746be2015-08-26 23:07:07182--smtp-auth=<mechanisms>::
183Whitespace-separated list of allowed SMTP-AUTH mechanisms. This setting
184forces using only the listed mechanisms. Example:
185+
186------
187$ git send-email --smtp-auth="PLAIN LOGIN GSSAPI" ...
188------
189+
190If at least one of the specified mechanisms matches the ones advertised by the
191SMTP server and if it is supported by the utilized SASL library, the mechanism
Junio C Hamano92d80372016-07-13 22:00:05192is used for authentication. If neither 'sendemail.smtpAuth' nor `--smtp-auth`
Junio C Hamano46fbbcb2018-11-07 03:54:16193is specified, all mechanisms supported by the SASL library can be used. The
194special value 'none' maybe specified to completely disable authentication
195independently of `--smtp-user`
Junio C Hamanoa1746be2015-08-26 23:07:07196
Junio C Hamanob4a9ede2009-04-08 07:36:32197--smtp-pass[=<password>]::
Junio C Hamanoa476efa2008-10-10 15:31:42198Password for SMTP-AUTH. The argument is optional: If no
199argument is specified, then the empty string is used as
Junio C Hamano042f2142016-06-27 18:05:05200the password. Default is the value of `sendemail.smtpPass`,
Junio C Hamano92d80372016-07-13 22:00:05201however `--smtp-pass` always overrides this value.
Junio C Hamanoa476efa2008-10-10 15:31:42202+
203Furthermore, passwords need not be specified in configuration files
204or on the command line. If a username has been specified (with
Junio C Hamano92d80372016-07-13 22:00:05205`--smtp-user` or a `sendemail.smtpUser`), but no password has been
206specified (with `--smtp-pass` or `sendemail.smtpPass`), then
Junio C Hamano5e7f1312013-03-21 22:49:01207a password is obtained using 'git-credential'.
Junio C Hamano68522892007-09-06 01:33:41208
Junio C Hamano46fbbcb2018-11-07 03:54:16209--no-smtp-auth::
210Disable SMTP authentication. Short hand for `--smtp-auth=none`
211
Junio C Hamanob4a9ede2009-04-08 07:36:32212--smtp-server=<host>::
Junio C Hamanob63afff2007-05-01 03:05:55213If set, specifies the outgoing SMTP server to use (e.g.
214`smtp.example.com` or a raw IP address). Alternatively it can
215specify a full pathname of a sendmail-like program instead;
Junio C Hamanob19b4f02006-10-29 20:47:22216the program must support the `-i` option. Default value can
Junio C Hamano042f2142016-06-27 18:05:05217be specified by the `sendemail.smtpServer` configuration
Junio C Hamano371470a2017-12-13 22:26:40218option; the built-in default is to search for `sendmail` in
219`/usr/sbin`, `/usr/lib` and $PATH if such program is
220available, falling back to `localhost` otherwise.
Junio C Hamano1a4e8412005-12-27 08:17:23221
Junio C Hamanob4a9ede2009-04-08 07:36:32222--smtp-server-port=<port>::
Junio C Hamano4fd58d42007-09-30 00:51:14223Specifies a port different from the default port (SMTP
Junio C Hamanobacccda2009-08-03 08:07:12224servers typically listen to smtp port 25, but may also listen to
225submission port 587, or the common SSL smtp port 465);
226symbolic port names (e.g. "submission" instead of 587)
Junio C Hamano3d141512009-06-01 01:22:40227are also accepted. The port can also be set with the
Junio C Hamano042f2142016-06-27 18:05:05228`sendemail.smtpServerPort` configuration variable.
Junio C Hamanofce7c7e2008-07-02 03:06:38229
Junio C Hamano39c7a692010-10-27 06:08:54230--smtp-server-option=<option>::
231If set, specifies the outgoing SMTP server option to use.
Junio C Hamano042f2142016-06-27 18:05:05232Default value can be specified by the `sendemail.smtpServerOption`
Junio C Hamano39c7a692010-10-27 06:08:54233configuration option.
234+
235The --smtp-server-option option must be repeated for each option you want
236to pass to the server. Likewise, different lines in the configuration files
237must be used for each option.
238
Junio C Hamano68522892007-09-06 01:33:41239--smtp-ssl::
Junio C Hamanoa476efa2008-10-10 15:31:42240Legacy alias for '--smtp-encryption ssl'.
Junio C Hamano68522892007-09-06 01:33:41241
Junio C Hamano58f587a2013-07-22 19:20:59242--smtp-ssl-cert-path::
Junio C Hamanoe8acc8e2015-01-14 22:01:34243Path to a store of trusted CA certificates for SMTP SSL/TLS
244certificate validation (either a directory that has been processed
245by 'c_rehash', or a single file containing one or more PEM format
246certificates concatenated together: see verify(1) -CAfile and
247-CApath for more information on these). Set it to an empty string
248to disable certificate verification. Defaults to the value of the
Junio C Hamano042f2142016-06-27 18:05:05249`sendemail.smtpsslcertpath` configuration variable, if set, or the
Junio C Hamanoe8acc8e2015-01-14 22:01:34250backing SSL library's compiled-in default otherwise (which should
251be the best choice on most platforms).
Junio C Hamano58f587a2013-07-22 19:20:59252
Junio C Hamanob4a9ede2009-04-08 07:36:32253--smtp-user=<user>::
Junio C Hamano042f2142016-06-27 18:05:05254Username for SMTP-AUTH. Default is the value of `sendemail.smtpUser`;
Junio C Hamano92d80372016-07-13 22:00:05255if a username is not specified (with `--smtp-user` or `sendemail.smtpUser`),
Junio C Hamanoa476efa2008-10-10 15:31:42256then authentication is not attempted.
Junio C Hamano86f75882006-02-06 02:27:23257
Junio C Hamano6ebd8042012-02-28 00:17:40258--smtp-debug=0|1::
259Enable (1) or disable (0) debug output. If enabled, SMTP
260commands and replies will be printed. Useful to debug TLS
261connection and authentication problems.
Junio C Hamanoa476efa2008-10-10 15:31:42262
Junio C Hamano08a3a232017-07-07 02:28:44263--batch-size=<num>::
264Some email servers (e.g. smtp.163.com) limit the number emails to be
Junio C Hamano96153bf2018-04-25 08:25:34265sent per session (connection) and this will lead to a failure when
Junio C Hamano08a3a232017-07-07 02:28:44266sending many messages. With this option, send-email will disconnect after
267sending $<num> messages and wait for a few seconds (see --relogin-delay)
268and reconnect, to work around such a limit. You may want to
269use some form of credential helper to avoid having to retype
270your password every time this happens. Defaults to the
271`sendemail.smtpBatchSize` configuration variable.
272
273--relogin-delay=<int>::
274Waiting $<int> seconds before reconnecting to SMTP server. Used together
275with --batch-size option. Defaults to the `sendemail.smtpReloginDelay`
276configuration variable.
277
Junio C Hamanoa476efa2008-10-10 15:31:42278Automating
279~~~~~~~~~~
280
Junio C Hamano39c7a692010-10-27 06:08:54281--to-cmd=<command>::
282Specify a command to execute once per patch file which
283should generate patch file specific "To:" entries.
284Output of this command must be single email address per line.
285Default is the value of 'sendemail.tocmd' configuration value.
286
Junio C Hamanob4a9ede2009-04-08 07:36:32287--cc-cmd=<command>::
Junio C Hamanoa476efa2008-10-10 15:31:42288Specify a command to execute once per patch file which
289should generate patch file specific "Cc:" entries.
290Output of this command must be single email address per line.
Junio C Hamano042f2142016-06-27 18:05:05291Default is the value of `sendemail.ccCmd` configuration value.
Junio C Hamanoa476efa2008-10-10 15:31:42292
Junio C Hamano25e7ba62009-06-14 01:03:22293--[no-]chain-reply-to::
Junio C Hamanoa476efa2008-10-10 15:31:42294If this is set, each email will be sent as a reply to the previous
295email sent. If disabled with "--no-chain-reply-to", all emails after
296the first will be sent as replies to the first email sent. When using
297this, it is recommended that the first file given be an overview of the
Junio C Hamano042f2142016-06-27 18:05:05298entire patch series. Disabled by default, but the `sendemail.chainReplyTo`
Junio C Hamano096dde22009-12-26 23:14:11299configuration variable can be used to enable it.
Junio C Hamanoa476efa2008-10-10 15:31:42300
Junio C Hamanob4a9ede2009-04-08 07:36:32301--identity=<identity>::
Junio C Hamanoa476efa2008-10-10 15:31:42302A configuration identity. When given, causes values in the
303'sendemail.<identity>' subsection to take precedence over
304values in the 'sendemail' section. The default identity is
Junio C Hamano042f2142016-06-27 18:05:05305the value of `sendemail.identity`.
Junio C Hamanoa476efa2008-10-10 15:31:42306
307--[no-]signed-off-by-cc::
308If this is set, add emails found in Signed-off-by: or Cc: lines to the
Junio C Hamano042f2142016-06-27 18:05:05309cc list. Default is the value of `sendemail.signedoffbycc` configuration
Junio C Hamanoa476efa2008-10-10 15:31:42310value; if that is unspecified, default to --signed-off-by-cc.
Junio C Hamanoc9154122006-02-15 02:22:06311
Junio C Hamano45f804f2014-06-20 22:24:49312--[no-]cc-cover::
313If this is set, emails found in Cc: headers in the first patch of
314the series (typically the cover letter) are added to the cc list
315for each email set. Default is the value of 'sendemail.cccover'
316configuration value; if that is unspecified, default to --no-cc-cover.
317
318--[no-]to-cover::
319If this is set, emails found in To: headers in the first patch of
320the series (typically the cover letter) are added to the to list
321for each email set. Default is the value of 'sendemail.tocover'
322configuration value; if that is unspecified, default to --no-to-cover.
323
Junio C Hamanob4a9ede2009-04-08 07:36:32324--suppress-cc=<category>::
Junio C Hamano9c334152008-02-12 03:18:52325Specify an additional category of recipients to suppress the
Junio C Hamano0a235222009-03-06 08:21:09326auto-cc of:
327+
328--
Junio C Hamano94d00a52018-10-30 07:34:40329- 'author' will avoid including the patch author.
330- 'self' will avoid including the sender.
Junio C Hamano0a235222009-03-06 08:21:09331- 'cc' will avoid including anyone mentioned in Cc lines in the patch header
332 except for self (use 'self' for that).
Junio C Hamano0e88f3e2009-06-21 08:03:25333- 'bodycc' will avoid including anyone mentioned in Cc lines in the
Junio C Hamano0a235222009-03-06 08:21:09334 patch body (commit message) except for self (use 'self' for that).
335- 'sob' will avoid including anyone mentioned in Signed-off-by lines except
Junio C Hamano94d00a52018-10-30 07:34:40336 for self (use 'self' for that).
337- 'misc-by' will avoid including anyone mentioned in Acked-by,
338 Reviewed-by, Tested-by and other "-by" lines in the patch body,
339 except Signed-off-by (use 'sob' for that).
Junio C Hamano0a235222009-03-06 08:21:09340- 'cccmd' will avoid running the --cc-cmd.
Junio C Hamano94d00a52018-10-30 07:34:40341- 'body' is equivalent to 'sob' + 'bodycc' + 'misc-by'.
Junio C Hamano0a235222009-03-06 08:21:09342- 'all' will suppress all auto cc values.
343--
344+
Junio C Hamano042f2142016-06-27 18:05:05345Default is the value of `sendemail.suppresscc` configuration value; if
Junio C Hamano0a235222009-03-06 08:21:09346that is unspecified, default to 'self' if --suppress-from is
347specified, as well as 'body' if --no-signed-off-cc is specified.
Junio C Hamano9c334152008-02-12 03:18:52348
Junio C Hamanoa476efa2008-10-10 15:31:42349--[no-]suppress-from::
350If this is set, do not add the From: address to the cc: list.
Junio C Hamano042f2142016-06-27 18:05:05351Default is the value of `sendemail.suppressFrom` configuration
Junio C Hamanoa476efa2008-10-10 15:31:42352value; if that is unspecified, default to --no-suppress-from.
353
354--[no-]thread::
Junio C Hamano1bbd0f42009-07-23 06:20:29355If this is set, the In-Reply-To and References headers will be
356added to each email sent. Whether each mail refers to the
357previous email (`deep` threading per 'git format-patch'
358wording) or to the first email (`shallow` threading) is
359governed by "--[no-]chain-reply-to".
360+
361If disabled with "--no-thread", those headers will not be added
362(unless specified with --in-reply-to). Default is the value of the
Junio C Hamano042f2142016-06-27 18:05:05363`sendemail.thread` configuration value; if that is unspecified,
Junio C Hamano1bbd0f42009-07-23 06:20:29364default to --thread.
365+
366It is up to the user to ensure that no In-Reply-To header already
367exists when 'git send-email' is asked to add it (especially note that
368'git format-patch' can be configured to do the threading itself).
369Failure to do so may not produce the expected result in the
370recipient's MUA.
Junio C Hamanoa476efa2008-10-10 15:31:42371
372
373Administering
374~~~~~~~~~~~~~
Junio C Hamanoddc5ad42007-06-27 07:14:52375
Junio C Hamanob4a9ede2009-04-08 07:36:32376--confirm=<mode>::
Junio C Hamano0a235222009-03-06 08:21:09377Confirm just before sending:
378+
379--
380- 'always' will always confirm before sending
381- 'never' will never confirm before sending
382- 'cc' will confirm before sending when send-email has automatically
383 added addresses from the patch to the Cc list
384- 'compose' will confirm before sending the first message when using --compose.
385- 'auto' is equivalent to 'cc' + 'compose'
386--
387+
Junio C Hamano042f2142016-06-27 18:05:05388Default is the value of `sendemail.confirm` configuration value; if that
Junio C Hamano0a235222009-03-06 08:21:09389is unspecified, default to 'auto' unless any of the suppress options
390have been specified, in which case default to 'compose'.
391
Junio C Hamano45889b42007-04-26 07:20:04392--dry-run::
393Do everything except actually send the emails.
394
Junio C Hamano3d141512009-06-01 01:22:40395--[no-]format-patch::
396When an argument may be understood either as a reference or as a file name,
Junio C Hamano92d80372016-07-13 22:00:05397choose to understand it as a format-patch argument (`--format-patch`)
398or as a file name (`--no-format-patch`). By default, when such a conflict
Junio C Hamano3d141512009-06-01 01:22:40399occurs, git send-email will fail.
400
Junio C Hamanoa476efa2008-10-10 15:31:42401--quiet::
402Make git-send-email less verbose. One line per email should be
403all that is output.
Junio C Hamano45889b42007-04-26 07:20:04404
Junio C Hamanoa476efa2008-10-10 15:31:42405--[no-]validate::
406Perform sanity checks on patches.
407Currently, validation means the following:
Junio C Hamanoa3fd83c2007-03-02 10:34:36408+
Junio C Hamanoa476efa2008-10-10 15:31:42409--
Junio C Hamanod88ba732017-05-30 04:14:20410* Invoke the sendemail-validate hook if present (see linkgit:githooks[5]).
Junio C Hamano1ff03382018-07-25 22:10:48411* Warn of patches that contain lines longer than
412998 characters unless a suitable transfer encoding
413('auto', 'base64', or 'quoted-printable') is used;
414this is due to SMTP limits as described by
415http://www.ietf.org/rfc/rfc5322.txt.
Junio C Hamanoa476efa2008-10-10 15:31:42416--
417+
Junio C Hamano042f2142016-06-27 18:05:05418Default is the value of `sendemail.validate`; if this is not set,
Junio C Hamano92d80372016-07-13 22:00:05419default to `--validate`.
Junio C Hamano97f518c2006-06-22 19:49:35420
Junio C Hamanocf29d332010-12-11 07:28:56421--force::
422Send emails even if safety checks would prevent it.
423
Junio C Hamano1a4e8412005-12-27 08:17:23424
Junio C Hamanoabb8a052015-12-04 22:43:11425Information
426~~~~~~~~~~~
427
428--dump-aliases::
429Instead of the normal operation, dump the shorthand alias names from
430the configured alias file(s), one per line in alphabetical order. Note,
431this only includes the alias name and not its expanded email addresses.
432See 'sendemail.aliasesfile' for more information about aliases.
433
434
Junio C Hamanoc51fede2007-03-12 07:29:20435CONFIGURATION
436-------------
Junio C Hamano68522892007-09-06 01:33:41437
Junio C Hamano322c6242015-03-23 21:32:46438sendemail.aliasesFile::
Junio C Hamanoc51fede2007-03-12 07:29:20439To avoid typing long email addresses, point this to one or more
Junio C Hamano042f2142016-06-27 18:05:05440email aliases files. You must also supply `sendemail.aliasFileType`.
Junio C Hamanoc51fede2007-03-12 07:29:20441
Junio C Hamano322c6242015-03-23 21:32:46442sendemail.aliasFileType::
443Format of the file(s) specified in sendemail.aliasesFile. Must be
Junio C Hamanoce447ab2015-06-16 22:08:01444one of 'mutt', 'mailrc', 'pine', 'elm', or 'gnus', or 'sendmail'.
445+
446What an alias file in each format looks like can be found in
447the documentation of the email program of the same name. The
448differences and limitations from the standard formats are
449described below:
450+
451--
452sendmail;;
453* Quoted aliases and quoted addresses are not supported: lines that
454contain a `"` symbol are ignored.
Junio C Hamanodf5384b2015-06-24 21:12:12455* Redirection to a file (`/path/name`) or pipe (`|command`) is not
456supported.
457* File inclusion (`:include: /path/name`) is not supported.
Junio C Hamanoce447ab2015-06-16 22:08:01458* Warnings are printed on the standard error output for any
459explicitly unsupported constructs, and any other lines that are not
460recognized by the parser.
461--
Junio C Hamanoc51fede2007-03-12 07:29:20462
Junio C Hamano322c6242015-03-23 21:32:46463sendemail.multiEdit::
Junio C Hamano610d1762008-11-28 06:27:13464If true (default), a single editor instance will be spawned to edit
Junio C Hamano92d80372016-07-13 22:00:05465files you have to edit (patches when `--annotate` is used, and the
466summary when `--compose` is used). If false, files will be edited one
Junio C Hamano610d1762008-11-28 06:27:13467after the other, spawning a new editor each time.
468
Junio C Hamano0a235222009-03-06 08:21:09469sendemail.confirm::
470Sets the default for whether to confirm before sending. Must be
Junio C Hamano92d80372016-07-13 22:00:05471one of 'always', 'never', 'cc', 'compose', or 'auto'. See `--confirm`
Junio C Hamano0a235222009-03-06 08:21:09472in the previous section for the meaning of these values.
473
Junio C Hamanob9d9d902018-05-23 07:07:42474EXAMPLES
475--------
Junio C Hamanofacbe512010-05-05 02:42:36476Use gmail as the smtp server
Junio C Hamanob77f8192011-05-05 01:30:38477~~~~~~~~~~~~~~~~~~~~~~~~~~~~
478To use 'git send-email' to send your patches through the GMail SMTP server,
479edit ~/.gitconfig to specify your account settings:
Junio C Hamanofacbe512010-05-05 02:42:36480
481[sendemail]
Junio C Hamano322c6242015-03-23 21:32:46482smtpEncryption = tls
483smtpServer = smtp.gmail.com
484smtpUser = yourname@gmail.com
485smtpServerPort = 587
Junio C Hamanofacbe512010-05-05 02:42:36486
Junio C Hamano5213c3b2016-06-03 23:34:40487If you have multifactor authentication setup on your gmail account, you will
Junio C Hamano37cf4082016-05-30 01:22:14488need to generate an app-specific password for use with 'git send-email'. Visit
Junio C Hamano96153bf2018-04-25 08:25:34489https://security.google.com/settings/security/apppasswords to create it.
Junio C Hamano37cf4082016-05-30 01:22:14490
Junio C Hamanob77f8192011-05-05 01:30:38491Once your commits are ready to be sent to the mailing list, run the
492following commands:
493
494$ git format-patch --cover-letter -M origin/master -o outgoing/
495$ edit outgoing/0000-*
496$ git send-email outgoing/*
497
Junio C Hamano96153bf2018-04-25 08:25:34498The first time you run it, you will be prompted for your credentials. Enter the
499app-specific or your regular password as appropriate. If you have credential
500helper configured (see linkgit:git-credential[1]), the password will be saved in
501the credential store so you won't have to type it the next time.
502
Junio C Hamanofacbe512010-05-05 02:42:36503Note: the following perl modules are required
504 Net::SMTP::SSL, MIME::Base64 and Authen::SASL
505
Junio C Hamanob77f8192011-05-05 01:30:38506SEE ALSO
507--------
508linkgit:git-format-patch[1], linkgit:git-imap-send[1], mbox(5)
509
Junio C Hamano1a4e8412005-12-27 08:17:23510GIT
511---
Junio C Hamanof7c042d2008-06-06 22:50:53512Part of the linkgit:git[1] suite