vscode-ebnf

EBNF for Visual Studio Code
Mirror of https://github.com/Jamozed/vscode-ebnf
git clone http://git.omkov.net/vscode-ebnf
Log | Tree | Refs | README | LICENCE | Download

AuthorJamozed <[email protected]>
Date2021-07-06 05:23:33
Commit26f75426033fad0e395de974844fc7303760c0d0
Parent57ce57745083873aa7f30066663651244725cc47

Add auto indent rules on enter

Diffstat

M language-configuration.json | 4 ++++

1 files changed, 4 insertions, 0 deletions

diff --git a/language-configuration.json b/language-configuration.json
index 517e902..b921a3a 100644
--- a/language-configuration.json
+++ b/language-configuration.json
@@ -21,5 +21,9 @@
 		[ "(", ")" ],
 		[ "'", "'" ],
 		[ "\"", "\"" ]
+	],
+	"onEnterRules": [
+		{ "beforeText": "\\w+\\s*=[^;]*$", "action": { "indent": "indent" } },
+		{ "beforeText": ";", "action": { "indent": "outdent" } }
 	]
 }