convert: use git diff-tree -Cn% instead of --find-copies=n% for older git stable
authorThomas Arendsen Hein <thomas@intevation.de>
Thu, 06 Nov 2014 09:36:39 +0100
branchstable
changeset 23206 a7f25a31e021
parent 23199 c35ffa4249ca
child 23223 a4af6fd99fb0
convert: use git diff-tree -Cn% instead of --find-copies=n% for older git The option --find-copies was added in a later git version than the one included in Debian squeeze-lts (1.7.2.5), probably around 1.7.4.
hgext/convert/git.py
--- a/hgext/convert/git.py	Wed Nov 05 17:25:00 2014 +0000
+++ b/hgext/convert/git.py	Thu Nov 06 09:36:39 2014 +0100
@@ -99,7 +99,7 @@
         if similarity < 0 or similarity > 100:
             raise util.Abort(_('similarity must be between 0 and 100'))
         if similarity > 0:
-            self.simopt = '--find-copies=%d%%' % similarity
+            self.simopt = '-C%d%%' % similarity
             findcopiesharder = ui.configbool('convert', 'git.findcopiesharder',
                                              False)
             if findcopiesharder: