SystemVerilog language server
SystemVerilog language server
Download from release page, and extract to the directory in PATH.
You can install from snapcraft
sudo snap install svlsYou can install by cargo.
cargo install svlssvls uses .svls.toml at the root of repository.
The example of .svls.toml is below:
[verilog]
include_paths = ["src/header"]
defines = ["DEBUG", "VAR=1"]
plugins = ["path/to/libfoo.so", "path/to/libbar.so"]
[option]
linter = true[verilog] sectioninclude_paths is include paths from the root of repository.
defines is define strings.
plugins is paths to svlint plugins from the working directory.
[option] sectionlinter shows whether linter feature is enabled.
Linter uses .svlint.toml at the root of repository.
If .svlint.toml can't be used, all lint rules are enabled.
Please see svlint#configuration for the detailed information.
Please install svls-vscode extension from marketplace.
let g:LanguageClient_serverCommands = {
\ 'systemverilog': ['svls'],
\ }if executable('svls')
au User lsp_setup call lsp#register_server({
\ 'name': 'svls',
\ 'cmd': {server_info->['svls']},
\ 'whitelist': ['systemverilog'],
\ })
endifIn configuration file
"languageserver": {
"svls": {
"command": "svls",
"filetypes": ["systemverilog"]
}
}In configuration file
{
"neovim/nvim-lspconfig",
opts = {
servers = {
svls = {
root_dir = function(fname)
return require("lspconfig.util").find_git_ancestor(fname)
end,
cmd = { "svls" },
filetypes = { "verilog", "systemverilog" },
},
},
},
}…(require 'verilog-ext)
(verilog-ext-mode-setup)
(verilog-ext-eglot-set-server 've-svls) ;`eglot' config
(verilog-ext-lsp-set-server 've-svls) ; `lsp' configIn languages.toml:
[language-server.svls]
command = "svls"
[[language]]
name = "verilog"
language-servers = ["svls"]No open issues yet, or sync has not completed.