Replies: 4 comments 1 reply
-
I think the only issue you're having is that ecode is not finding your |
Beta Was this translation helpful? Give feedback.
-
So it somehow seems to not communicate with the batchfile in some way. I tried a newer version with the official jdtls batch and python script. It has the same result. Everything is at its place and in path. I could verify that jdtls itself starts also on the newer version. When trying different methods also sometimes after saving the lsp config ecode crashed and reset the config to basically zero. It does definitely find the batchfile to start jdtls as it shows that in languages health. jdtls themselves say, if no ports are defined in PATH, it will just serve through stdin/stdout and I did not configure those as I already assumed it goes through stdio. I am not entirely sure on what the actual cause is in the configuration. |
Beta Was this translation helpful? Give feedback.
-
Best course of action will be to add your own configuration for the LSP. As far as I can see the distribution currently provides a python file that executes the jar but using {
"config": {
"disable_semantic_highlighting_lang": [],
"hover_delay": "1s",
"semantic_highlighting": true,
"server_close_after_idle_time": "1m",
"silent": true,
"trim_logs": false
},
"keybindings": {
"lsp-format-range": "alt+shift+f",
"lsp-go-to-declaration": "",
"lsp-go-to-definition": "f2",
"lsp-go-to-implementation": "shift+f2",
"lsp-go-to-type-definition": "",
"lsp-memory-usage": "",
"lsp-plugin-restart": "",
"lsp-refresh-semantic-highlighting": "",
"lsp-rename-symbol-under-cursor": "mod+shift+r",
"lsp-switch-header-source": "f4",
"lsp-symbol-code-action": "alt+return",
"lsp-symbol-info": "f1",
"lsp-symbol-references": "mod+shift+u",
"lspz-go-to-type-definition": ""
},
"servers": [
{
"language": "java",
"name": "jdtls",
"url": "https://github.com/eclipse/eclipse.jdt.ls",
"command": "java",
"command_parameters": "-Declipse.application=org.eclipse.jdt.ls.core.id1 -Dosgi.bundles.defaultStartLevel=4 -Declipse.product=org.eclipse.jdt.ls.core.product -Dlog.level=ALL -Dlog.protocol=true -Xmx1G --add-modules=ALL-SYSTEM --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED -jar C:\\Expand\\crupkg\\.langtools\\jdtls\\plugins\\org.eclipse.equinox.launcher_1.6.400.v20210924-0641.jar -configuration ./config_win -data C:\\Expand\\crupkg\\.langtools\\jdtls\\dat_glob",
"file_patterns": ["%.java$"]
}
]
} On Linux and macOS is trivial to get jdtls running, but I can see that Windows case is pretty confusing. |
Beta Was this translation helpful? Give feedback.
-
Okay I fiddled around a bit and like you suggested I tried again by only using the config. For some odd reason it seems that no langserver does anything on me except some quite old versions and I cannot explain why. But that is actually a problem of jdtls itself not ecode. Thanks again. |
Beta Was this translation helpful? Give feedback.
-
[WIN]
Tryin to get jdtls to work but I cannot seem to. Configuring it seems a bit odd here.
I tried to set it directly through the config with java and I tried to use a batchfile I found.
Somewhat I cannot get it to be recognized. Finally I had it running through console by
batch but It won't be recognized in ecode.
So it seems to wait for input. Tryin to open ecode after configuring it gave me
I have the batch
jdtls.bat
configured as follows:I am just close before a larger project and I'd love to leverage jdt.ls but I cannot seem to understand how to
properly get it working here.
The package is the default package that eclipse give for download and the config in ecode is also the default
config with no further params but I tried tweaking a little yet couldn't get it to work.
Beta Was this translation helpful? Give feedback.
All reactions