Hi guys,
Is there any topic for defferences between syntax definition file for ST2 and ST3?
Last year I’ve develop a syntax and autocomletions helper for our own project’s “programming” language.
(Based on ST2 doc)
At first Ive started developing tmlanguage for ST2, but later I’ve switched to ST3 and use old tmLanguage(yaml) file.
Now I want to use full power of ST3 syntax highlighting and I can’t understand the difference between those two formats (Like one here: ST3 Doc) of tmLanguage.
Old one uses:
patterns:
- comment: Tab stops like $1, $2...
name: keyword.other.ssraw
match: \$\d+
repository:
other_definitions:
name: constant.other.tplpre
comment: Tags
match: \s+(tags)\s+(.*?);
…
And etc - which is looks fine for me.
New format is something like:
contexts:
main:
- match: \b(if|else|for|while)\b
scope: keyword.control.c
Which is totally broke my old format and my mind.
- Can I somehow reformat old to new - automatically \ or should I start the develpment from the beggining and forgot the old format?
- Is there huge difference and enchansement or advantages in new format comparing with old one / or it’s better to use old and change nothing?
P.S. I also tried to include new format in old - but it does not work. It builds without errors but not highlighting.
Thanks in advance.