From: Julien Rioux Date: Sat, 17 Dec 2011 12:49:02 +0000 (-0500) Subject: Regtest script: Allow to customize the length of shortened strings. X-Git-Tag: release/2.15.24-1~44 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=373203863a8c1cd1a75f8fa947fb93d2b7d21da0;p=lilypond.git Regtest script: Allow to customize the length of shortened strings. --- diff --git a/scripts/build/output-distance.py b/scripts/build/output-distance.py index 941f879f47..647d7bd7af 100755 --- a/scripts/build/output-distance.py +++ b/scripts/build/output-distance.py @@ -53,8 +53,7 @@ def system (c): raise Exception ("failed") return -def shorten_string (s): - threshold = 15 +def shorten_string (s, threshold = 15): if len (s) > 2*threshold: s = s[:threshold] + '..' + s[-threshold:] return s