updated development installation instructions

This commit is contained in:
2026-08-17 18:22:30 +02:00
parent f783617393
commit 1c12fd1df6
+59 -9
View File
@@ -12,20 +12,24 @@ Syntax highlighting and language support for **EFTL (ElixForms Template Language
## Supported Syntax ## Supported Syntax
### Block Delimiters ### Block Delimiters
- `[EFTL]...[/EFTL]` - Main EFTL block - `[EFTL]...[/EFTL]` - Main EFTL block
- `[VAR name="..." type="..."]...[/VAR]` - Variable declarations - `[VAR name="..." type="..."]...[/VAR]` - Variable declarations
- `[IF]...[/IF]` - Conditionals - `[IF]...[/IF]` - Conditionals
- `[WHILE]...[/WHILE]` - Loops - `[WHILE]...[/WHILE]` - Loops
### Expressions ### Expressions
- `[% expression %]` - Execute expression - `[% expression %]` - Execute expression
- `[%= expression %]` - Output expression value - `[%= expression %]` - Output expression value
### Data Tags ### Data Tags
- `[TAG]GETVALUEBYTAG,TAG_NAME,REQUEST,IUQOID[/TAG]` - `[TAG]GETVALUEBYTAG,TAG_NAME,REQUEST,IUQOID[/TAG]`
- `[TAG]SCHEMAID,schemaId,COL0001,IUQOID, , [/TAG]` - `[TAG]SCHEMAID,schemaId,COL0001,IUQOID, , [/TAG]`
### Functions ### Functions
- `[SPLIT regex="..."]...[/SPLIT]` - Split string - `[SPLIT regex="..."]...[/SPLIT]` - Split string
- `[TRIM]...[/TRIM]` - Trim whitespace - `[TRIM]...[/TRIM]` - Trim whitespace
- `[VALUE_OF varname="..." index="..." /]` - Get array element - `[VALUE_OF varname="..." index="..." /]` - Get array element
@@ -34,29 +38,75 @@ Syntax highlighting and language support for **EFTL (ElixForms Template Language
- `[FORMAT type="..." pattern="..."]...[/FORMAT]` - Format values - `[FORMAT type="..." pattern="..."]...[/FORMAT]` - Format values
### Control Structures ### Control Structures
- `[IF]`, `[CONDITION]`, `[THEN]`, `[ELSE]`, `[ELSE IF]` - `[IF]`, `[CONDITION]`, `[THEN]`, `[ELSE]`, `[ELSE IF]`
- `[WHILE]`, `[DO]` - `[WHILE]`, `[DO]`
### Comments ### Comments
- `[!-- comment --]` - `[!-- comment --]`
## Installation ## Building and Installation
### From VSIX (Local) ### 1. Build from Source
1. Package the extension: `npx vsce package` To compile the extension, you need [Node.js](https://nodejs.org/) installed.
2. Install in VS Code: `code --install-extension eftl-language-0.1.0.vsix`
### Development Mode 1. Open a terminal in the project root.
2. Install dependencies:
1. Open this folder in VS Code ```bash
2. Press `F5` to launch Extension Development Host npm install
3. Open any `.eftl` file to see syntax highlighting ```
3. Compile the TypeScript code:
```bash
npm run compile
```
*Alternatively, use `npm run watch` to automatically recompile on changes.*
### 2. Manual Installation (for testing)
To make the extension available in your VS Code without packaging it as a VSIX:
#### Windows
1. Open a command prompt (as Administrator for symlinks) or PowerShell.
2. Create a link to this folder in your VS Code extensions directory:
```powershell
# PowerShell
New-Item -ItemType Junction -Path "$env:USERPROFILE\.vscode\extensions\eftl-language" -Value "D:\__Git\vscode-eftl-language"
```
*Note: Replace the value path with the actual absolute path to your project folder if it differs.*
#### Linux / macOS
1. Create a symbolic link:
```bash
ln -s "$(pwd)" ~/.vscode/extensions/eftl-language
```
2. **Restart VS Code**. The extension will now be loaded.
### 3. Development Mode (Debugging)
If you want to debug the extension or the language server:
1. Open the project folder in VS Code.
2. Ensure you have run `npm install` and `npm run compile`.
3. Press `F5` (or go to the **Run and Debug** view and click **Launch Extension**).
4. A new **Extension Development Host** window will open.
5. In that window, open any `.eftl` file to test syntax highlighting and the language server.
## Snippets ## Snippets
| Prefix | Description | | Prefix | Description |
|--------|-------------| | ----------- | ---------------------- |
| `eftl` | EFTL block with header | | `eftl` | EFTL block with header |
| `var` | Variable declaration | | `var` | Variable declaration |
| `vartag` | Variable from TAG | | `vartag` | Variable from TAG |