From: David Kastrup Date: Thu, 2 Aug 2012 08:07:07 +0000 (+0200) Subject: Add convert-ly rule for unquoting tuning assignments X-Git-Tag: release/2.15.95-1~27 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=36bb3e1b30a0bb617faaabe7e8a7e79ac295fe12;p=lilypond.git Add convert-ly rule for unquoting tuning assignments --- diff --git a/python/convertrules.py b/python/convertrules.py index e3d5dd65d0..44ecf049e7 100644 --- a/python/convertrules.py +++ b/python/convertrules.py @@ -3373,6 +3373,13 @@ def conv (str): str = re.sub (r"(\\set\s+)stringTuning", r"\1Staff.stringTuning", str) return str +wordsyntax = r"[a-zA-Z\200-\377](?:[-_]?[a-zA-Z\200-\377])*" + +@rule ((2, 15, 43), r'"custom-tuning" = -> custom-tuning =') +def conv (str): + str = re.sub ('\n"(' + wordsyntax + r')"(\s*=\s*\\stringTuning)', "\n\\1\\2", str) + return str + # Guidelines to write rules (please keep this at the end of this file) # # - keep at most one rule per version; if several conversions should be done,