From: Junio C Hamano <gitster@pobox.com>
To: しらいしななこ <nanako3@bluebottle.com>
Cc: Johannes Schindelin <Johannes.Schindelin@gmx.de>,
"Shawn O. Pearce" <spearce@spearce.org>,
Bernt Hansen <bernt@alumni.uwaterloo.ca>,
git@vger.kernel.org
Subject: Re: [PATCH] Force new line at end of commit message
Date: Sun, 30 Dec 2007 04:21:25 -0800 [thread overview]
Message-ID: <7v8x3c8jay.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <200712301158.lBUBwT3r004608@mi1.bluebottle.com> (nanako3@bluebottle.com's message of "Sun, 30 Dec 2007 20:57:49 +0900")
しらいしななこ <nanako3@bluebottle.com> writes:
>> Heh, I can see that you do not care---the original did not even
>> add a newline when necessary (and that is why we have this
>> thread). Instead you were adding a newline regardless to the
>> end of the first commit, but not doing so for the other ones.
>
> Aren't you being too harsh on Johannes these days?
Not on purpose, but perhaps I might have been.
> Everybody knows that you are capable of rewriting that part in Perl or Python yourself to fix the issue.
I actually have been trying to avoid Perl (let alone Python nor
Ruby) as "rebase -i" is primarily Johannes's bailiwick, and I
had an impression that he avoided them for Windows portability.
Unfortunately, sed does not handle incomplete lines well, at
least portably. POSIX says very little about it, except that
its input shall be "text files" (i.e. no NUL is allowed, each
line separated with <newline> and with less than {LINE_MAX}
bytes in length), and its default operation shall read each line
less its terminating <newline> and after manipulation spit it
out and immediately follow it with a <newline>. But a popular
implementation (e.g. GNU) actually does not follow the output
with a <newline> if the input was incomplete line [*1*]
[Footnote]
*1* Otherwise, this would have been a way to add a
missing newline to a file that could end with an incomplete
line:
$ sed -e '' <$file_that_may_end_with_an_incomplete_line
next prev parent reply other threads:[~2007-12-30 12:22 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-20 0:35 git rebase -i / git-gui bug Bernt Hansen
2007-12-20 4:47 ` Bernt Hansen
2007-12-20 7:12 ` [PATCH] Reallow git-rebase --interactive --continue if commit is unnecessary Shawn O. Pearce
2007-12-20 7:15 ` Junio C Hamano
2007-12-20 7:31 ` Shawn O. Pearce
2007-12-20 9:35 ` Junio C Hamano
2007-12-26 23:48 ` Junio C Hamano
2007-12-29 13:26 ` Johannes Schindelin
2007-12-20 7:52 ` Matthieu Moy
2007-12-24 14:31 ` [PATCH] Force new line at end of commit message Bernt Hansen
2007-12-24 17:38 ` Johannes Schindelin
2007-12-25 4:42 ` Shawn O. Pearce
2007-12-25 9:34 ` Junio C Hamano
2007-12-26 17:47 ` Bernt Hansen
2007-12-27 4:19 ` Shawn O. Pearce
2007-12-28 2:15 ` [PATCH] git-gui: Make commit log messages end with a newline Bernt Hansen
2007-12-26 19:36 ` [PATCH] Force new line at end of commit message Junio C Hamano
2007-12-29 13:31 ` Johannes Schindelin
2007-12-30 0:19 ` Junio C Hamano
2007-12-30 10:26 ` Johannes Schindelin
2007-12-30 10:51 ` Junio C Hamano
2007-12-30 11:03 ` Johannes Schindelin
2007-12-30 11:45 ` Junio C Hamano
2007-12-30 11:57 ` しらいしななこ
2007-12-30 12:21 ` Junio C Hamano [this message]
2007-12-30 12:05 ` Junio C Hamano
2007-12-30 15:50 ` Johannes Schindelin
2007-12-25 4:46 ` Shawn O. Pearce
[not found] <200712301158.lBUBwT3u004608@mi1.bluebottle.com>
2007-12-30 15:51 ` Johannes Schindelin
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=7v8x3c8jay.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=bernt@alumni.uwaterloo.ca \
--cc=git@vger.kernel.org \
--cc=nanako3@bluebottle.com \
--cc=spearce@spearce.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).