From: Junio C Hamano <junkio@cox.net>
To: Andy Parkins <andyparkins@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] Remove use of git-rev-parse and replace git-rev-list --pretty with git-log
Date: Sat, 03 Mar 2007 03:52:51 -0800 [thread overview]
Message-ID: <7virdiczn0.fsf@assigned-by-dhcp.cox.net> (raw)
In-Reply-To: <200703030825.18378.andyparkins@gmail.com> (Andy Parkins's message of "Sat, 3 Mar 2007 08:25:16 +0000")
Andy Parkins <andyparkins@gmail.com> writes:
> Finding the "---" separator between diff and log message could at least
> rely on finding "---" alone on a line so that "--- something else"
> wouldn't trigger the end of log?
>
> I assume this is too simple?
>
> diff --git a/builtin-mailinfo.c b/builtin-mailinfo.c
> index 766a37e..4e0795a 100644
> --- a/builtin-mailinfo.c
> +++ b/builtin-mailinfo.c
> @@ -670,7 +670,7 @@ static int handle_commit_msg(int *seen)
> return 0;
> do {
> if (!memcmp("diff -", line, 6) ||
> - !memcmp("---", line, 3) ||
> + !memcmp("---\n", line, 4) ||
> !memcmp("Index: ", line, 7))
> break;
> if ((multipart_boundary[0] && is_multipart_boundary(line))) {
I think that would make us reject patches that we currently
accept. Today, you can submit a patch created this way:
$ cp Makefile Makefile.orig
$ edit Makefile
$ cat body-of-message
$ echo "Signed-off-by: $me"
$ diff -u Makefile.orig Makefile
The first line of the diff part would be "--- Makefile.orig"
(and the second one begins with "+++ Makefile").
I do not think I've asked Linus about how he originally came up
with "three dashes at the beginning of line" convention in the
kernel circle, but my guess always have been that it would
automatically allow us to accept patches prepared like this.
next prev parent reply other threads:[~2007-03-03 11:52 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-02 10:27 [PATCH] Fix typo on variable name $newref should be $newrev in sample update hook Andy Parkins
2007-03-02 16:44 ` Linus Torvalds
2007-03-02 19:25 ` Andy Parkins
2007-03-02 19:29 ` [PATCH] Remove use of git-rev-parse and replace git-rev-list --pretty with git-log Andy Parkins
2007-03-02 20:48 ` Linus Torvalds
2007-03-02 23:10 ` Junio C Hamano
2007-03-03 8:25 ` Andy Parkins
2007-03-03 11:52 ` Junio C Hamano [this message]
2007-03-04 21:44 ` Linus Torvalds
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=7virdiczn0.fsf@assigned-by-dhcp.cox.net \
--to=junkio@cox.net \
--cc=andyparkins@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.