tests/filtercr.py
author Patrick Mezard <patrick@mezard.eu>
Wed, 11 Apr 2012 11:32:00 +0200
changeset 16411 4c2edcd84175
parent 13141 6cfe17c19ba2
permissions -rwxr-xr-x
graphlog: correctly handle calls in subdirectories

#!/usr/bin/env python

# Filter output by the progress extension to make it readable in tests

import sys, re

for line in sys.stdin:
    line = re.sub(r'\r+[^\n]', lambda m: '\n' + m.group()[-1:], line)
    sys.stdout.write(line)
print