git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* rev-list and "ambiguous" IDs
@ 2019-11-14  4:35 Bryan Turner
  2019-11-14  5:59 ` Jeff King
  0 siblings, 1 reply; 13+ messages in thread
From: Bryan Turner @ 2019-11-14  4:35 UTC (permalink / raw)
  To: Git Users

When using a command like `git rev-list dc41e --`, it's possible to
get output like this: (from newer Git versions)
error: short SHA1 dc41e is ambiguous
hint: The candidates are:
hint:   dc41eeb01ba commit 2012-11-23 - Stuff from the commit message
hint:   dc41e0d508b tree
hint:   dc41e5bef41 tree
hint:   dc41e11ee18 blob
fatal: bad revision 'dc41e'

Is there any way to ask rev-list to be a little...pickier about what
it considers a candidate? Almost without question the two trees and
the blob aren't what I'm asking for, which means there's actually only
one real candidate.

Also, while considering this, I noticed that `git rev-list
dc41e11ee18` (the blob from the output above) doesn't fail. It
silently exits, nothing written to stdout or stderr, with 0 status. A
little surprising; I would have expected rev-list to complain that
dc41e11ee18 isn't a valid commit-ish value.

Bryan

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2019-11-19  1:24 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-14  4:35 rev-list and "ambiguous" IDs Bryan Turner
2019-11-14  5:59 ` Jeff King
2019-11-15  0:12   ` Thomas Braun
2019-11-15  3:49     ` Jeff King
2019-11-15 23:38       ` Thomas Braun
2019-11-16  3:47         ` Junio C Hamano
2019-11-18 12:03           ` Jeff King
2019-11-19  1:24             ` Junio C Hamano
2019-11-15  5:07     ` Junio C Hamano
2019-11-15  8:16       ` Jeff King
2019-11-15 11:23         ` Junio C Hamano
2019-11-15  1:19   ` Bryan Turner
2019-11-15  3:57     ` Jeff King

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).