https://github.com/nikeee/dot-language-server
A language server for the DOT language.
https://github.com/nikeee/dot-language-server
dot-language graphviz hacktoberfest language-server language-server-protocol lsp
Last synced: about 2 months ago
JSON representation
A language server for the DOT language.
- Host: GitHub
- URL: https://github.com/nikeee/dot-language-server
- Owner: nikeee
- License: mit
- Created: 2018-05-29T13:01:03.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2025-03-08T14:19:40.000Z (2 months ago)
- Last Synced: 2025-03-22T20:31:40.371Z (about 2 months ago)
- Topics: dot-language, graphviz, hacktoberfest, language-server, language-server-protocol, lsp
- Language: TypeScript
- Homepage:
- Size: 860 KB
- Stars: 42
- Watchers: 3
- Forks: 4
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Citation: CITATION.cff
Awesome Lists containing this project
README
# dot-language-server [](https://github.com/nikeee/dot-language-server/actions/workflows/CD.yml)  
A language Server for the DOT language/Graphviz.
## Prerequisites
- Node.js `>=18`
- `npm`## Installation
```Shell
npm i -g dot-language-server
```If you want to request or implement new features, head over to [dot-language-support](https://github.com/nikeee/dot-language-support).
## Features
#### Refactorings
## Usage
### Vim
#### coc.nvim
```json
{
"languageserver": {
"dot": {
"command": "dot-language-server",
"args": ["--stdio"],
"filetypes": ["dot"]
}
}
}
```### vim-lsp
```vim
if executable('dot-language-server')
augroup lsp
autocmd!
autocmd User lsp_setup call lsp#register_server({
\ 'name': 'dot',
\ 'cmd': {server_info->['dot-language-server', '--stdio']},
\ 'whitelist': ['dot'],
\ })
augroup END
endif
```### [Neovim](https://neovim.io)
```lua
vim.api.nvim_create_autocmd({ "BufEnter" }, {
pattern = { "*.dot" },
callback = function()
vim.lsp.start({
name = "dot",
cmd = { "dot-language-server", "--stdio" }
})
end,
})
```### Visual Studio Code
TODO: There's an Extension for that.
### Sublime Text
1. Install [LSP support](https://github.com/tomv564/LSP) via `Install Package` -> [`LSP`](https://packagecontrol.io/packages/LSP)
2. Go to `Preferences: LSP Settings`
3. Add this to clients:```JSON
{
"clients": {
"dot-language-server": {
"command": ["dot-language-server", "--stdio"],
"enabled": true,
"languageId": "dot",
"scopes": ["source.dot"],
"syntaxes": ["Packages/Graphviz/DOT.sublime-syntax"]
}
}
}
```
**Note for Windows Users**: You have to append `.cmd` to the first entry in the `command` array (or, if possible, enable shell execution).### Emacs
For Emacs users, you need to use `lsp-mode` which supports the DOT Language Server out of the box....and you're done!