git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Gerrit Pape <pape@smarden.org>
Cc: Andreas Ericsson <ae@op5.se>, git@vger.kernel.org
Subject: Re: [PATCH] hooks--update: fix test for properly set up project description file
Date: Thu, 08 Nov 2007 14:13:38 -0800	[thread overview]
Message-ID: <7v640c1j3h.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <20071108140200.24902.qmail@f23d7e396b1523.315fe32.mid.smarden.org> (Gerrit Pape's message of "Thu, 8 Nov 2007 14:02:00 +0000")

Gerrit Pape <pape@smarden.org> writes:

> The update hook template intends to abort if the project description file
> hasn't been adjusted or is empty.  This patch fixes the check for 'being
> adjusted'.
>
> Signed-off-by: Gerrit Pape <pape@smarden.org>
> ---
>
> On Tue, Nov 06, 2007 at 02:55:55PM +0100, Andreas Ericsson wrote:
>> Gerrit Pape wrote:
>> > # check for no description
>> >-projectdesc=$(sed -e '1p' "$GIT_DIR/description")
>> >-if [ -z "$projectdesc" -o "$projectdesc" = "Unnamed repository; edit
>> >this
>> >file to name it for gitweb" ]; then
>> >+projectdesc=$(sed -ne '1p' "$GIT_DIR/description")
>>
>> Write this as
>>       projectdesc=$(sed -e 1q "$GIT_DIR/description")
>> instead. It's a little shorter, a little faster and slightly more
>> portable.

I even suspect that the original 'p' is indeed a typo of 'q'.

      reply	other threads:[~2007-11-08 22:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-06 13:47 [PATCH] hooks--update: fix test for properly set up project description file Gerrit Pape
2007-11-06 13:55 ` Andreas Ericsson
2007-11-08 14:02   ` Gerrit Pape
2007-11-08 22:13     ` Junio C Hamano [this message]

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=7v640c1j3h.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=ae@op5.se \
    --cc=git@vger.kernel.org \
    --cc=pape@smarden.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).