case sensitivity on Windows

Mark Hammond mhammond at skippinet.com.au
Sat Oct 11 00:55:26 BST 2008


Alex writes:

> >> One possibility would be to have the behavior:
> >>
> >> % bzr st
> >> renamed:
> >>   Foo => foo
> >> modified:
> >>   foo
> >>
> >> So we automatically detect the rename.
> >
> > My point is that on Windows, this is *not* a "rename" in a practical
> sense.  The same name used in the past can still be used on the new
> name, where that isn't true of a "real" rename.  ie, just because some
> editor changed the case of a file, no other windows program would be
> affected, so bzr should not either.

As mentioned, I think this is an edge case we are unlikely to hit, given Python imposes case-matching semantics on Windows and they almost never get in the way either.

But it is worth agreeing on the semantics for the edge cases.

> IMO it should be tracked as rename. Although it's not truly rename, but
> it is for bzr.

What makes it a 'rename' for bzr any more than:
% echo > foo
% bzr add Foo
% bzr ci foo

Isn't an implied rename?  IMO it should be a rename for bzr only when the user tells bzr it is a rename.  So 'bzr mv Foo foo' should do the right thing on Windows, but IMO, the mere fact that some app "accidently" changed the case of a file on disk should not imply a rename.

It's probably more important we put further use-cases and scenarios forward though - we should be able to get the point where the desired semantics are somewhat "obvious" once they are all looked at together.
 
Cheers,

Mark




More information about the bazaar mailing list