diff options
author | serialhex <serialhex@gmail.com> | 2017-06-01 16:22:05 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-06-01 16:22:05 +0300 |
commit | 68784def79f8942e50ce326a465e5ca655a1391a (patch) | |
tree | 9fc48cace7562d27365d8c2a71ded7966563c1c5 | |
parent | f0943e94d28eb17d66df641b1a696c2756aab572 (diff) | |
parent | 6010442f8069c5f01f99415fe1b21e8584e814da (diff) |
Merge pull request #34 from Piterden/patch-4
Create yaml.nanorc
-rw-r--r-- | yaml.nanorc | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/yaml.nanorc b/yaml.nanorc new file mode 100644 index 0000000..36c0b5b --- /dev/null +++ b/yaml.nanorc @@ -0,0 +1,36 @@ +# Supports `YAML` files +syntax "YAML" "\.ya?ml$" +header "^(---|===)" "%YAML" + +## Keys +color magenta "^\s*[\$A-Za-z0-9_-]+\:" +color brightmagenta "^\s*@[\$A-Za-z0-9_-]+\:" + +## Values +color white ":\s.+$" +## Booleans +icolor brightcyan " (y|yes|n|no|true|false|on|off)$" +## Numbers +color brightred " [[:digit:]]+(\.[[:digit:]]+)?" +## Arrays +color red "\[" "\]" ":\s+[|>]" "^\s*- " +## Reserved +color green "(^| )!!(binary|bool|float|int|map|null|omap|seq|set|str) " + +## Comments +color brightwhite "#.*$" + +## Errors +color ,red ":\w.+$" +color ,red ":'.+$" +color ,red ":".+$" +color ,red "\s+$" + +## Non closed quote +color ,red "['\"][^['\"]]*$" + +## Closed quotes +color yellow "['\"].*['\"]" + +## Equal sign +color brightgreen ":( |$)" |