Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Refresh an Eclipse project with Ant

Tags:

eclipse

jar

ant

We have some Ant script fosr building the different jars we use, in several Eclipse projects. There is some interdependency

At the end of the build, we have to refresh some of the Eclipse projects in order to make the build path valid. Without this, it doesn't see one of the just-built jars and Eclipse throws a build path error.

There is a way to avoid the manual refresh step?

like image 999
Antoine Claval Avatar asked Jun 12 '09 10:06

Antoine Claval


People also ask

How do I update ant project in Eclipse?

Go to Help -> About RAD -> Intallation details -> Plugins ... locate the org. apache. ant plugin version you are using. Note the Provider ... in this case for me it was Eclipse Orbit.

How do I do ant clean in Eclipse?

Right click on the build. xml > Run As > Ant Build... On Targets tab, check clean option.


1 Answers

Try this:

<eclipse.refreshLocal resource="project_name/folder_name" depth="infinite" /> 

There are option details at the Eclipse help system.

Important: you have to choose "Run in the same JRE as workspace" at the Ant run configuration.

like image 181
Roman P Avatar answered Sep 21 '22 12:09

Roman P