changeset 9242:6fd3f795e908

issue1251: bail if darcs version is too old
author Bryan O'Sullivan <bos@serpentine.com>
date Sat, 25 Jul 2009 10:08:20 -0700
parents b6cb3af61582
children df21a009c9c4 ca143d86727c
files hgext/convert/darcs.py
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/convert/darcs.py	Fri Jul 24 12:20:40 2009 +0200
+++ b/hgext/convert/darcs.py	Sat Jul 25 10:08:20 2009 -0700
@@ -36,6 +36,10 @@
             raise NoRepo("%s does not look like a darcs repo" % path)
 
         checktool('darcs')
+        version = self.run0('--version').splitlines()[0].strip()
+        if version < '2.1':
+            raise util.Abort(_('darcs version 2.1 or newer needed (found %r)') %
+                             version)
 
         if ElementTree is None:
             raise util.Abort(_("Python ElementTree module is not available"))