Problems setting up jdtls #567
-
Hello everyone, hope you're having an amazing week so far. I've used this plugin mixed with jdtls in the past, I've even created a YouTube video to help other people to set up this amazing plugin. I've only been since then, a Java developer on my free time and now, I wanted to start a new side project with spring and I had to set up everything again to develop this side project. The issue is that now, I've been not able to set it up. I've installed jdtls and created a lua file on ftplugin with the following: local config = {
cmd = { "~/.local/share/nvim/mason/bin/jdtls" },
root_dir = vim.fs.dirname(vim.fs.find({ ".gradlew", ".git", "mvnw" }, { upward = true })[1]),
}
require("jdtls").start_or_attach(config) The problem is that, I get the following error:
If I go to that location and execute the jdtls exec manually, it just executes with any problem at all. I've even tried to download a millstone as I made last time and execute from there and got the same issue. Any suggestion on what am I doing wrong? Thanks in advance... |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Change
|
Beta Was this translation helpful? Give feedback.
Change
cmd = { "~/.local/share/nvim/mason/bin/jdtls" },
tocmd = { vim.fn.expand("~/.local/share/nvim/mason/bin/jdtls") },
~
isn't automatically expanded to the home directory, so it can't find the executable