Git development
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Mark A Rada <marada@uwaterloo.ca>
Cc: Jakub Narebski <jnareb@gmail.com>, git@vger.kernel.org
Subject: Re: [RFC] gitweb.perl t9500 t9501
Date: Sat, 22 Aug 2009 19:09:57 -0700	[thread overview]
Message-ID: <7v3a7j2scq.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <4C812C4E-815B-478D-AEB1-3F1DEC5D3641@mailservices.uwaterloo.ca> (Mark A. Rada's message of "Sat\, 22 Aug 2009 18\:42\:56 -0400")

Mark A Rada <marada@uwaterloo.ca> writes:

> I have not been telling git-format-patch to use a specific width for
> the diffstat, is the standard width supposed to be 70?

Perhaps there is some misconception here.

We try to keep our _code_ to fit in standard 80-column terminal.  We also
keep lines in the _log message_ shorter than 70-something so that after
indentation by various programs (e.g. shortlog) and a few levels of
quoting in the e-mail are added, the lines will still stay below
80-columns.  These are standard practices.

And you may need to find a good place to break lines in your _code_, and
your _log message_, to stay below that limit.

But that all happens inside your editor, before you touch format-patch nor
your MUA.

The patch contents may contain long lines, such as

    diff --git a/filename-that-is-long b/filename-that-is-long

or

    @@ -old,lines +new,lines @@ original contents that is long

that is neither _code_ nor _log message_.  They could easily go beyond
80-column, but that is normal, and they do not have any 70-column limit
for you to worry about.  They follow a different rule, namely, if
format-patch (or "diff" in general) outputs something on a single line,
that has to stay on a single line.  "patch" expects each of these on a
single line.  Do not break them.

So make sure that you do not let your MUA perform any line-wrapping at
random place in the message after you formatted your commits via
format-patch, and you will be Ok.

  reply	other threads:[~2009-08-23  2:11 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-21  2:48 What's cooking in git.git (Aug 2009, #03; Thu, 20) Junio C Hamano
2009-08-21  9:10 ` Paolo Bonzini
2009-08-21 19:36   ` Junio C Hamano
2009-08-21 12:40 ` Mark A Rada
2009-08-21 18:06   ` Jakub Narebski
2009-08-21 20:10     ` Junio C Hamano
2009-08-22 22:42       ` [RFC] gitweb.perl t9500 t9501 Mark A Rada
2009-08-23  2:09         ` Junio C Hamano [this message]
2009-08-23 15:29           ` Mark A Rada
2009-08-21 21:43   ` What's cooking in git.git (Aug 2009, #03; Thu, 20) 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=7v3a7j2scq.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=jnareb@gmail.com \
    --cc=marada@uwaterloo.ca \
    /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