From: Junio C Hamano <gitster@pobox.com>
To: Trevor Saunders <tbsaunde@tbsaunde.org>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] bisect: improve output when bad commit is found
Date: Mon, 11 May 2015 14:12:51 -0700 [thread overview]
Message-ID: <xmqq4mni3jjg.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <1431377939-13887-1-git-send-email-tbsaunde@tbsaunde.org> (Trevor Saunders's message of "Mon, 11 May 2015 16:58:59 -0400")
Trevor Saunders <tbsaunde@tbsaunde.org> writes:
> When the first bad commit has been found git bisect prints something
> like this
>
> <40 char sha1> is the first bad commit
> Commit <40 char sha1>
> ...
>
> <raw diff output>
>
> The raw diff output is not really useful, and its kind of silly to print
End "something like this" with a colon, and indent the example
display, i.e.
... prints something like this:
<40-hex object name> is the first bad commit
Commit <40-hex object name>
The raw diff output is ...
> the sha1 twice. Instead lets print something like
>
> the first bad commit is
> Commit <sha1>
> ...
Likewise.
> This also fixes an odd inconsistancy where if the first bad commit is a
> trivial merge git bisect will only print the first line.
> ---
Sign-off?
> - printf("%s is the first bad commit\n", bisect_rev_hex);
> + puts("the first bad commit is");
s/the/The/, I would think.
> diff --git a/t/t6030-bisect-porcelain.sh b/t/t6030-bisect-porcelain.sh
> index 06b4868..bf50d20 100755
> --- a/t/t6030-bisect-porcelain.sh
> +++ b/t/t6030-bisect-porcelain.sh
> @@ -26,6 +26,14 @@ add_line_into_file()
> git commit --quiet -m "$MSG" $_file
> }
>
> +check_bisect_msg()
> +{
Find this paragraph in Documentation/CodingGuidelines:
- We prefer a space between the function name and the parentheses,
and no space inside the parentheses. The opening "{" should also
be on the same line.
> + file=$1
> + hash=$2
> + grep "the first bad commit is" $file || return $?
> + grep $hash $file || return $?
Is it OK to have these strings anywhere in the $file?
Thanks.
next prev parent reply other threads:[~2015-05-11 21:12 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-11 20:58 [PATCH] bisect: improve output when bad commit is found Trevor Saunders
2015-05-11 21:12 ` Junio C Hamano [this message]
2015-05-11 23:11 ` Trevor Saunders
2015-05-12 2:08 ` Junio C Hamano
2015-05-12 2:10 ` Trevor Saunders
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=xmqq4mni3jjg.fsf@gitster.dls.corp.google.com \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=tbsaunde@tbsaunde.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.