git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "Christoffer Stjernlöf" <a@xkqr.org>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: Bug: git branch returns EXIT_SUCCESS when no branches found
Date: Wed, 24 Apr 2019 10:53:56 +0000	[thread overview]
Message-ID: <87wojjhdx7.fsf@xkqr.org> (raw)
In-Reply-To: <xmqqimv31y3n.fsf@gitster-ct.c.googlers.com>

[-- Attachment #1: Type: text/plain, Size: 862 bytes --]

Dear Junio,

Junio C Hamano (gitster@pobox.com) 2019-04-24:
> if cs/topic branch does not exist, of if the branch
> does not contain 'master', the command will show "here are the
> branches that match the criteria you gave me" by giving no lines in
> its standard output, and exits with 0 to signal that what you see on
> the screen indeed was computed correctly (as opposed to the command
> internally crashing and failing to produce a result, in which case
> you would want to be told with non-zero exit status).

Thank you for taking the time to elaborate on your already detailed
answer. I can see the concern about separating internal command errors
from correctly computed results, even if those results seem to indicate
something being amiss. Is this not a place where different error codes
can be useful?

Sincerely yours,
Christoffer

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

  reply	other threads:[~2019-04-24 10:54 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-24 10:13 Bug: git branch returns EXIT_SUCCESS when no branches found Christoffer Stjernlöf
2019-04-24 10:36 ` Junio C Hamano
2019-04-24 10:44   ` Junio C Hamano
2019-04-24 10:53     ` Christoffer Stjernlöf [this message]
2019-04-24 10:47   ` Christoffer Stjernlöf
2019-04-24 11:11   ` SZEDER Gábor

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87wojjhdx7.fsf@xkqr.org \
    --to=a@xkqr.org \
    --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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).