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

Re: Date handling.

From
Linus Torvalds <torvalds@osdl.org>
Date
Apr 14, 2005, 09:00 UTC
Message-ID
<Pine.LNX.4.58.0504140153230.7211@ppc970.osdl.org>
In-Reply-To
<1113466592.12012.192.camel@baythorne.infradead.org>
On Thu, 14 Apr 2005, David Woodhouse wrote:
> 
> I see two possible solutions:
> 	1. Just store seconds-since-GMT-epoch and if we really want, the
> 	   timezone as auxiliary information.

Yeah, I think this is the right thing to do. I can change "commit" to do it.

I used to think that the date was purely a "enforced comment" (like the committer info is, as far as git is concerned), which is why I used the simple textual representation. But yes, when I wrote that "rev-tree" thing I did curse that and consider just changing it.

It's still just technically a "hint", since time isn't synchronized in any way (and in a distributed system, time _cannot_ be synchronized). But it's a useful hint, so ..

> 	2. Store dates in RFC2822 form.
> 
> Unless someone convincingly expresses a preference before I get to work
> and start playing with it, I'll implement the latter.

I do like text output, but if it is painful, the "unix seconds" format is certainly a hell of a lot simpler. And quite frankly, if we change it, we might as well just change it all the way. So I'd almost prefer (1).

But "He who does the work gets to choose the implementation". And I do agree that this is a bad format decision, and that we should change it. It shouldn't even be that painful. Only "rev-tree" cares, and even rev-tree doesn't care _that_ deeply.

		Linus
Previous: David WoodhouseNext: Linus Torvalds
Message 2 of 13 in “Date handling.”
  1. David WoodhouseApr 14, 2005
  2. Linus TorvaldsApr 14, 2005
  3. Linus TorvaldsApr 14, 2005
  4. David WoodhouseApr 14, 2005
  5. tony.luck@intel.comApr 14, 2005
  6. David WoodhouseApr 14, 2005
  7. Jan HarkesApr 24, 2005
  8. James PurserApr 24, 2005
  9. David WoodhouseApr 24, 2005
  10. Russ AllberyApr 24, 2005
  11. Jan HarkesApr 25, 2005
  12. Russ AllberyApr 25, 2005
  13. David WoodhouseApr 14, 2005

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.