diff options
author | Drew DeVault <sir@cmpwn.com> | 2019-06-07 11:14:40 -0400 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2019-06-07 11:14:50 -0400 |
commit | 0647ea64839df5ceecf3a71f672f05a589fd1409 (patch) | |
tree | 63102e7e0bb0167618bfbcb972948e255ae47170 /contrib/hldiff.py | |
parent | e0cadd61a24473e5d41ed3e54f2826b7dd8a8a0e (diff) | |
download | aerc-0647ea64839df5ceecf3a71f672f05a589fd1409.tar.gz |
Move ANSI stripping from filters to Go
Diffstat (limited to 'contrib/hldiff.py')
-rwxr-xr-x | contrib/hldiff.py | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/contrib/hldiff.py b/contrib/hldiff.py index 5f660fd7..f3cfd202 100755 --- a/contrib/hldiff.py +++ b/contrib/hldiff.py @@ -3,13 +3,11 @@ from colorama import Fore, Style import sys import re -ansi_escape = re.compile(r'\x1B\[[0-?]*[ -/]*[@-~]') stat_re = re.compile(r'(| \d+ )(\+*)(\-*)') lines_re = re.compile(r'@@ (-\d+,\d+ \+\d+,\d+) @@') sys.stdin.reconfigure(encoding='utf-8', errors='ignore') patch = sys.stdin.read().replace("\r\n", "\n") -patch = ansi_escape.sub('', patch) hit_diff = False for line in patch.split("\n"): |