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

Re: Git on Windows maps creation time onto changed time

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Feb 2, 2018, 21:18 UTC
Message-ID
<nycvar.QRO.7.76.6.1802022216370.35@ZVAVAG-6OXH6DA.rhebcr.pbec.zvpebfbsg.pbz>
In-Reply-To
<040E3C3E-BC8E-4658-A882-5149D10AD408@blackthorn-media.com>
Hi Keith,
On Fri, 2 Feb 2018, Keith Goldfarb wrote:
Show 14 quoted lines
> > The purpose of these values is to allow to notice a change on the file
> > system without going through the actual file data. Duplicating
> > st_mtime would be pointless.
> 
> Well, I agree with the first statement. I disagree with the 2nd. It’s
> not pointless to fix a problem, and in theory the creation date of a
> file can never change.
> 
> > Don't do that then. Use core.trustctime.
> 
> I am. Unfortunately, my problem isn’t solved by that alone. Perhaps this
> deserves its own thread, but on Windows the st_ino field is set to zero.
> This can also trigger a false positive, causing the whole cache to be
> rebuilt unnecessarily.

You cannot assume that the inode numbers are identical between file systems/operating systems. That's simply not going to work.

I know you really want *so hard* for the same working directory to be accessible from both Windows and Linux. I have a lot of sympathy for that sentiment. Though I do not see much chance for success on that front.

Ciao, Johannes

Previous: Keith GoldfarbNext: Keith Goldfarb
Message 5 of 7 in “Git on Windows maps creation time onto changed time”
  1. Keith GoldfarbFeb 1, 2018
  2. Ævar Arnfjörð BjarmasonFeb 1, 2018
  3. Johannes SixtFeb 2, 2018
  4. Keith GoldfarbFeb 2, 2018
  5. Johannes SchindelinFeb 2, 2018
  6. Keith GoldfarbFeb 2, 2018
  7. Johannes SchindelinFeb 2, 2018

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.