You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Java support for lsp-mode using the [Eclipse JDT Language Server](https://projects.eclipse.org/projects/eclipse.jdt.ls).
6
5
@@ -21,30 +20,14 @@ LSP java mode supports the following JDT Features:
21
20
* Test runner - [dap-mode](https://github.com/yyoncho/dap-mode/)
22
21
23
22
## Installation
24
-
### Install [Eclipse JDT Language Server](https://projects.eclipse.org/projects/eclipse.jdt.ls)
25
-
Download either [latest](http://download.eclipse.org/jdtls/snapshots/jdt-language-server-latest.tar.gz) or [a specific version](http://download.eclipse.org/jdtls/snapshots/?d) of Eclipse JDT Language Server distribution to `~/.emacs.d/eclipse.jdt.ls/server/`
26
-
27
-
If you choose to have the server installed in a different directory, set `lsp-java-server-install-dir`.
28
-
29
-
On Linux/MacOS you could install/update [Eclipse JDT Language Server](https://projects.eclipse.org/projects/eclipse.jdt.ls) via running the following commands:
tar xf /tmp/jdt-latest.tar -C ~/.emacs.d/eclipse.jdt.ls/server/
36
-
```
37
23
### Spacemacs
38
24
[lsp-java](https://github.com/emacs-lsp/lsp-java) is included in spacemacs (for now only on the dev branch). If you are using the development version of
39
25
spacemacs you can simply add `(java :variables java-backend 'lsp)` to `dotspacemacs-configuration-layers`.
40
26
41
-
### Install LSP Java
27
+
### Install via melpa
42
28
The recommended way to install LSP Java is via `package.el` - the built-in package
43
-
manager in Emacs.
44
-
LSP Java is available on the two major `package.el` community
45
-
maintained repos -
46
-
[MELPA Stable](http://stable.melpa.org)
47
-
and [MELPA](http://melpa.org).
29
+
manager in Emacs. LSP Java is available on the two major `package.el` community
30
+
maintained repos - [MELPA Stable](http://stable.melpa.org) and [MELPA](http://melpa.org).
@@ -58,6 +41,10 @@ Then add the following lines to your `.emacs` and open a file from the any of th
58
41
"/path/to/project2"
59
42
...))
60
43
```
44
+
### [Eclipse JDT Language Server](https://projects.eclipse.org/projects/eclipse.jdt.ls)
45
+
46
+
[lsp-java](https://github.com/emacs-lsp/lsp-java) will automatically detect when the server is missing and it will download [Eclipse JDT Language Server](https://projects.eclipse.org/projects/eclipse.jdt.ls) before the first startup. The server installation will be in `lsp-java-server-install-dir`. It will detect whether [dap-mode](https://github.com/yyoncho/dap-mode/) is present and it will download the required server side plugins/components. If you want to update the server you can run `lsp-java-update-server`. To run specific version of [Eclipse JDT Language Server](https://projects.eclipse.org/projects/eclipse.jdt.ls) use `lsp-java-server-install-dir`.
47
+
61
48
#### Quick start
62
49
Minimal configuration with [company-lsp](https://github.com/tigersoldier/company-lsp) and [lsp-ui](https://github.com/emacs-lsp/lsp-ui). Make sure you have replaced the XXX placeholder with the list of the projects you want to import.
63
50
```elisp
@@ -110,7 +97,7 @@ Minimal configuration with [company-lsp](https://github.com/tigersoldier/company
0 commit comments