Thread (7 messages) flat view 7 messages, 5 authors, 2016-06-15

Re: Seeing various mode changes on cygwin

From: Daniel Barkalow <hidden>
Date: 2016-06-15 22:42:08

On Sat, 8 Oct 2005, Linus Torvalds wrote:
I think we might want to have a flag that says "don't care about 
filesystem modes". That should be pretty easy, I think we'd get most of 
them by just adding some logic to "ce_match_stat()".

Then add a "git chmod" to set the mode in the index (which should end up 
being just a wrapper around the regular "git-update-index" using the 
"--cacheinfo" flag, I think).

Those parts should be trivial.

The more interesting issue is how to set the _flag_ that we should do 
this. We may have to add a config file, and it should be per-repository 
(ie something like ".git/config" or ".git/info/config"). Or do we just do 
yet another environment variable?
Perhaps have a bit in the index mode for the file to say that the mode in 
the filesystem is unreliable, which gets set if a stat of the 
newly-written file doesn't match the mode it was supposed to have, or if 
git chmod is used to change it; then, if the bit is set, ignore the mode 
in the filesystem and just use the mode in the index.

This should prevent modes from magically changing, even if the user 
doesn't do anything special.

	-Daniel
*This .sig left intentionally blank*
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help