• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Eclipse export Runnable Jar with separate property folder

 
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am under corporate constraints. There is no standard build mechanism here, no continuous integration, etc. But what we do have is a very restrictive set of rules governing the deployment of programs into production.

We are currently just using eclipse to do the builds for us - it is simple, it works, it is consistent, and doesn't require a bunch of extra effort. When we use eclipse to export to a runnable JAR, we have an option for dependent libraries to go into a separate folder. Is there some way (other than messing with Ant scripts) to get eclipse to put dependent property files into a separate folder?

If property files are included in the JAR, then you must touch the jar to modify a property. Where I work it can take an hour to get permission to modify a production property file, but several days if you want to touch a jar file that is in production (even if you are just touching it to modify a property file). So, it is to our advantage to keep our property files separate from the JAR file. It would be more consistent if there was a standard automated approach for us to use.

It seems like this should be a fairly common requirement ... I'm hoping that maybe someone did an extension of the default export wizard that meets our needs. If not, is there someone on here with experience creating plugins and/or extending existing wizards that could throw me a bone?
 
Rancher
Posts: 2759
32
Eclipse IDE Spring Tomcat Server
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Note that Eclipse supports both Ant and Maven, and you can setup your eclipse project to use ant and maven underneath the hood. You can check in the ant/maven project file into your source repository. If your team agrees to it, you should be able to "upgrade" to ant/maven without installing anything new.

However, if you just want to use eclipse, then the way I would do is have a seperate folder for your property files in your source folder. Then, you can setup eclipse to ignore that folder when it bundles the jar, and add the folder to runtime classpath. You shouldn't need a plugin or a expert wizard or anything. Eclipse should work out of the box for you.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic