diff --git a/Readme.md b/Readme.md index bb45d52..ab2f282 100644 --- a/Readme.md +++ b/Readme.md @@ -62,8 +62,9 @@ To get proper completion and errors in the editor when working on this repo, "venvPath": ".", "venv": "sublime-modelines", "extraPaths": [ - "/Applications/Sublime Text.app/Contents/MacOS/Lib/python38", - "/Users/YOUR_USER_NAME/Library/Application Support/Sublime Text/Lib/python38", + /* Replace python314 by python38 if you’re on Sublime <4213 (Python 3.8 instead of 3.14). */ + "/Applications/Sublime Text.app/Contents/MacOS/Lib/python314", + "/Users/YOUR_USER_NAME/Library/Application Support/Sublime Text/Lib/python314", "/Users/YOUR_USER_NAME/Library/Application Support/Sublime Text/Packages/UnitTesting", ] } diff --git a/app/modeline_parsers/legacy_vim.py b/app/modeline_parsers/legacy_vim.py index e9f64b4..7cb70d9 100644 --- a/app/modeline_parsers/legacy_vim.py +++ b/app/modeline_parsers/legacy_vim.py @@ -51,14 +51,14 @@ def parser_data_for_view(self, view: SublimeView) -> object: __MODELINE_TYPE_1 = re.compile(r"[\x20\t](st|sublime|vim):\x20?set\x20(.*):.*$") __MODELINE_TYPE_2 = re.compile(r"[\x20\t](st|sublime|vim):(.*):.*$") - __KEY_VALUE = re.compile(r""" - (?x) \s* - (?P\w+) \s* (?P\+?=) \s* (?P - (?: "(?:\\.|[^"\\])*" - | [\[\{].* - | [^\s:]+ - ) - )""" + __KEY_VALUE = re.compile( + r"""(?x) \s* + (?P\w+) \s* (?P\+?=) \s* (?P + (?: "(?:\\.|[^"\\])*" + | [\[\{].* + | [^\s:]+ + ) + )""" ) __KEY_ONLY = re.compile(r"""(?x)\s*(?P\w+)""")