aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--installer/install-svls.cmd10
-rwxr-xr-xinstaller/install-svls.sh23
-rw-r--r--settings.json6
-rw-r--r--settings/svls.vim13
4 files changed, 52 insertions, 0 deletions
diff --git a/installer/install-svls.cmd b/installer/install-svls.cmd
new file mode 100644
index 0000000..44c19b3
--- /dev/null
+++ b/installer/install-svls.cmd
@@ -0,0 +1,10 @@
+@echo off
+
+setlocal
+
+set version=v0.1.12
+curl -L -o svls-%version%-x86_64-win.zip "https://github.com/dalance/svls/releases/download/v0.1.12/svls-%version%-x86_64-win.zip"
+call "%~dp0\run_unzip.cmd" svls-%version%-x86_64-win.zip
+move target\x86_64-pc-windows-msvc\release\svls.exe .
+rd /Q /S target
+del svls-%version%-x86_64-win.zip
diff --git a/installer/install-svls.sh b/installer/install-svls.sh
new file mode 100755
index 0000000..a0f2675
--- /dev/null
+++ b/installer/install-svls.sh
@@ -0,0 +1,23 @@
+#!/usr/bin/env bash
+
+set -e
+
+os=$(uname -s | tr "[:upper:]" "[:lower:]")
+
+case $os in
+linux)
+ os="lnx"
+ ;;
+darwin)
+ os="mac"
+ ;;
+*)
+ printf "%s doesn't supported by bash installer" "$os"
+ exit 1
+ ;;
+esac
+
+version="v0.1.12"
+curl -L -o svls-$version-x86_64-$os.zip "https://github.com/dalance/svls/releases/download/v0.1.12/svls-$version-x86_64-$os.zip"
+unzip svls-$version-x86_64-$os.zip
+rm svls-$version-x86_64-$os.zip
diff --git a/settings.json b/settings.json
index b99e94a..0b417c7 100644
--- a/settings.json
+++ b/settings.json
@@ -435,6 +435,12 @@
}
}
],
+ "systemverilog": [
+ {
+ "command": "svls",
+ "requires": []
+ }
+ ],
"terraform": [
{
"command": "terraform-lsp",
diff --git a/settings/svls.vim b/settings/svls.vim
new file mode 100644
index 0000000..7677585
--- /dev/null
+++ b/settings/svls.vim
@@ -0,0 +1,13 @@
+augroup vimlsp_settings_svls
+ au!
+ LspRegisterServer {
+ \ 'name': 'svls',
+ \ 'cmd': {server_info->lsp_settings#get('svls', 'cmd', [lsp_settings#exec_path('svls'), '-d'])},
+ \ 'root_uri':{server_info->lsp_settings#get('svls', 'root_uri', lsp_settings#root_uri(extend(['package.json'], g:lsp_settings_root_markers)))},
+ \ 'initialization_options': lsp_settings#get('svls', 'initialization_options', v:null),
+ \ 'whitelist': lsp_settings#get('svls', 'whitelist', ['systemverilog']),
+ \ 'blacklist': lsp_settings#get('svls', 'blacklist', []),
+ \ 'config': lsp_settings#get('svls', 'config', {}),
+ \ 'workspace_config': lsp_settings#get('svls', 'workspace_config', {}),
+ \ }
+augroup END