Minilux Language Support for VS Code
Syntax highlighting support for the Minilux scripting language.
Features
- Syntax Highlighting - Full syntax highlighting for
.mi files
- Bracket Matching - Automatic bracket, parenthesis, and quote pairing
- Comment Support - Line comments with
#
- Code Folding - Fold code blocks for better readability
Supported Syntax
Keywords
- Control flow:
if, elseif, else, while
- Functions:
func, return
- Module:
include
- Logical operators:
AND, OR, NOT
Built-in Functions
- I/O:
printf, shell
- Arrays:
len, push, pop, shift, unshift
- Variables:
inc, dec
- Sockets:
sockopen, sockclose, sockwrite, sockread
- Timing:
sleep
Syntax Elements
- Variables:
$variable_name
- Strings: Double
"..." and single '...' quoted
- Numbers: Integer literals
- Comments:
# comment
- Operators:
+, -, *, /, %, ==, !=, <, >, <=, >=
Installation
From VSIX
- Download the
.vsix file
- Open VS Code
- Go to Extensions view (
Ctrl+Shift+X)
- Click the
... menu at the top
- Select "Install from VSIX..."
- Choose the downloaded file
From Source
cd vscode-minilux
npm install -g @vscode/vsce
vsce package
code --install-extension minilux-0.1.0.vsix
Usage
Open any .mi file and syntax highlighting will be automatically applied.
Example
# Calculate factorial
$n = 5
$result = 1
while (($n > 0)) {
$result = $result * $n
dec($n, 1)
}
printf("Factorial: ", $result, "\n")
About Minilux
Minilux is a minimal scripting language written in Rust.
Release Notes
0.1.0
- Initial release
- Syntax highlighting for all Minilux language features
- Bracket matching and auto-closing pairs
- Comment support
| |