From: Sebastian Schuberth <sschuberth@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Boris Faure <billiob@gmail.com>, git@vger.kernel.org
Subject: Re: [PATCH 1/2] commit: do not cleanup template
Date: Sun, 08 May 2011 10:38:28 +0200 [thread overview]
Message-ID: <4DC65684.1050606@gmail.com> (raw)
In-Reply-To: <7vwri2uv4m.fsf@alter.siamese.dyndns.org>
On 07.05.2011 22:13, Junio C Hamano wrote:
> My gut feeling is that it is relatively easy to justify [1/2]. We prepare
> the message file to be edited by the committer in sb by reading from
> different message sources, and usually we would want to clean up what is
> in sb before writing it out, but you may want to enforce a particular
> format by using the template (such as having a leading whitespace) and the
> way to tweak and fix that appearance should be by editing the template,
> not by automatically running stripspace() here [*1*] when the message came
> from the template.
FYI, Boris' patch pretty much matches the one I proposed back in [1] (or the slightly improved version in [2]). My commit message gives additional reasoning why whitespace in general should not be stripped from templates. IIRC, the only reason my patch was not accepted back then was that I was too lazy to write a test against it.
[1] http://kerneltrap.org/mailarchive/git/2010/3/10/25306
[2] http://repo.or.cz/w/git/mingw/4msysgit.git/commitdiff/39228f1b8af3eb6a6108c4fabf398d23a97a5993
--
Sebastian Schuberth
next prev parent reply other threads:[~2011-05-08 8:38 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-07 15:53 [PATCH 1/2] commit: do not cleanup template Boris Faure
2011-05-07 15:53 ` [PATCH 2/2] commit: do not add a newline after a template Boris Faure
2011-05-07 20:13 ` [PATCH 1/2] commit: do not cleanup template Junio C Hamano
2011-05-07 21:17 ` Boris 'billiob' Faure
2011-05-07 22:31 ` Junio C Hamano
2011-05-08 8:38 ` Sebastian Schuberth [this message]
2011-05-08 8:47 ` Sebastian Schuberth
2011-05-08 10:31 ` [PATCH/RFC v2] Do not strip empty lines / trailing spaces from a commit message template Boris Faure
2011-05-08 12:28 ` Sebastian Schuberth
2011-05-08 18:14 ` Junio C Hamano
2011-05-08 18:55 ` [PATCH/RFC v3] " Boris Faure
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=4DC65684.1050606@gmail.com \
--to=sschuberth@gmail.com \
--cc=billiob@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/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).