Home > Blockchain >  Run Maven Project (with ant) in a single go using Remote Debug Configuration of IntelliJ
Run Maven Project (with ant) in a single go using Remote Debug Configuration of IntelliJ

Time:04-26

I have a Maven Project, Ant Project which are somehow coupled. If I have to make any change in maven project and test it I have to do following steps every time, which is very time consuming.

Steps

  • ant stopserver
  • mvn install
  • ant startserver
  • Access it on localhost:8080

And to debug anything I have to create a Remote Debug Configuration which connects to port 8000 and start ant server in debug mode.

All this is new to me as I have only worked on microservices based out of maven when there is a @SpringApplication class with main method which I could directly run/debug. In this project, there is no class with main method. It's a legacy spring mvc project.

I seriously want some way to do the same with current project. I tried going though the build.xml but I couldn't get past much of it.

Is there a way possible? Can it run like a normal maven project? Ant is probably building some db and ui parts (not very sure). But I only work on Java side.

Please help. Anything that could get rid of me having to run mvn install with every small change would also be helpful.

I have tried following post but it did not work for me enter image description here

  • Related