- # ignore the first 2 lines
- # e.g. '#LyX file created ...'
- # '\lyxformat ...'
- if lines1[2:] != lines2[2:]:
- diff = difflib.unified_diff(lines1, lines2, lyxfile1, lyxfile2, t1, t2)
- sys.stdout.writelines(diff)
- errors.append(f)
+ # ignore the first line e.g. the version of lyx
+ if not compareLyx(lines1, lines2):
+ diff = difflib.unified_diff(lines1, lines2, lyxfile1, lyxfile2, t1, t2)
+ sys.stdout.writelines(diff)
+ errors.append(f)
+