Lombok not working with STS
For whom the installer is throwing error while installation, this can be installed manually by following below steps.
- First close the STS.
- Copy
lombok-x.xx.xx.jar
from~/.m2
repository. (E.g.~\.m2\repository\org\projectlombok\lombok\1.16.14\lombok-1.16.14.jar
) - Rename the copied jar to lombok.jar and paste it in STS home directory right beside STS launcher exe (E.g.
D:\spring-tool-suite-3.9.0.RELEASE-e4.7.0-win32-x86_64\sts-bundle\sts-3.9.0.RELEASE\
) - Open STS.ini (Name of this file can be different based on the STS version) and write
-javaagent:lombok.jar
line in the end . - Restart STS
- Go to
help>About Spring Tool Suit
and check. You will see a message like "Lombok v1.16.14 "Candid Duck" is installed. https://projectlombok.org/
" - For any existing project error, RCL on the project, Go to
Maven>Update Project
.
For the STS on Mac OSX, choose the .ini file, not the .exe file.
This is the path on my Macbook.
/Applications/SpringToolSuite4.app/Contents/Eclipse/SpringToolSuite4.ini
It worked like a charm.
- I have update the same on the following link.
Lombok not generating getter and setter STS
I had this problem despite successfully installing lombok
and restarting STS, so:
- shutting down STS and
- starting it
worked (as opposed to restarting it). See this: http://codeomitted.com/setup-lombok-with-stseclipse-based-ide/