diff options
| author | github-actions[bot] <github-actions[bot]@users.noreply.github.com> | 2024-10-26 00:16:03 +0000 |
|---|---|---|
| committer | github-actions[bot] <github-actions[bot]@users.noreply.github.com> | 2024-10-26 00:16:03 +0000 |
| commit | 28b205ebe73a18f401e040585106f9bafd8ff21f (patch) | |
| tree | 74173edefdc5b302b76021cd06856c306906fb43 /doc | |
| parent | feat: ts_query_ls (for tree-sitter query files) #3404 (diff) | |
| download | nvim-lspconfig-28b205ebe73a18f401e040585106f9bafd8ff21f.tar nvim-lspconfig-28b205ebe73a18f401e040585106f9bafd8ff21f.tar.gz nvim-lspconfig-28b205ebe73a18f401e040585106f9bafd8ff21f.tar.bz2 nvim-lspconfig-28b205ebe73a18f401e040585106f9bafd8ff21f.tar.lz nvim-lspconfig-28b205ebe73a18f401e040585106f9bafd8ff21f.tar.xz nvim-lspconfig-28b205ebe73a18f401e040585106f9bafd8ff21f.tar.zst nvim-lspconfig-28b205ebe73a18f401e040585106f9bafd8ff21f.zip | |
docs: update configs.md
skip-checks: true
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/configs.md | 56 | ||||
| -rw-r--r-- | doc/configs.txt | 56 |
2 files changed, 112 insertions, 0 deletions
diff --git a/doc/configs.md b/doc/configs.md index e31a5911..594cff9e 100644 --- a/doc/configs.md +++ b/doc/configs.md @@ -306,6 +306,7 @@ Nvim by running `:help lspconfig-all`. - [tilt_ls](#tilt_ls) - [tinymist](#tinymist) - [ts_ls](#ts_ls) +- [ts_query_ls](#ts_query_ls) - [tsp_server](#tsp_server) - [ttags](#ttags) - [turtle_ls](#turtle_ls) @@ -10560,6 +10561,61 @@ Default config: - `single_file_support` : `true` +## ts_query_ls + +https://github.com/ribru17/ts_query_ls +Can be configured by passing a "settings" object to `ts_query_ls.setup{}`: +```lua +require('lspconfig').ts_query_ls.setup{ + settings = { + parser_install_directories = { + -- If using nvim-treesitter with lazy.nvim + vim.fs.joinpath( + vim.fn.stdpath('data'), + '/lazy/nvim-treesitter/parser/' + ), + }, + -- This setting is provided by default + parser_aliases = { + ecma = 'javascript', + jsx = 'javascript', + php_only = 'php', + }, + -- E.g. zed support + language_retrieval_patterns = { + 'languages/src/([^/]+)/[^/]+\\.scm$', + }, + }, +} +``` + +Snippet to enable the language server: +```lua +require'lspconfig'.ts_query_ls.setup{} +``` + +Default config: +- `cmd` : + ```lua + { "ts_query_ls" } + ``` +- `filetypes` : + ```lua + { "query" } + ``` +- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ts_query_ls.lua:4](../lua/lspconfig/configs/ts_query_ls.lua#L4) +- `settings` : + ```lua + { + parser_aliases = { + ecma = "javascript", + jsx = "javascript", + php_only = "php" + } + } + ``` + + ## tsp_server https://github.com/microsoft/typespec diff --git a/doc/configs.txt b/doc/configs.txt index e31a5911..594cff9e 100644 --- a/doc/configs.txt +++ b/doc/configs.txt @@ -306,6 +306,7 @@ Nvim by running `:help lspconfig-all`. - [tilt_ls](#tilt_ls) - [tinymist](#tinymist) - [ts_ls](#ts_ls) +- [ts_query_ls](#ts_query_ls) - [tsp_server](#tsp_server) - [ttags](#ttags) - [turtle_ls](#turtle_ls) @@ -10560,6 +10561,61 @@ Default config: - `single_file_support` : `true` +## ts_query_ls + +https://github.com/ribru17/ts_query_ls +Can be configured by passing a "settings" object to `ts_query_ls.setup{}`: +```lua +require('lspconfig').ts_query_ls.setup{ + settings = { + parser_install_directories = { + -- If using nvim-treesitter with lazy.nvim + vim.fs.joinpath( + vim.fn.stdpath('data'), + '/lazy/nvim-treesitter/parser/' + ), + }, + -- This setting is provided by default + parser_aliases = { + ecma = 'javascript', + jsx = 'javascript', + php_only = 'php', + }, + -- E.g. zed support + language_retrieval_patterns = { + 'languages/src/([^/]+)/[^/]+\\.scm$', + }, + }, +} +``` + +Snippet to enable the language server: +```lua +require'lspconfig'.ts_query_ls.setup{} +``` + +Default config: +- `cmd` : + ```lua + { "ts_query_ls" } + ``` +- `filetypes` : + ```lua + { "query" } + ``` +- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ts_query_ls.lua:4](../lua/lspconfig/configs/ts_query_ls.lua#L4) +- `settings` : + ```lua + { + parser_aliases = { + ecma = "javascript", + jsx = "javascript", + php_only = "php" + } + } + ``` + + ## tsp_server https://github.com/microsoft/typespec |
