high-res mtimes
Cache high-resolution mtimes for improved detection of modified files in v7 (and direct mode). Including on Windows. With back-compat support so old low-res mtimes won't break anything, and so the new information also won't break old versions of git-annex.
This commit is contained in:
parent
48af284872
commit
5ab0f48ffb
7 changed files with 109 additions and 31 deletions
|
@ -766,6 +766,10 @@ isUnmodified key f = go =<< geti
|
|||
|
||||
{- Cheap check if a file contains the unmodified content of the key,
|
||||
- only checking the InodeCache of the key.
|
||||
-
|
||||
- Note that, on systems not supporting high-resolution mtimes,
|
||||
- this may report a false positive when repeated edits are made to a file
|
||||
- within a small time window (eg 1 second).
|
||||
-}
|
||||
isUnmodifiedCheap :: Key -> FilePath -> Annex Bool
|
||||
isUnmodifiedCheap key f = maybe (return False) (isUnmodifiedCheap' key)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue