Build multiple project configurations with eclipse

空扰寡人 提交于 2019-12-10 17:53:20

问题


Is there a way to make Eclipse able to export multiple configurations of a single project?

My problem is the following:

I have several java web applications which I develop in Eclipse. Before I put new versions onto my production server I publish the new versions to a test server, where the apps run with a slightly different configuration (database server name, etc.).

Is there a way to something like 'export war for TEST env' and 'export war for PROD env'? Eclipse only would have to take another properties file...

I guess there is a way, I just can't figure it out.

Any ideas / hints ?


回答1:


There are actually plugins for this out there:

Maven4Eclipse




回答2:


You would get much better results by having an Ant or Maven build.

These are build systems, rather than IDEs, so all you have to do is run a shell command, with parameters, if needed.


Update: as for the question of integrating Ant or Maven with Eclipse, see my answer on Best way to share jars across multiple projects.



来源:https://stackoverflow.com/questions/1367077/build-multiple-project-configurations-with-eclipse

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!