diff options
| author | terib0l <64969840+terib0l@users.noreply.github.com> | 2023-02-21 19:04:07 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-02-21 18:04:07 +0800 |
| commit | e2a01be4451365c4ede8cb73cfa3f0b539a219e8 (patch) | |
| tree | 766862dc93c712d23ab7507b6fa863f6bfb2574b /lua | |
| parent | docs: update server_configurations.md (diff) | |
| download | nvim-lspconfig-e2a01be4451365c4ede8cb73cfa3f0b539a219e8.tar nvim-lspconfig-e2a01be4451365c4ede8cb73cfa3f0b539a219e8.tar.gz nvim-lspconfig-e2a01be4451365c4ede8cb73cfa3f0b539a219e8.tar.bz2 nvim-lspconfig-e2a01be4451365c4ede8cb73cfa3f0b539a219e8.tar.lz nvim-lspconfig-e2a01be4451365c4ede8cb73cfa3f0b539a219e8.tar.xz nvim-lspconfig-e2a01be4451365c4ede8cb73cfa3f0b539a219e8.tar.zst nvim-lspconfig-e2a01be4451365c4ede8cb73cfa3f0b539a219e8.zip | |
feat: add yara-language-server support (#2473)
Diffstat (limited to 'lua')
| -rw-r--r-- | lua/lspconfig/server_configurations/yls.lua | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/lua/lspconfig/server_configurations/yls.lua b/lua/lspconfig/server_configurations/yls.lua new file mode 100644 index 00000000..0fe15fb2 --- /dev/null +++ b/lua/lspconfig/server_configurations/yls.lua @@ -0,0 +1,28 @@ +local util = require 'lspconfig.util' + +local bin_name = 'yls' +local cmd = { bin_name, '-vv' } + +if vim.fn.has 'win32' == 1 then + cmd = { 'cmd.exe', '/C', bin_name, '-vv' } +end + +return { + default_config = { + cmd = cmd, + filetypes = { 'yar', 'yara' }, + root_dir = util.find_git_ancestor, + single_file_support = true, + }, + docs = { + description = [[ +https://pypi.org/project/yls-yara/ + +An YLS plugin adding YARA linting capabilities. + +This plugin runs yara.compile on every save, parses the errors, and returns list of diagnostic messages. + +Language Server: https://github.com/avast/yls +]], + }, +} |
