Re: config files dependencies
Thanks for answers ! So we all go on the correct way :) I keep all the conf files in each project's src/conf directory and we do not put them in our jars because that's not practical for production (the sysadmin doesn't know how to find the jar, unzip it, modify, rezip, etc.). So I wrote some goals in my maven.xml to copy the jars from all dependent projects. I copy them into src/conf.dep. I then take src/conf.dep and copy to src/conf.dev, and then copy src/conf to src/conf.dev. Sounds complicated but it's not too bad: src/conf - original, unfiltered resources src/conf.dep - filtered dependency resources src/conf.dev - filtered original & dependency resources (original can override dependency) The maven.xml code is very ugly, but it works and I haven't had time to optimize it: Copying dependency resources for project ${pom.artifactId} ${depItem} ${depItemItem} ${depProject} is available Yes, I know, it actually copies the resources for each project twice. But it's so fast I haven't bothered to fix this (tough deadlines here) Michael -Message d'origine- De : Göschl,Siegfried [mailto:[EMAIL PROTECTED] Envoyé : lundi 28 juin 2004 16:08 À : Maven Users List Objet : RE: config files dependencies Hi Alexander, I have the same problems with Torque.properties, log4j.properties and spy.properties. I keep a folder for each set of configuration files for each build mode. To determine the build mode I pass a 'maven.build.mode' for building all project but I'm not using the reactor (yet) Cheers, Siegfried Goeschl -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Montag, 28. Juni 2004 14:09 To: [EMAIL PROTECTED] Subject: config files dependencies Hi! I need some advice. I need to copy config file from one subproect to another. I know one way to solve this problem. I can spesify this cofig files as resourses in one subproject and spesify the second subproject as being dependent from the first one. But I have two problems: 1. This config files have to be unjared. (P6SpyDriver wants its config file - spy.properties - not to be in jar) 2. To test the second subprojct I need to use testing version of the config files from the first one. I'm going to copy config files and their testing versions from the first subproject to the second one: basedir="${basedir}/.." includes="firstProject/project.xml" goals="test:test-resources" postProcessing="true" /> <>Would it be the right desision? -- Maksimenko Alexander Softwarium, www.softwarium.net -- Maksimenko Alexander Softwarium, www.softwarium.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: config files dependencies
I keep all the conf files in each project's src/conf directory and we do not put them in our jars because that's not practical for production (the sysadmin doesn't know how to find the jar, unzip it, modify, rezip, etc.). So I wrote some goals in my maven.xml to copy the jars from all dependent projects. I copy them into src/conf.dep. I then take src/conf.dep and copy to src/conf.dev, and then copy src/conf to src/conf.dev. Sounds complicated but it's not too bad: src/conf - original, unfiltered resources src/conf.dep - filtered dependency resources src/conf.dev - filtered original & dependency resources (original can override dependency) The maven.xml code is very ugly, but it works and I haven't had time to optimize it: Copying dependency resources for project ${pom.artifactId} ${depItem} ${depItemItem} ${depProject} is available Yes, I know, it actually copies the resources for each project twice. But it's so fast I haven't bothered to fix this (tough deadlines here) Michael > -Message d'origine- > De : Göschl,Siegfried [mailto:[EMAIL PROTECTED] > Envoyé : lundi 28 juin 2004 16:08 > À : Maven Users List > Objet : RE: config files dependencies > > > Hi Alexander, > > I have the same problems with Torque.properties, log4j.properties > and spy.properties. I keep a folder for each set of configuration > files for each build mode. To determine the build mode I pass a > 'maven.build.mode' for building all project but I'm not using the > reactor (yet) > > Cheers, > > Siegfried Goeschl > > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: Montag, 28. Juni 2004 14:09 > To: [EMAIL PROTECTED] > Subject: config files dependencies > > > > Hi! > > I need some advice. I need to copy config file from one subproect > to another. I know one way to solve this problem. I can spesify > this cofig files as resourses in one subproject and spesify the > second subproject as being dependent from the first one. > > But I have two problems: > > 1. This config files have to be unjared. (P6SpyDriver wants its > config file - spy.properties - not to be in jar) > > 2. To test the second subprojct I need to use testing version of > the config files from the first one. > > I'm going to copy config files and their testing versions from > the first subproject to the second one: > > > > > basedir="${basedir}/.." > > includes="firstProject/project.xml" > > goals="test:test-resources" > > postProcessing="true" > > /> > > > > dir="${reactorProjects.get(0).context.getVariable('maven.test.dest')}"> > > > > > > > > > > > > <>Would it be the right desision? > > -- > > Maksimenko Alexander > > Softwarium, www.softwarium.net > > -- This E-mail is confidential. It may also be legally privileged. If you are not the addressee you may not copy, forward, disclose or use any part of it. If you have received this message in error, please delete it and all copies from your system and notify the sender immediately by return E-mail. Internet communications cannot be guaranteed to be timely, secure, error or virus-free. The sender does not accept liability for any errors or omissions. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: config files dependencies
Hi Alexander, I have the same problems with Torque.properties, log4j.properties and spy.properties. I keep a folder for each set of configuration files for each build mode. To determine the build mode I pass a 'maven.build.mode' for building all project but I'm not using the reactor (yet) Cheers, Siegfried Goeschl -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Montag, 28. Juni 2004 14:09 To: [EMAIL PROTECTED] Subject: config files dependencies Hi! I need some advice. I need to copy config file from one subproect to another. I know one way to solve this problem. I can spesify this cofig files as resourses in one subproject and spesify the second subproject as being dependent from the first one. But I have two problems: 1. This config files have to be unjared. (P6SpyDriver wants its config file - spy.properties - not to be in jar) 2. To test the second subprojct I need to use testing version of the config files from the first one. I'm going to copy config files and their testing versions from the first subproject to the second one: <>Would it be the right desision? -- Maksimenko Alexander Softwarium, www.softwarium.net
config files dependencies
Hi! I need some advice. I need to copy config file from one subproect to another. I know one way to solve this problem. I can spesify this cofig files as resourses in one subproject and spesify the second subproject as being dependent from the first one. But I have two problems: 1. This config files have to be unjared. (P6SpyDriver wants its config file - spy.properties - not to be in jar) 2. To test the second subprojct I need to use testing version of the config files from the first one. I'm going to copy config files and their testing versions from the first subproject to the second one: basedir="${basedir}/.." includes="firstProject/project.xml" goals="test:test-resources" postProcessing="true" /> <>Would it be the right desision? -- Maksimenko Alexander Softwarium, www.softwarium.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]