Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lombok support does not work #472

Open
tidux opened this issue Apr 14, 2024 · 2 comments
Open

Lombok support does not work #472

tidux opened this issue Apr 14, 2024 · 2 comments

Comments

@tidux
Copy link

tidux commented Apr 14, 2024

Describe the bug
Lombok support is manually set to "t" in customize but jdtls does not start with the Lombok support args.

To Reproduce
open a project that uses Lombok with lsp-java
ps aux | grep -i lombok | grep -v grep returns 0 results

Expected behavior
Lombok support is loaded and recognizes annotations.

@nithin-mk
Copy link

Lombok is not working for me either.

@rbarbey
Copy link

rbarbey commented Sep 30, 2024

What's working for me was to add Lombok as a javaagent to the JVM args like this

(use-package lsp-java
  :hook (java-mode . lsp-deferred)
  :init
  (setq lsp-java-vmargs (list
                         "-Xmx1G"
                         "-XX:+UseG1GC"
                         "-XX:+UseStringDeduplication"
                         "-javaagent:/path/to/home/.m2/repository/org/projectlombok/lombok/1.18.22/lombok-1.18.22.jar")))

Be sure to adapt the path to where your local Maven repo is and the version you have.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants