diff options
| author | Dmitry Kudryavtsev <ko.dmitri@gmail.com> | 2022-06-01 17:23:59 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-06-01 07:23:59 -0700 |
| commit | 05023bface60b3b846668e209905c5ee11ab0a55 (patch) | |
| tree | a37e0e69545a51bd5a23ca867c80e2bbe4e1d458 /lua | |
| parent | docs: update server_configurations.md (diff) | |
| download | nvim-lspconfig-05023bface60b3b846668e209905c5ee11ab0a55.tar nvim-lspconfig-05023bface60b3b846668e209905c5ee11ab0a55.tar.gz nvim-lspconfig-05023bface60b3b846668e209905c5ee11ab0a55.tar.bz2 nvim-lspconfig-05023bface60b3b846668e209905c5ee11ab0a55.tar.lz nvim-lspconfig-05023bface60b3b846668e209905c5ee11ab0a55.tar.xz nvim-lspconfig-05023bface60b3b846668e209905c5ee11ab0a55.tar.zst nvim-lspconfig-05023bface60b3b846668e209905c5ee11ab0a55.zip | |
feat: added wgsl_analyzer support (#1925)
Diffstat (limited to 'lua')
| -rw-r--r-- | lua/lspconfig/server_configurations/wgsl_analyzer.lua | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/lua/lspconfig/server_configurations/wgsl_analyzer.lua b/lua/lspconfig/server_configurations/wgsl_analyzer.lua new file mode 100644 index 00000000..d5c73135 --- /dev/null +++ b/lua/lspconfig/server_configurations/wgsl_analyzer.lua @@ -0,0 +1,30 @@ +local util = require 'lspconfig.util' + +local bin_name = 'wgsl_analyzer' +local cmd = { bin_name } + +if vim.fn.has 'win32' == 1 then + cmd = { 'cmd.exe', '/C', bin_name } +end + +return { + default_config = { + cmd = cmd, + filetypes = { 'wgsl' }, + root_dir = util.root_pattern('.git'), + settings = {} + }, + docs = { + description = [[ +https://github.com/wgsl-analyzer/wgsl-analyzer + +`wgsl_analyzer` can be installed via `cargo`: +```sh +cargo install --git https://github.com/wgsl-analyzer/wgsl-analyzer wgsl_analyzer +``` +]], + default_config = { + root_dir = [[root_pattern(".git"]], + } + } +} |
