0

How can i do this in SublimeText (see the image below)?

image

Is it possible do by using .sublime-syntax (%YAML1.2) or maybe another way?

Will be wonderful if anyone can provide me with some example. Thanks.

hendryanw
  • 1,819
  • 5
  • 24
  • 39
FMarkus
  • 54
  • 4

1 Answers1

0

Ok, nobody knows. This small example how it may works.

%YAML 1.2
---
name: MyCustomSyntax
file_extensions: txt
scope: source.txt

contexts:
  main:
  - comment: "mykey operator definition"
    match: mykey(?= *?= *?\{)
    scope: keyword.txt

  - comment: "mykey structure definition"
    match: mykey(?! *?= *?\{)
    scope: string.txt

  - comment: "other operator definition"
    match: (=|{|})
    scope: comment.txt
FMarkus
  • 54
  • 4