hcl/extras/grammar/HCLExpression.tmLanguage

336 lines
8.7 KiB
Plaintext
Raw Normal View History

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>fileTypes</key>
<array>
</array>
<key>name</key>
<string>HCL Expression</string>
<key>patterns</key>
<array>
<dict>
<key>begin</key>
<string>#|//</string>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.comment.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Comments</string>
<key>end</key>
<string>$\n?</string>
<key>name</key>
<string>comment.line.hcl</string>
</dict>
<dict>
<key>begin</key>
<string>/\*</string>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.comment.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Block comments</string>
<key>end</key>
<string>\*/</string>
<key>name</key>
<string>comment.block.hcl</string>
</dict>
<dict>
<key>comment</key>
<string>Language constants (true, false, null)</string>
<key>match</key>
<string>\b(true|false|null)\b</string>
<key>name</key>
<string>constant.language.hcl</string>
</dict>
<dict>
<key>comment</key>
<string>Numbers</string>
<key>match</key>
<string>\b([0-9]+)(.[0-9]+)?([eE][0-9]+)?\b</string>
<key>name</key>
<string>constant.numeric.hcl</string>
</dict>
<dict>
<key>begin</key>
<string>([-\w]+)(\()</string>
<key>beginCaptures</key>
<dict>
<key>1</key>
<dict>
<key>name</key>
<string>keyword.other.function.inline.hcl</string>
</dict>
<key>2</key>
<dict>
<key>name</key>
<string>keyword.other.section.begin.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Function Calls</string>
<key>end</key>
<string>(\))</string>
<key>endCaptures</key>
<dict>
<key>1</key>
<dict>
<key>name</key>
<string>keyword.other.section.end.hcl</string>
</dict>
</dict>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>$self</string>
</dict>
</array>
</dict>
<dict>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>variable.other.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Variables and Attribute Names</string>
<key>match</key>
<string>[-\w]+</string>
</dict>
<dict>
<key>begin</key>
<string>(?&gt;\s*&lt;&lt;(\w+))</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.begin.hcl</string>
</dict>
<key>1</key>
<dict>
<key>name</key>
<string>keyword.operator.heredoc.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Heredoc Templates</string>
<key>end</key>
<string>^\s*\1$</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.end.hcl keyword.operator.heredoc.hcl</string>
</dict>
</dict>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>source.hcltemplate</string>
</dict>
</array>
</dict>
<dict>
<key>begin</key>
<string>\&#34;</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>string.hcl punctuation.definition.string.begin.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>String Templates</string>
<key>end</key>
<string>\&#34;</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>string.hcl punctuation.definition.string.end.hcl</string>
</dict>
</dict>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>source.hcltemplate</string>
</dict>
<dict>
<key>match</key>
<string>(^&#34;|$\{|%\{)+</string>
<key>name</key>
<string>string.quoted.double.hcl</string>
</dict>
</array>
</dict>
<dict>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>keyword.operator.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Operators</string>
<key>match</key>
<string>(!=|==|&gt;=|&lt;=|&amp;&amp;|\|\||[-+*/%&lt;&gt;!?:])</string>
</dict>
<dict>
<key>begin</key>
<string>\(</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>meta.brace.round.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Parentheses</string>
<key>end</key>
<string>\)</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>meta.brace.round.hcl</string>
</dict>
</dict>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>$self</string>
</dict>
</array>
</dict>
<dict>
<key>begin</key>
<string>\[</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>meta.brace.square.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Tuple Constructor</string>
<key>end</key>
<string>\]</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>meta.brace.square.hcl</string>
</dict>
</dict>
<key>patterns</key>
<array>
<dict>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>keyword.control.hcl</string>
</dict>
</dict>
<key>match</key>
<string>(for|in)</string>
</dict>
<dict>
<key>include</key>
<string>$self</string>
</dict>
</array>
</dict>
<dict>
<key>begin</key>
<string>\{</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>meta.brace.curly.hcl</string>
</dict>
</dict>
<key>comment</key>
<string>Object Constructor</string>
<key>end</key>
<string>\}</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>meta.brace.curly.hcl</string>
</dict>
</dict>
<key>patterns</key>
<array>
<dict>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>keyword.control.hcl</string>
</dict>
</dict>
<key>match</key>
<string>(for|in)</string>
</dict>
<dict>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>keyword.operator.hcl</string>
</dict>
</dict>
<key>match</key>
<string>(=&gt;|\.\.\.)</string>
</dict>
<dict>
<key>include</key>
<string>$self</string>
</dict>
</array>
</dict>
</array>
<key>scopeName</key>
<string>source.hclexpr</string>
<key>uuid</key>
<string>6c358551-0381-4128-9ea3-277b21943b5c</string>
</dict>
</plist>