git reset and ctime

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I've encountered a strange issue where "git reset --hard" insists on
"Checking out files ..." when all that is changed is the ctime on
these files. My deploy process (capistrano) maintains a cached copy of
a git repo, which it fetches, resets, and then hardlinks files from
when a deploy occurs ( https://github.com/37signals/fast_remote_cache
). The hardlinking step is meant to save the time of copying the file.
but hardlinking changes the ctime of the source files. That causes git
reset to re-check out the files when the next deploy occurs, which is
quite time-consuming. Some helpful people on #git showed that "git
update-index --refresh" before the git reset prevents this behavior,
but I wonder why that is needed at all.

Should git reset be performing whatever "git update-index --refresh"
is doing? Certainly in this case it would result in a vast speed
improvement.

-Greg
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]