Home Explore Blog CI



git

1st chunk of `Documentation/git-send-email.adoc`
5b2d84b8765ad588b718c4fd022b793732343ac5ad1971050000000100000fa0
git-send-email(1)
=================

NAME
----
git-send-email - Send a collection of patches as emails


SYNOPSIS
--------
[verse]
'git send-email' [<options>] (<file>|<directory>)...
'git send-email' [<options>] <format-patch-options>
'git send-email' --dump-aliases
'git send-email' --translate-aliases


DESCRIPTION
-----------
Takes the patches given on the command line and emails them out.
Patches can be specified as files, directories (which will send all
files in the directory), or directly as a revision list.  In the
last case, any format accepted by linkgit:git-format-patch[1] can
be passed to git send-email, as well as options understood by
linkgit:git-format-patch[1].

The header of the email is configurable via command-line options.  If not
specified on the command line, the user will be prompted with a ReadLine
enabled interface to provide the necessary information.

There are two formats accepted for patch files:

1. mbox format files
+
This is what linkgit:git-format-patch[1] generates.  Most headers and MIME
formatting are ignored.

2. The original format used by Greg Kroah-Hartman's 'send_lots_of_email.pl'
   script
+
This format expects the first line of the file to contain the "Cc:" value
and the "Subject:" of the message as the second line.


OPTIONS
-------

Composing
~~~~~~~~~

--annotate::
	Review and edit each patch you're about to send. Default is the value
	of `sendemail.annotate`. See the CONFIGURATION section for
	`sendemail.multiEdit`.

--bcc=<address>,...::
	Specify a "Bcc:" value for each email. Default is the value of
	`sendemail.bcc`.
+
This option may be specified multiple times.

--cc=<address>,...::
	Specify a starting "Cc:" value for each email.
	Default is the value of `sendemail.cc`.
+
This option may be specified multiple times.

--compose::
	Invoke a text editor (see GIT_EDITOR in linkgit:git-var[1])
	to edit an introductory message for the patch series.
+
When `--compose` is used, git send-email will use the From, To, Cc, Bcc,
Subject, Reply-To, and In-Reply-To headers specified in the message. If
the body of the message (what you type after the headers and a blank
line) only contains blank (or Git: prefixed) lines, the summary won't be
sent, but the headers mentioned above will be used unless they are
removed.
+
Missing From or In-Reply-To headers will be prompted for.
+
See the CONFIGURATION section for `sendemail.multiEdit`.

--from=<address>::
	Specify the sender of the emails.  If not specified on the command line,
	the value of the `sendemail.from` configuration option is used.  If
	neither the command-line option nor `sendemail.from` are set, then the
	user will be prompted for the value.  The default for the prompt will be
	the value of GIT_AUTHOR_IDENT, or GIT_COMMITTER_IDENT if that is not
	set, as returned by "git var -l".

--reply-to=<address>::
	Specify the address where replies from recipients should go to.
	Use this if replies to messages should go to another address than what
	is specified with the --from parameter.

--in-reply-to=<identifier>::
	Make the first mail (or all the mails with `--no-thread`) appear as a
	reply to the given Message-ID, which avoids breaking threads to
	provide a new patch series.
	The second and subsequent emails will be sent as replies according to
	the `--[no-]chain-reply-to` setting.
+
So for example when `--thread` and `--no-chain-reply-to` are specified, the
second and subsequent patches will be replies to the first one like in the
illustration below where `[PATCH v2 0/3]` is in reply to `[PATCH 0/2]`:
+
  [PATCH 0/2] Here is what I did...
    [PATCH 1/2] Clean up and tests
    [PATCH 2/2] Implementation
    [PATCH v2 0/3] Here is a reroll
      [PATCH v2 1/3] Clean up
      [PATCH v2 2/3] New tests
      [PATCH v2 3/3] Implementation
+
Only necessary if --compose is also set.  If --compose
is not set, this will be prompted for.

--[no-]outlook-id-fix::
	Microsoft Outlook SMTP servers discard the Message-ID sent via email and
	assign a new

Title: Git Send Email Documentation
Summary
The git-send-email command is used to send a collection of patches as emails, with configurable headers and options for composing and editing the email content, including support for various patch formats, such as mbox and the original format used by Greg Kroah-Hartman's script, and allowing for customization of sender, recipient, and reply-to addresses, as well as the ability to specify introductory messages and edit patches before sending.