# Gotlin for VS Code VS Code language support for Gotlin (`.gt`) files. ## Features - TextMate highlighting for current Gotlin declarations, control flow, concurrency, exceptions, types, annotations, pointers, nullable types, generics, and numeric literals - Dedicated highlighting for the typed `sql` DSL and its query, mutation, and execution methods - Go import highlighting for bare dotted paths, aliases, and quoted module paths - Bracket matching, indentation, folding markers, comments, and editor pairs - Snippets for data classes, SQL table rows and operations, structured coroutines, embeds, defer, and foreach loops - `gotlin-lsp` integration, including its optional `gopls` bridge for Go-imported symbols ## Development From this directory: ```bash npm install npm run check ``` `npm run build` compiles the extension and `npm test` validates all JSON contribution files plus key current grammar tokens and snippets without additional test dependencies. To run the extension, open this directory in VS Code and press `F5`. In the Extension Development Host, open a Gotlin workspace containing `.gt` files. ## Language Server The extension first looks for the platform-specific server binary at `/bin/gotlin-lsp`, then falls back to `gotlin-lsp` on `PATH`. Override it with: ```json "gotlin.serverPath": "/absolute/path/to/gotlin-lsp" ``` If `gopls` is not on `PATH`, configure: ```json "gotlin.goplsPath": "/absolute/path/to/gopls" ``` Build the language server from the repository root with: ```bash go build -o ./bin/gotlin-lsp ./cmd/gotlin-lsp ``` The extension activates when a Gotlin document is opened and communicates with the server over stdio.