Thread (12 messages) flat view 12 messages, 3 authors, 2016-06-15

Re: ident hash usage question

From: Alex Riesen <hidden>
Date: 2016-06-15 22:47:35

On Tue, Oct 20, 2009 at 20:59, Eugene Sajine [off-list ref] wrote:
quoted
Well, not exactly impossible, but you can end up with multiple paths,
some of which may not have anything to do the original path.

Just run git log --no-abbrev --raw --all and grep for the SHA-1
This is exactly what I was looking for! Thank you!
Very likely it isn't, but it's your choice.
Because after having this hash one can build up all necessary info from it:
Depending on your definition of "necessary".
#finding blobs with SHA indicated in $Id$ keword
$ git log --no-abbrev --raw --all | grep SHA-1
yeah. These are all starting from commit which introduced
the hash under a specific path, ending at the commit where
the path contains another SHA-1.
# little script or regexp here (don’t have it)
$ pull out path from result

# last commit for the path with all corresponding info
$ git log -1 HEAD path

So, this seems to cover most of the needs of people who would like to
use keywords expansion, if they are not ready to forget about them…

Does it make sense?
Not much. You'll always get a long list of commits which didn't
change the damned blob. And you have absolutely no way
to find out exactly which of the commits have produced
the blob you're looking at (because you decided to do away
with the information).

What's so hard with storing the SHA-1 of the *commit*, anyway?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help