r/SpringBoot • u/Lost-Instruction-545 • Feb 18 '26
Question Lombok doesn't work in Eclipse IDE on Ubuntu Linux
I have been trying to solve this issue for an hour and haven't found right solution yet. I got the STS plugin, pom.xml generated from Spring Initialzr, tried to install manually into IDE but lombok.jar file couldn't find Eclipse. I also desperately asked to Gemini (Pro) but it is so stpd every time I say "not working" just loops back to beginning. Any solution for it? Or should I go for IntelliJ and leave behind all those premium features Eclipse offering? Because I don't really want to write getter, setter etc. everywhere.
EDIT: After struggling about a day finally found the "real" solution. For Eclipse to recognize lombok.jar file it needs to be in it's class path. Adding .jar file to class path in Eclipse build path settings doesn't do anything. Skip this, directly to the solution: Find eclipse.ini file in your disk. By default it is located in "/snap/eclipse/131/usr/lib/eclipse/". You can't edit it because it is signed as system file. Copy that file to your "/home/trencmivront/snap/eclipse/131/". Now you can edit it. Have your lombok.jar file downloaded from ( https://projectlombok.org/download ). Add following command to end of file : -javaagent: [path_to_lombok.jar]. Make sure you placed the .jar file into somewhere you won't move again. That's it, now Eclipse will recognize Lombok as it should.
3
u/Rulmeq Feb 18 '26
What happens when you manually navigate to the install location of eclipse in the lombok installer?
1
u/Linvael Feb 18 '26
What does "doesn't work" mean exactly? If it's a maven project (and it is if you're using pom.xml) maven should be responsible for downloading and adding lombok to classpath, as well as using it via lombok runner. The only job Eclipse should have here is handling the maven project correctly, which I believe it can do without much issues.
0
u/TurkmenTT Feb 18 '26
Average eclipse experience.