git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Jan Krüger" <jk@jk.gs>
To: Git ML <git@vger.kernel.org>
Subject: More noise when parsing ref args?
Date: Sat, 7 Feb 2009 16:48:19 +0100	[thread overview]
Message-ID: <20090207164819.7150661a@perceptron> (raw)

Good day,

I heard a (quite valid) complaint on IRC about a confusing error
message. The command used was "git show <commit>:foo", where foo was a
working tree file in the CWD (a non-toplevel dir of the repository).
Obviously this couldn't have worked but the error message was the usual
"ambiguous argument" message output by verify_filename(). That message
doesn't really make clear the fact that the commit object was found but
the path wasn't. It's easy for someone with less experience to read the
message as "either the <commit> or the path suffix you gave was wrong".

It would be great adding another message that points out what exactly
went wrong in looking up the object, but that message would then appear
in plumbing. So what's the policy on adding new error messages to
plumbing? If it's a bad idea: I remember that a couple of months ago
some error handling code was changed to allow overloading messages from
porcelain. Can that be extended with a reasonable amount of effort?

-Jan

                 reply	other threads:[~2009-02-07 15:49 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20090207164819.7150661a@perceptron \
    --to=jk@jk.gs \
    --cc=git@vger.kernel.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).