mirror of
https://github.com/QL-Win/QuickLook.git
synced 2025-09-01 18:35:13 +00:00
Add syntax highlighting for .env files
This commit is contained in:
@@ -0,0 +1,75 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<SyntaxDefinition name="ENV" extensions=".env;.env.local;.env.development;.env.production;.env.test;.env.example">
|
||||
|
||||
<Environment>
|
||||
<Default color="#D4D4D4" bgcolor="#1E1E1E"/>
|
||||
</Environment>
|
||||
|
||||
<Properties>
|
||||
<Property name="LineComment" value="#"/>
|
||||
</Properties>
|
||||
|
||||
<Digits name="Digits" color="#B5CEA8"/>
|
||||
|
||||
<RuleSets>
|
||||
<RuleSet ignorecase="false">
|
||||
|
||||
<Delimiters>&|\/"',;=:-</Delimiters>
|
||||
|
||||
<!-- Comments starting with # -->
|
||||
<Span name="LineComment" stopateol="true" color="#608B4E" bold="false" italic="true">
|
||||
<Begin>#</Begin>
|
||||
</Span>
|
||||
|
||||
<!-- Double quoted strings with escape character support -->
|
||||
<Span name="DoubleQuotedString" stopateol="true" color="#CE9178" bold="false" italic="false" escapecharacter="\">
|
||||
<Begin>"</Begin>
|
||||
<End>"</End>
|
||||
</Span>
|
||||
|
||||
<!-- Single quoted strings -->
|
||||
<Span name="SingleQuotedString" stopateol="true" color="#CE9178" bold="false" italic="false">
|
||||
<Begin>'</Begin>
|
||||
<End>'</End>
|
||||
</Span>
|
||||
|
||||
<!-- Variable expansion ${VAR} or $VAR -->
|
||||
<Span name="VariableExpansion" color="#DCDCAA" bold="true" italic="false">
|
||||
<Begin>${</Begin>
|
||||
<End>}</End>
|
||||
</Span>
|
||||
|
||||
<!-- Environment variable names (before =) -->
|
||||
<MarkPrevious color="#4FC1FF" bold="true" italic="false">=</MarkPrevious>
|
||||
|
||||
<!-- Simple variable reference $VAR -->
|
||||
<MarkFollowing color="#DCDCAA" bold="true" italic="false">$</MarkFollowing>
|
||||
|
||||
<!-- Boolean values -->
|
||||
<KeyWords name="BooleanValues" color="#569CD6" bold="true" italic="false">
|
||||
<Key word="true"/>
|
||||
<Key word="false"/>
|
||||
<Key word="TRUE"/>
|
||||
<Key word="FALSE"/>
|
||||
<Key word="yes"/>
|
||||
<Key word="no"/>
|
||||
<Key word="YES"/>
|
||||
<Key word="NO"/>
|
||||
<Key word="on"/>
|
||||
<Key word="off"/>
|
||||
<Key word="ON"/>
|
||||
<Key word="OFF"/>
|
||||
</KeyWords>
|
||||
|
||||
<!-- null values -->
|
||||
<KeyWords name="NullValues" color="#569CD6" bold="true" italic="false">
|
||||
<Key word="null"/>
|
||||
<Key word="NULL"/>
|
||||
<Key word="nil"/>
|
||||
<Key word="NIL"/>
|
||||
</KeyWords>
|
||||
|
||||
</RuleSet>
|
||||
</RuleSets>
|
||||
</SyntaxDefinition>
|
@@ -0,0 +1,75 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<SyntaxDefinition name="ENV" extensions=".env;.env.local;.env.development;.env.production;.env.test;.env.example">
|
||||
|
||||
<Environment>
|
||||
<Default color="#000000" bgcolor="#FFFFFF"/>
|
||||
</Environment>
|
||||
|
||||
<Properties>
|
||||
<Property name="LineComment" value="#"/>
|
||||
</Properties>
|
||||
|
||||
<Digits name="Digits" color="#098658"/>
|
||||
|
||||
<RuleSets>
|
||||
<RuleSet ignorecase="false">
|
||||
|
||||
<Delimiters>&|\/"',;=:-</Delimiters>
|
||||
|
||||
<!-- Comments starting with # -->
|
||||
<Span name="LineComment" stopateol="true" color="#008000" bold="false" italic="true">
|
||||
<Begin>#</Begin>
|
||||
</Span>
|
||||
|
||||
<!-- Double quoted strings with escape character support -->
|
||||
<Span name="DoubleQuotedString" stopateol="true" color="#A31515" bold="false" italic="false" escapecharacter="\">
|
||||
<Begin>"</Begin>
|
||||
<End>"</End>
|
||||
</Span>
|
||||
|
||||
<!-- Single quoted strings -->
|
||||
<Span name="SingleQuotedString" stopateol="true" color="#A31515" bold="false" italic="false">
|
||||
<Begin>'</Begin>
|
||||
<End>'</End>
|
||||
</Span>
|
||||
|
||||
<!-- Variable expansion ${VAR} or $VAR -->
|
||||
<Span name="VariableExpansion" color="#795E26" bold="true" italic="false">
|
||||
<Begin>${</Begin>
|
||||
<End>}</End>
|
||||
</Span>
|
||||
|
||||
<!-- Environment variable names (before =) -->
|
||||
<MarkPrevious color="#0000FF" bold="true" italic="false">=</MarkPrevious>
|
||||
|
||||
<!-- Simple variable reference $VAR -->
|
||||
<MarkFollowing color="#795E26" bold="true" italic="false">$</MarkFollowing>
|
||||
|
||||
<!-- Boolean values -->
|
||||
<KeyWords name="BooleanValues" color="#0000FF" bold="true" italic="false">
|
||||
<Key word="true"/>
|
||||
<Key word="false"/>
|
||||
<Key word="TRUE"/>
|
||||
<Key word="FALSE"/>
|
||||
<Key word="yes"/>
|
||||
<Key word="no"/>
|
||||
<Key word="YES"/>
|
||||
<Key word="NO"/>
|
||||
<Key word="on"/>
|
||||
<Key word="off"/>
|
||||
<Key word="ON"/>
|
||||
<Key word="OFF"/>
|
||||
</KeyWords>
|
||||
|
||||
<!-- null values -->
|
||||
<KeyWords name="NullValues" color="#0000FF" bold="true" italic="false">
|
||||
<Key word="null"/>
|
||||
<Key word="NULL"/>
|
||||
<Key word="nil"/>
|
||||
<Key word="NIL"/>
|
||||
</KeyWords>
|
||||
|
||||
</RuleSet>
|
||||
</RuleSets>
|
||||
</SyntaxDefinition>
|
Reference in New Issue
Block a user