changeset 3404:0f308690bda8

Fixed contrib/hgdiff script to pass diffopts in the new format.
author Thomas Arendsen Hein <thomas@intevation.de>
date Sun, 15 Oct 2006 20:56:38 +0200
parents f0415b61949d
children 5dbb3a991bbf
files contrib/hgdiff
diffstat 1 files changed, 6 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/hgdiff	Sun Oct 15 16:35:47 2006 +0200
+++ b/contrib/hgdiff	Sun Oct 15 20:56:38 2006 +0200
@@ -5,9 +5,9 @@
 import re
 from optparse import OptionParser
 from mercurial.bdiff import bdiff, blocks
-from mercurial.mdiff import bunidiff
+from mercurial.mdiff import bunidiff, diffopts
 
-VERSION="0.2"
+VERSION="0.3"
 usage = "usage: %prog [options] file1 file2"
 parser = OptionParser(usage=usage)
 
@@ -57,9 +57,10 @@
         if options.difflib:
             l = difflib.unified_diff(l1, l2, file1, file2)
         else:
-            l = bunidiff(t1, t2, l1, l2, file1, file2, context=options.context,
-                     showfunc=options.show_c_function,
-                     ignorews=options.ignore_all_space)
+            l = bunidiff(t1, t2, l1, l2, file1, file2,
+                         diffopts(context=options.context,
+                                  showfunc=options.show_c_function,
+                                  ignorews=options.ignore_all_space))
     for x in l:
         if x[-1] != '\n':
             x += "\n\ No newline at end of file\n"