git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: latest blob date (request)

From
Linus Torvalds <torvalds@osdl.org>
Date
Jan 16, 2006, 19:00 UTC
Message-ID
<Pine.LNX.4.64.0601161055300.13339@g5.osdl.org>
In-Reply-To
<20060115173100.1134256b.rdunlap@xenotime.net>
On Sun, 15 Jan 2006, Randy.Dunlap wrote:
Show 7 quoted lines
> 
> I would find it helpful (a user optimization) if each tree list
> contained a date-last-modified/updated.  This could be used
> to help decide if I (someone) wanted to click on a particular
> blob or history (OK, blobs are quick, but history can be
> very time-consuming, so being able to shortcut or skip
> history would be very helpful IMO).
That's fundamentally a very expensive operation in git.

A "blob" doesn't have a date - and indeed, it cannot have one, since the same blob may be associated with multiple different pathnames, and multiple different commits.

If you have a particular pathname, you can ask "when was this pathname changed last", which is basically

	git-rev-list --max-count=1 HEAD -- Makefile 
but that's not very cheap either.
		Linus
Previous: Junio C Hamano
Message 7 of 7 in “latest blob date (request)”
  1. Randy.DunlapJan 16, 2006
  2. Paul MackerrasJan 16, 2006
  3. gitweb: latest blob date (request)Randy.Dunlap, Jan 16, 2006
  4. Kay SieversJan 16, 2006
  5. Randy.DunlapJan 16, 2006
  6. Junio C HamanoJan 16, 2006
  7. Linus TorvaldsJan 16, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.