diff --git a/.gitignore b/.gitignore
index 8930eaf..56b2d86 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,4 +2,5 @@ syntaxes/
grammars/
node_modules/
atom/
-atom.zip
\ No newline at end of file
+atom.zip
+.vscode/
diff --git a/PowerShellSyntax.tmLanguage b/PowerShellSyntax.tmLanguage
index ed2ddf0..c0810e5 100644
--- a/PowerShellSyntax.tmLanguage
+++ b/PowerShellSyntax.tmLanguage
@@ -1023,7 +1023,7 @@
comment
These are the other built-in constants.
match
- (\$)(?i:(Error|ExecutionContext|Host|Home|PID|PsHome|PsVersionTable|ShellID))((?:\.(?:\p{L}|\d|_)+)*\b)?\b
+ (\$)(?i:(ExecutionContext|Host|Home|PID|PsHome|PsVersionTable|ShellID))((?:\.(?:\p{L}|\d|_)+)*\b)?\b
captures
@@ -1047,7 +1047,7 @@
comment
Automatic variables are not constants, but they are read-only. In monokai (default) color schema support.variable doesn't have color, so we use constant.
match
- (\$)((?:[$^?])|(?i:_|Args|ConsoleFileName|Event|EventArgs|EventSubscriber|ForEach|Input|LastExitCode|Matches|MyInvocation|NestedPromptLevel|Profile|PSBoundParameters|PsCmdlet|PsCulture|PSDebugContext|PSItem|PSCommandPath|PSScriptRoot|PsUICulture|Pwd|Sender|SourceArgs|SourceEventArgs|StackTrace|Switch|This)\b)((?:\.(?:\p{L}|\d|_)+)*\b)?
+ (\$)((?:[$^?])|(?i:_|Args|ConsoleFileName|Error|Event|EventArgs|EventSubscriber|ForEach|Input|LastExitCode|Matches|MyInvocation|NestedPromptLevel|Profile|PSBoundParameters|PsCmdlet|PsCulture|PSDebugContext|PSItem|PSCommandPath|PSScriptRoot|PsUICulture|Pwd|Sender|SourceArgs|SourceEventArgs|StackTrace|Switch|This)\b)((?:\.(?:\p{L}|\d|_)+)*\b)?
captures
diff --git a/package-lock.json b/package-lock.json
index e75d8ea..037921e 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,29 +1,48 @@
{
"name": "EditorSyntax",
"version": "1.0.0",
- "lockfileVersion": 1,
+ "lockfileVersion": 3,
"requires": true,
- "dependencies": {
- "atom-grammar-test": {
+ "packages": {
+ "": {
+ "name": "EditorSyntax",
+ "version": "1.0.0",
+ "license": "MIT",
+ "dependencies": {
+ "atom-grammar-test": "^0.6.3",
+ "fast-plist": "0.1.2"
+ },
+ "engines": {
+ "atom": "*",
+ "node": "*"
+ }
+ },
+ "node_modules/atom-grammar-test": {
"version": "0.6.4",
"resolved": "https://registry.npmjs.org/atom-grammar-test/-/atom-grammar-test-0.6.4.tgz",
"integrity": "sha1-2KU1A9H+k5mX9Ji3SirDEARKfU4=",
- "requires": {
- "chevrotain": "0.18.0",
- "escape-string-regexp": "1.0.5"
+ "dependencies": {
+ "chevrotain": "^0.18.0",
+ "escape-string-regexp": "^1.0.5"
+ },
+ "engines": {
+ "atom": ">=1.0.0 <2.0.0"
}
},
- "chevrotain": {
+ "node_modules/chevrotain": {
"version": "0.18.0",
"resolved": "https://registry.npmjs.org/chevrotain/-/chevrotain-0.18.0.tgz",
"integrity": "sha1-sodxTjFZC64sXR4vYRZz7+xHnYA="
},
- "escape-string-regexp": {
+ "node_modules/escape-string-regexp": {
"version": "1.0.5",
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
- "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
+ "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=",
+ "engines": {
+ "node": ">=0.8.0"
+ }
},
- "fast-plist": {
+ "node_modules/fast-plist": {
"version": "0.1.2",
"resolved": "https://registry.npmjs.org/fast-plist/-/fast-plist-0.1.2.tgz",
"integrity": "sha1-pFr/NFGWAG1AbKbNzQX2kFHvNbg="
diff --git a/spec/testfiles/syntax_test_TheBigTestFile.ps1 b/spec/testfiles/syntax_test_TheBigTestFile.ps1
index 7c06e18..6f3b7e1 100644
--- a/spec/testfiles/syntax_test_TheBigTestFile.ps1
+++ b/spec/testfiles/syntax_test_TheBigTestFile.ps1
@@ -113,14 +113,34 @@ $args
# ^ support.variable.automatic.powershell
$error
# <- punctuation.definition.variable.powershell
-# ^ support.constant.variable.powershell
-$home
-# <- punctuation.definition.variable.powershell
-# ^ support.constant.variable.powershell
+# ^ support.variable.automatic.powershell
$foreach
# <- punctuation.definition.variable.powershell
# ^ support.variable.automatic.powershell
+# Automatic constants
+$executioncontext
+# <- punctuation.definition.variable.powershell
+# ^ variable.other.constant.powershell
+$host
+# <- punctuation.definition.variable.powershell
+# ^ variable.other.constant.powershell
+$home
+# <- punctuation.definition.variable.powershell
+# ^ variable.other.constant.powershell
+$pid
+# <- punctuation.definition.variable.powershell
+# ^ variable.other.constant.powershell
+$pshome
+# <- punctuation.definition.variable.powershell
+# ^ variable.other.constant.powershell
+$psversiontable
+# <- punctuation.definition.variable.powershell
+# ^ variable.other.constant.powershell
+$shellid
+# <- punctuation.definition.variable.powershell
+# ^ variable.other.constant.powershell
+
# Normal variables
$variable
# <- punctuation.definition.variable.powershell