aboutsummaryrefslogtreecommitdiffstats
path: root/lsp/jdtls.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2025-04-18 17:44:38 +0200
committerJustin M. Keyes <justinkz@gmail.com>2025-04-18 17:44:38 +0200
commitf8b5cbe6312b568def1f91d747e2cdb8984fdf2e (patch)
treec1baf319b22d8ccc7d3468276b5ba9a26dfa2775 /lsp/jdtls.lua
parentfeat: angularls #3746 (diff)
downloadnvim-lspconfig-f8b5cbe6312b568def1f91d747e2cdb8984fdf2e.tar
nvim-lspconfig-f8b5cbe6312b568def1f91d747e2cdb8984fdf2e.tar.gz
nvim-lspconfig-f8b5cbe6312b568def1f91d747e2cdb8984fdf2e.tar.bz2
nvim-lspconfig-f8b5cbe6312b568def1f91d747e2cdb8984fdf2e.tar.lz
nvim-lspconfig-f8b5cbe6312b568def1f91d747e2cdb8984fdf2e.tar.xz
nvim-lspconfig-f8b5cbe6312b568def1f91d747e2cdb8984fdf2e.tar.zst
nvim-lspconfig-f8b5cbe6312b568def1f91d747e2cdb8984fdf2e.zip
docs: cleanup
- brief should live at the top of each file - fix indentation for some docs
Diffstat (limited to 'lsp/jdtls.lua')
-rw-r--r--lsp/jdtls.lua67
1 files changed, 34 insertions, 33 deletions
diff --git a/lsp/jdtls.lua b/lsp/jdtls.lua
index 1cc5946a..e9cce6a9 100644
--- a/lsp/jdtls.lua
+++ b/lsp/jdtls.lua
@@ -1,3 +1,37 @@
+---@brief
+---
+--- https://projects.eclipse.org/projects/eclipse.jdt.ls
+---
+--- Language server for Java.
+---
+--- IMPORTANT: If you want all the features jdtls has to offer, [nvim-jdtls](https://github.com/mfussenegger/nvim-jdtls)
+--- is highly recommended. If all you need is diagnostics, completion, imports, gotos and formatting and some code actions
+--- you can keep reading here.
+---
+--- For manual installation you can download precompiled binaries from the
+--- [official downloads site](http://download.eclipse.org/jdtls/snapshots/?d)
+--- and ensure that the `PATH` variable contains the `bin` directory of the extracted archive.
+---
+--- ```lua
+--- -- init.lua
+--- vim.lsp.enable('jdtls')
+--- ```
+---
+--- You can also pass extra custom jvm arguments with the JDTLS_JVM_ARGS environment variable as a space separated list of arguments,
+--- that will be converted to multiple --jvm-arg=<param> args when passed to the jdtls script. This will allow for example tweaking
+--- the jvm arguments or integration with external tools like lombok:
+---
+--- ```sh
+--- export JDTLS_JVM_ARGS="-javaagent:$HOME/.local/share/java/lombok.jar"
+--- ```
+---
+--- For automatic installation you can use the following unofficial installers/launchers under your own risk:
+--- - [jdtls-launcher](https://github.com/eruizc-dev/jdtls-launcher) (Includes lombok support by default)
+--- ```lua
+--- -- init.lua
+--- vim.lsp.config('jdtls', { cmd = { 'jdtls' } })
+--- ```
+
local handlers = require 'vim.lsp.handlers'
local env = {
@@ -75,39 +109,6 @@ local function on_language_status(_, result)
command 'echohl None'
end
----@brief
----
--- https://projects.eclipse.org/projects/eclipse.jdt.ls
---
--- Language server for Java.
---
--- IMPORTANT: If you want all the features jdtls has to offer, [nvim-jdtls](https://github.com/mfussenegger/nvim-jdtls)
--- is highly recommended. If all you need is diagnostics, completion, imports, gotos and formatting and some code actions
--- you can keep reading here.
---
--- For manual installation you can download precompiled binaries from the
--- [official downloads site](http://download.eclipse.org/jdtls/snapshots/?d)
--- and ensure that the `PATH` variable contains the `bin` directory of the extracted archive.
---
--- ```lua
--- -- init.lua
--- vim.lsp.enable('jdtls')
--- ```
---
--- You can also pass extra custom jvm arguments with the JDTLS_JVM_ARGS environment variable as a space separated list of arguments,
--- that will be converted to multiple --jvm-arg=<param> args when passed to the jdtls script. This will allow for example tweaking
--- the jvm arguments or integration with external tools like lombok:
---
--- ```sh
--- export JDTLS_JVM_ARGS="-javaagent:$HOME/.local/share/java/lombok.jar"
--- ```
---
--- For automatic installation you can use the following unofficial installers/launchers under your own risk:
--- - [jdtls-launcher](https://github.com/eruizc-dev/jdtls-launcher) (Includes lombok support by default)
--- ```lua
--- -- init.lua
--- vim.lsp.config('jdtls', { cmd = { 'jdtls' } })
--- ```
return {
cmd = {
'jdtls',