Setup Lombok With STS/Eclipse Based IDE

Setup Lombok With STS/Eclipse Based IDE

This article show you how to setup lombok with your STS/eclipse based IDE.

1, First time work Lombok, you will wonder why it doesn’t generate getter and setter like what video shown.

 

Install Lombok

  1. Copy the lombok.jar to your STS installation path, Contents > MacOS > lombok.jar (I’ve remove the version).
  2. Run the command and update your STS path.
    java -jar [your_lombok.jar]
    
    
  3. From the window browse to your STS.ini files.

  4.  Update the STS.ini with -javaagent:lombok.jar

  5. Finally you NEED to close the STS/eclipse and start again. (Restart doesn’t take effect)
  6. Once you’ve done close and start STS. You’ll see the getter and setter is autogenerated.

4 comments

  1. Close and start again that’s why. Thanks.

    Reply
    1. Finally you NEED to close the STS/eclipse and start again. (Restart doesn’t take effect)
      This statement really helped. It unblocked my task . Thank you

      Reply
  2. It is very helpful. You can also refer this website for some useful information:
    http://ahex.co/lombok-jar-installation/

    Reply
  3. Besides the above steps, I went to sts-bundle\sts-3.9.7.RELEASE and did sts clean , that the properties got enabled.

    Reply

Write a Reply or Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.