Hello Jeff!

Jeff King <p...@peff.net> wrote:
 |On Thu, Jun 30, 2016 at 09:38:45PM +0200, Steffen Nurpmeso wrote:
 |> For some time (currently with 2.9.0) know see that a single commit
 |> gives a longer hash than necessary, even though there is no
 |> ambiguity:

 |I don't know what your "git longca" alias is, but presumably it's
 |running "git log". That will show just _commit_ hashes, but the
 |abbreviation code will consider all objects.

Ah!  That indeed explains it, i didn't know that!

 |There are some places you can use an abbreviated sha1 that know they are
 |looking for a commit, but most places will generally complain if there
 |is ambiguity between a blob and commit (e.g., "git show $foo").

 |Try "git rev-list --objects --all | grep ^786d0c9".

It clashes a file blob:

  ?0[steffen@wales ]$ git rev-list --objects --all | grep ^786d0c9
  786d0c9c88e5d69eba603e3ed75d1f9cc6ec4e81
  786d0c9d09aaf4107bcaf6c201307ed9db205df5 dotlock.c

Thanks for the explanation!
It seems the left side of my brain degenerates faster than the
right one.  Uff.  How lucky i am!
Ciao.

--steffen
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to