Rev 3650: OSX too needs to accept 'bzr mv foo Foo' when foo and Foo are the same file. in lp:~vila/bzr/wt-ci

Vincent Ladeuil v.ladeuil+lp at free.fr
Tue Aug 26 15:33:56 BST 2008


At lp:~vila/bzr/wt-ci

------------------------------------------------------------
revno: 3650
revision-id: v.ladeuil+lp at free.fr-20080826143353-y4s0frtmvgrsph6g
parent: pqm at pqm.ubuntu.com-20080825182248-dydy5bn4n5akbfjq
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: wt-ci
timestamp: Tue 2008-08-26 16:33:53 +0200
message:
  OSX too needs to accept 'bzr mv foo Foo' when foo and Foo are the same file.
  No new tests (existing ones were failing on OSX), this fixes the code.
  
  * bzrlib/workingtree.py:
  (WorkingTree._determine_mv_mode): Case sensitivity is what matter
  here, it exists outside of win32 (i.e. OSX).
modified:
  bzrlib/workingtree.py          workingtree.py-20050511021032-29b6ec0a681e02e3
-------------- next part --------------
=== modified file 'bzrlib/workingtree.py'
--- a/bzrlib/workingtree.py	2008-07-30 09:50:22 +0000
+++ b/bzrlib/workingtree.py	2008-08-26 14:33:53 +0000
@@ -1316,9 +1316,9 @@
                 only_change_inv = True
             elif self.has_filename(from_rel) and not self.has_filename(to_rel):
                 only_change_inv = False
-            elif (sys.platform == 'win32'
-                and from_rel.lower() == to_rel.lower()
-                and self.has_filename(from_rel)):
+            elif (not self.case_sensitive
+                  and from_rel.lower() == to_rel.lower()
+                  and self.has_filename(from_rel)):
                 only_change_inv = False
             else:
                 # something is wrong, so lets determine what exactly



More information about the bazaar-commits mailing list