cheat/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/powerquery.xml
Christopher Allen Lane 1790aec85d chore(deps): bump chroma to v2 #735
Bump `alecthomas/chroma` to `v2`:
https://github.com/cheat/cheat/issues/735
2023-12-13 12:54:32 -05:00

51 lines
No EOL
1.6 KiB
XML

<lexer>
<config>
<name>PowerQuery</name>
<alias>powerquery</alias>
<alias>pq</alias>
<filename>*.pq</filename>
<mime_type>text/x-powerquery</mime_type>
<case_insensitive>true</case_insensitive>
<dot_all>true</dot_all>
</config>
<rules>
<state name="root">
<rule pattern="\s+">
<token type="Text"/>
</rule>
<rule pattern="//.*?\n">
<token type="CommentSingle"/>
</rule>
<rule pattern="/\*.*?\*/">
<token type="CommentMultiline"/>
</rule>
<rule pattern="&#34;(\\\\|\\&#34;|[^&#34;])*&#34;">
<token type="LiteralString"/>
</rule>
<rule pattern="(and|as|each|else|error|false|if|in|is|let|meta|not|null|or|otherwise|section|shared|then|true|try|type)\b">
<token type="Keyword"/>
</rule>
<rule pattern="(#binary|#date|#datetime|#datetimezone|#duration|#infinity|#nan|#sections|#shared|#table|#time)\b">
<token type="KeywordType"/>
</rule>
<rule pattern="(([a-zA-Z]|_)[\w|._]*|#&#34;[^&#34;]+&#34;)">
<token type="Name"/>
</rule>
<rule pattern="0[xX][0-9a-fA-F][0-9a-fA-F_]*[lL]?">
<token type="LiteralNumberHex"/>
</rule>
<rule pattern="([0-9]+\.[0-9]+|\.[0-9]+)([eE][0-9]+)?">
<token type="LiteralNumberFloat"/>
</rule>
<rule pattern="[0-9]+">
<token type="LiteralNumberInteger"/>
</rule>
<rule pattern="[\(\)\[\]\{\}]">
<token type="Punctuation"/>
</rule>
<rule pattern="\.\.|\.\.\.|=&gt;|&lt;=|&gt;=|&lt;&gt;|[@!?,;=&lt;&gt;\+\-\*\/&amp;]">
<token type="Operator"/>
</rule>
</state>
</rules>
</lexer>