https://github.com/erg-lang/vscode-erg
A VSCode plugin for the Erg programming language
https://github.com/erg-lang/vscode-erg
erg extension vscode
Last synced: about 1 year ago
JSON representation
A VSCode plugin for the Erg programming language
- Host: GitHub
- URL: https://github.com/erg-lang/vscode-erg
- Owner: erg-lang
- License: mit
- Created: 2022-08-20T08:29:56.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2024-05-12T04:49:35.000Z (about 2 years ago)
- Last Synced: 2024-05-12T05:29:20.198Z (about 2 years ago)
- Topics: erg, extension, vscode
- Language: TypeScript
- Homepage: https://marketplace.visualstudio.com/items?itemName=erg-lang.vscode-erg
- Size: 949 KB
- Stars: 8
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Erg language support for Visual Studio Code
This extension provides syntax highlighting and basic supports (diagnostics & code completion) for the [Erg](https://github.com/erg-lang/erg) programming language.
## Requirements
~~You need to have the [Erg language server](https://github.com/erg-lang/erg/tree/main/compiler/els#readme) installed on your system.~~
~~To install it, you need to install or build Erg with `--features els`.~~
The extension installs the Erg toolchain automatically. If you see a message "Erg is not installed.", press the "Install" button.
After installing, you should set `PATH` to the directory stores the `erg` executable and `ERG_PATH` to the `.erg` directory.
Usually, the `.erg` directory is located in `~` and the `erg` executable is located in `~/.erg/bin`.
Building from source code is recommended if you want to have the latest complete ELS experience.
## Configuration
### General
* `vscode-erg.ergpath.path`: Path to the `.erg` directory. Default is `~/.erg`.
* `vscode-erg.executablePath`: Path to the `erg` executable. Default is `erg`.
* `vscode-erg.checkForUpdates`: Check for updates on startup. Default is `true`.
### Language Server
* `vscode-erg.lsp.inlayHints`: Enable inlay hints. Default is `true`.
* `vscode-erg.lsp.semanticTokens`: Enable semantic tokens. Default is `true`.
* `vscode-erg.lsp.hover`: Enable hover. Default is `true`.
* `vscode-erg.lsp.smartCompletion`: Enable smart completion (see [ELS features](https://github.com/erg-lang/erg/blob/main/crates/els/doc/features.md)). Default is `true`.
* `vscode-erg.lsp.lint`: Enable linting. Default is `true`.
## How to build (for contributors)
```sh
npm install -g vsce
npm install
npx vsce package
```