Closed soychpapalus closed 7 months ago
Fixed it by following the following guide (with edits): https://lsp.readthedocs.io/en/stable/#java
Comments:
jdt-ls
to /.local/share/eclipse-jdt-server/
LSP-jdtls.sublime-settings
(with edits)"PATH/TO/jdt-language-server-latest/plugins/org.eclipse.equinox.launcher_*.jar"
was edited to ~/.local/share/eclipse-jdt-server/plugins/org.eclipse.equinox.launcher_1.6.800.v20240330-1250.jar
(the version you use might change... For me it did not work with the wildcard in the filename"-noverify"
was removed"<TEMP_DIR>/${project_base_name}/jdt_ws"
replaced with "/tmp/${project_base_name}/jdt_ws"
"command": [
"java",
"--add-modules=ALL-SYSTEM",
"--add-opens",
"java.base/java.util=ALL-UNNAMED",
"--add-opens",
"java.base/java.lang=ALL-UNNAMED",
"-Declipse.application=org.eclipse.jdt.ls.core.id1",
"-Dosgi.bundles.defaultStartLevel=4",
"-Declipse.product=org.eclipse.jdt.ls.core.product",
"-Dfile.encoding=UTF-8",
"-DwatchParentProcess=true", // false on windows, true other OSs
"-Xmx1G",
"-XX:+UseG1GC",
"-XX:+UseStringDeduplication",
"-jar",
"~/.local/share/eclipse-jdt-server/plugins/org.eclipse.equinox.launcher_1.6.800.v20240330-1250.jar",
"-configuration",
"~/.local/share/eclipse-jdt-server/config_linux", // depending on the OS
"-data",
"/tmp/${project_base_name}/jdt_ws"
],
"enabled": true,
"languageId": "java",
"scopes": ["source.java"],
"syntaxes": ["Packages/Java/Java.sublime-syntax"]
}
This plugin is broken The only way I got java working is by following the above instructions
I need more info to fix this for everyone. LSP-jdtls version, LSP version, ST version, Windows/Mac/Linux? Also run the troubleshoot server command from the ST command panel.
I need more info to fix this for everyone. LSP-jdtls version, LSP version, ST version, Windows/Mac/Linux? Also run the troubleshoot server command from the ST command panel.
Just now I tried to reproduce the issue but everything is working. I think 2627751 fixed it