git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alex Riesen <raa.lkml@gmail.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] git-commit: add --verbatim to allow unstripped commit messages
Date: Fri, 21 Dec 2007 00:33:24 +0100	[thread overview]
Message-ID: <20071220233324.GB3052@steel.home> (raw)
In-Reply-To: <alpine.LFD.0.9999.0712201324270.21557@woody.linux-foundation.org>

Linus Torvalds, Thu, Dec 20, 2007 22:40:13 +0100:
> On Thu, 20 Dec 2007, Alex Riesen wrote:
> > 
> > I just happen to have a corporate template (for perforce messages, I
> > reuse it my git mirror repo) which contains "#" and at least one time
> > lost my bash comments in a commit.
> 
> I think that this is a real bug, but I don't think this is something that 
> we should add a flag for.
> 
> Basically, I don't think we should really strip lines starting with '#' 
> unless *we* added them. In particular, I don't think we should strip them 
> at all unless we're running the editor.

Right

> That may be enough for your case, although it still does leave the "use 
> editor on a template thing", so if that is your usage scenario, I guess we 
> still do need a flag for it.

Yes, I afraid I need both. I use "git commit -t" almost (submission in
perforce takes careful planning) every day. I also would like to keep
the empty leading and trailing lines (perforce default GUI P4Win does
not show them, but our scripts which check the descriptions will test
the description text according to template which does have trailing
empty lines).

> But even if we *do* add a flag (like "--verbatim") you should at the 
> *least* also then remove the
> 
> 	"# (Comment lines starting with '#' will not be included)\n"
> 
> printout! Which you didn't.

I did think about it. It wont be read, I believe (at least I ignore
the status listing git-commit generates today). But then, it can be
removed for verbatim message as no one (I think) will probably care.
Including the "Please..." so it does not look stupid in the commit
message later. Will do.

> > It also implies --allow-empty.
> 
> I disagree with this one too.
> 

I agree. Will remove (I am not even sure myself, why I did that. It is
not even tested)

  reply	other threads:[~2007-12-20 23:33 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-20 21:18 [PATCH] git-commit: add --verbatim to allow unstripped commit messages Alex Riesen
2007-12-20 21:40 ` Linus Torvalds
2007-12-20 23:33   ` Alex Riesen [this message]
2007-12-20 23:35     ` Alex Riesen
2007-12-20 23:37       ` [PATCH] Only filter "#" comments from commits if the editor is used Alex Riesen
2007-12-20 23:39         ` Junio C Hamano
2007-12-20 23:43           ` Alex Riesen
2007-12-20 23:43         ` Junio C Hamano
2007-12-20 23:48       ` [PATCH] Fix thinko in checking for commit message emptiness Alex Riesen
2007-12-20 23:55     ` [PATCH] git-commit: add --verbatim to allow unstripped commit messages Linus Torvalds
2007-12-21  0:14       ` Björn Steinbrink
2007-12-21  0:49         ` Linus Torvalds
2007-12-20 23:50   ` Junio C Hamano
2007-12-21  0:03     ` Linus Torvalds
2007-12-21 17:35       ` [PATCH] Allow selection of different cleanup modes for " Alex Riesen
2007-12-21 21:43         ` Junio C Hamano
2007-12-21 23:08           ` Alex Riesen
2007-12-22  7:59             ` Junio C Hamano
2007-12-22 18:46               ` Alex Riesen
2007-12-22 19:18                 ` Linus Torvalds
2007-12-22 19:41                   ` Junio C Hamano
2007-12-23  3:01                   ` Junio C Hamano
2007-12-23  3:46                     ` Junio C Hamano

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=20071220233324.GB3052@steel.home \
    --to=raa.lkml@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=torvalds@linux-foundation.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;
as well as URLs for NNTP newsgroup(s).