From: Josh Triplett <josht@us.ibm.com>
To: git@vger.kernel.org
Subject: [PATCH 2/3] Add option to disable threading headers
Date: Mon, 10 Jul 2006 11:41:45 -0700 [thread overview]
Message-ID: <1152556906.8890.47.camel@josh-work.beaverton.ibm.com> (raw)
In-Reply-To: <5b476cb7f1440875f348842a2ef581ab882e7d0d.1152550451.git.josh@freedesktop.org>
Add a --no-thread option to disable generation of In-Reply-To and References
headers, normally used to make the second and subsequent mails appear as
replies to the first.
Signed-off-by: Josh Triplett <josh@freedesktop.org>
---
As requested by Johannes Schindelin <johannes.schindelin@gmx.de>.
Documentation/git-format-patch.txt | 8 +++++++-
builtin-log.c | 5 ++++-
2 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/Documentation/git-format-patch.txt b/Documentation/git-format-patch.txt
index 4ca0014..81e3a9a 100644
--- a/Documentation/git-format-patch.txt
+++ b/Documentation/git-format-patch.txt
@@ -9,7 +9,7 @@ git-format-patch - Prepare patches for e
SYNOPSIS
--------
[verse]
-'git-format-patch' [-n | -k] [-o <dir> | --stdout] [--attach]
+'git-format-patch' [-n | -k] [-o <dir> | --stdout] [--attach] [--no-thread]
[-s | --signoff] [--diff-options] [--start-number <n>]
<since>[..<until>]
@@ -35,6 +35,9 @@ they are created in the current working
If -n is specified, instead of "[PATCH] Subject", the first line
is formatted as "[PATCH n/m] Subject".
+The generated mails include In-Reply-To and References headers to make
+the second and subsequent patch mails appear as replies to the first
+mail; --no-thread disables this behavior.
OPTIONS
-------
@@ -63,6 +66,9 @@ OPTIONS
--attach::
Create attachments instead of inlining patches.
+--no-thread::
+ Do not add In-Reply-To and References headers to make the
+ second and subsequent mails appear as replies to the first.
CONFIGURATION
-------------
diff --git a/builtin-log.c b/builtin-log.c
index 9d0cae1..97df715 100644
--- a/builtin-log.c
+++ b/builtin-log.c
@@ -242,6 +242,7 @@ int cmd_format_patch(int argc, const cha
int start_number = -1;
int keep_subject = 0;
int ignore_if_in_upstream = 0;
+ int thread = 1;
struct diff_options patch_id_opts;
char *add_signoff = NULL;
char message_id[1024];
@@ -311,6 +312,8 @@ int cmd_format_patch(int argc, const cha
rev.mime_boundary = argv[i] + 9;
else if (!strcmp(argv[i], "--ignore-if-in-upstream"))
ignore_if_in_upstream = 1;
+ else if (!strcmp(argv[i], "--no-thread"))
+ thread = 0;
else
argv[j++] = argv[i];
}
@@ -373,7 +376,7 @@ int cmd_format_patch(int argc, const cha
commit = list[nr];
rev.nr = total - nr + (start_number - 1);
/* Make the second and subsequent mails replies to the first */
- if (nr == (total - 2)) {
+ if (thread && nr == (total - 2)) {
strncpy(ref_message_id, message_id,
sizeof(ref_message_id));
ref_message_id[sizeof(ref_message_id)-1] = '\0';
--
1.4.1.gf029
next parent reply other threads:[~2006-07-10 18:41 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <5b476cb7f1440875f348842a2ef581ab882e7d0d.1152550451.git.josh@freedesktop.org>
2006-07-10 18:41 ` Josh Triplett [this message]
2006-07-10 18:42 ` [PATCH 3/3] Add option to set initial In-Reply-To/References Josh Triplett
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1152556906.8890.47.camel@josh-work.beaverton.ibm.com \
--to=josht@us.ibm.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox