Re: What is the 'Maven way' to handle multi-artifact code generation from a single model source?
I'd like to stress that Jesse explains the true Maven way. This is how this should be done if you want to enjoy simple and correct dependency management through Maven. Using classifiers will make your two (for instance) artifacts have the same dependencies. As I've stated before, classifiers are most often NOT the way to go IMO. /Anders On Wed, Dec 2, 2009 at 22:40, Jesse Farinacci wrote: > Hi KJ, > > On Wed, Dec 2, 2009 at 3:19 PM, K J wrote: > > Does anyone have any examples or tips about how to handle the > > generation of multiple artifacts based on a shared model? For example, > > I have a project which needs to produce both Java and ActionScript > > code based on a shared UML model. I'm having trouble figuring out how > > to best setup and manage these types of projects, so that a change to > > the source project can easily result in the build of all the various > > generated outputs. Thanks in advance for the help. > > To go the real Maven way, I think that I'd probably put the shared > model data (perhaps some sort of XML?) into a Maven module. Then I'd > have more Maven modules for Java and ActionScript, each, that would > depend on the model data module. They would use it as a dependency and > then generate their source codes accordingly. > > -jesse > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re: [Release] getting rewritten. how does it work?
you have to be clear about what I will call as "release roots" A release root is a project that has an section. It will typically be an aggregator project (i.e. packaging=pom && modules.size()>0) but it does not need to be. If it is a parent project (i.e. at least one of the modules it aggregates references it as a parent you do know that aggregation does not have to follow inheritance by the way) then the scm information is transformed when being inherited, so that the child module's artifactId is appended to the scm url. in general, you should run "mvn release:prepare release:perform" from a "release root", it will generate one tag of everything that is contained below the "release root". in this case, you should always ensure that your modules definitions do not jump back up (e.g. you don't have ../someother) as that would break the tagging for you. If you have to 'jump back up' then you probably need to set the configuration parameter "commitByProject=true" on the release plugin and you should explicitly set the scm information on the 'jump back up' modules. the scm information has to be solidified at deployment time, so what happens is that the ${project.artifactId} gets replaced with the actual artifactId in the scm information... there are a number of bugs in earlier versions of maven where this information was not getting solidified. Additionally there might be some magic about when the scm url ends with a / or not which might control whether or not the inheriting module gets it's artifactId appended to the inherited scm url -Stephen 2009/12/3 nodje : > > Hi, > > I'm using maven-release-plugin 2.0-beta9 and I'm still getting urls > rewritten at each deployment. > > http://jira.codehaus.org/browse/MRELEASE-231 is been closed quite a while > ago, so many we're not speaking about the same rewriting. > > The way we use the tag in our organization is trough a parent pom that > is suppose to set the for each every child project. > > It looks like this: > > scm:svn:${svn.root}/trunk/${artifactId} > > scm:svn:${svn.root}/trunk/${artifactId} > ${svn.root}/trunk/${artifactId} > > > What I'm not getting is that while it's the only tag in the whole > maven configuration, it gets rewritten at parent-pom deployment time WITH > parent-pom properties. > > Even though, when releasing a child project based on this parent release, > Release plugin seems to find it's way to our Subversion without any other > help. > > I really don't understand how this can possibly work. > Could somebody enlighten me on this? > > rgds > -jean > -- > View this message in context: > http://old.nabble.com/-Release--%3Cscm%3E-getting-rewritten.-how-does-it-work--tp26621596p26621596.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: [Release] getting rewritten. how does it work?
I'm guessing that when you do the release of the child module, a snapshot-version of the parent is actually being used as that's what your child pom specifies. The snapshot-version is in your local repo (or a remote repo) and still has all the properties in the scm url (it's just the released version in your corp repo that has the properties substituted). Thus, the effective-pom will have a scm url with the properties and when substituting those with the child's values, the scm url is created correctly (for the child project). If this is the case, I would say that it is a kind of bug in the release plugin as the resulting effective-pom (based on the release version parent pom and the release version child pom) is not what was used when doing the release. As you can tell from you're case there are some differences. In your example it's for instance not possible to retrieve the code base based on the scm url of the release child project (the scm url inherited from the release version parent pom). Regarding the proprties substitution in the parent pom people normally complain that the properties are NOT substituted. And now you're complaining they are...:-) /Anders On Thu, Dec 3, 2009 at 07:27, nodje wrote: > > Hi, > > I'm using maven-release-plugin 2.0-beta9 and I'm still getting urls > rewritten at each deployment. > > http://jira.codehaus.org/browse/MRELEASE-231 is been closed quite a while > ago, so many we're not speaking about the same rewriting. > > The way we use the tag in our organization is trough a parent pom > that > is suppose to set the for each every child project. > > It looks like this: > >scm:svn:${svn.root}/trunk/${artifactId} > > > scm:svn:${svn.root}/trunk/${artifactId} >${svn.root}/trunk/${artifactId} > > > What I'm not getting is that while it's the only tag in the whole > maven configuration, it gets rewritten at parent-pom deployment time WITH > parent-pom properties. > > Even though, when releasing a child project based on this parent release, > Release plugin seems to find it's way to our Subversion without any other > help. > > I really don't understand how this can possibly work. > Could somebody enlighten me on this? > > rgds > -jean > -- > View this message in context: > http://old.nabble.com/-Release--%3Cscm%3E-getting-rewritten.-how-does-it-work--tp26621596p26621596.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
[Release] getting rewritten. how does it work?
Hi, I'm using maven-release-plugin 2.0-beta9 and I'm still getting urls rewritten at each deployment. http://jira.codehaus.org/browse/MRELEASE-231 is been closed quite a while ago, so many we're not speaking about the same rewriting. The way we use the tag in our organization is trough a parent pom that is suppose to set the for each every child project. It looks like this: scm:svn:${svn.root}/trunk/${artifactId} scm:svn:${svn.root}/trunk/${artifactId} ${svn.root}/trunk/${artifactId} What I'm not getting is that while it's the only tag in the whole maven configuration, it gets rewritten at parent-pom deployment time WITH parent-pom properties. Even though, when releasing a child project based on this parent release, Release plugin seems to find it's way to our Subversion without any other help. I really don't understand how this can possibly work. Could somebody enlighten me on this? rgds -jean -- View this message in context: http://old.nabble.com/-Release--%3Cscm%3E-getting-rewritten.-how-does-it-work--tp26621596p26621596.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: the module in maven
Thats what Im talking about. Try to follow maven-way style and you would get minimal amount of problems. 2009/12/3 Dan Tran > the reason to make module name to have the same name as artifactId is > so that you dont have define your scm element in every child pom. All > Maven needs to the top pom.xml's scm to figure out out scm element of > the child module. this is crucial when cutting a release the maven > way using its infamous maven-release-plugin > > if you have lots of modules, this convention is very handy. > > > -Dan > > On Wed, Dec 2, 2009 at 9:33 PM, Alexander wrote: > > Yeah, thats right. > > > > There are some problems? > > > > 2009/12/3 maven apache > > > >> 2009/12/3 Alexander > >> > >> > Maven way is to name module directory as module artifact id. > >> > > >> I want to rename the module since the old project are not well named.So > I > >> should rename both the module directory and module artifact id? > >> > >> > > >> > 2009/12/3 maven apache > >> > > >> > > Hi: > >> > > I want to know how do maven find the module of the parent project: > >> > > for example in the root project whose packaging is pom and the > >> directory > >> > is > >> > > C:/project, I define the following modules: > >> > > - > >> > > maven > >> > > platform > >> > > main > >> > > -- > >> > > So the module "maven" should be a directory under the > C:/project/maven > >> or > >> > > the directory contains module "maven" can be named as others and its > >> > > artifactId should be "maven"? > >> > > > >> > > >> > > >> > > >> > -- > >> > Regards, > >> > Alexander > >> > > >> > > > > > > > > -- > > Regards, > > Alexander > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > -- Regards, Alexander
Re: the module in maven
the reason to make module name to have the same name as artifactId is so that you dont have define your scm element in every child pom. All Maven needs to the top pom.xml's scm to figure out out scm element of the child module. this is crucial when cutting a release the maven way using its infamous maven-release-plugin if you have lots of modules, this convention is very handy. -Dan On Wed, Dec 2, 2009 at 9:33 PM, Alexander wrote: > Yeah, thats right. > > There are some problems? > > 2009/12/3 maven apache > >> 2009/12/3 Alexander >> >> > Maven way is to name module directory as module artifact id. >> > >> I want to rename the module since the old project are not well named.So I >> should rename both the module directory and module artifact id? >> >> > >> > 2009/12/3 maven apache >> > >> > > Hi: >> > > I want to know how do maven find the module of the parent project: >> > > for example in the root project whose packaging is pom and the >> directory >> > is >> > > C:/project, I define the following modules: >> > > - >> > > maven >> > > platform >> > > main >> > > -- >> > > So the module "maven" should be a directory under the C:/project/maven >> or >> > > the directory contains module "maven" can be named as others and its >> > > artifactId should be "maven"? >> > > >> > >> > >> > >> > -- >> > Regards, >> > Alexander >> > >> > > > > -- > Regards, > Alexander > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: the module in maven
2009/12/3 Alexander > Yeah, thats right. > > There are some problems? > I have tested it ,and I found that the module configed in the pom just referred to the module directory so the module artifact id can changed as one want . > > 2009/12/3 maven apache > > > 2009/12/3 Alexander > > > > > Maven way is to name module directory as module artifact id. > > > > > I want to rename the module since the old project are not well named.So I > > should rename both the module directory and module artifact id? > > > > > > > > 2009/12/3 maven apache > > > > > > > Hi: > > > > I want to know how do maven find the module of the parent project: > > > > for example in the root project whose packaging is pom and the > > directory > > > is > > > > C:/project, I define the following modules: > > > > - > > > > maven > > > > platform > > > > main > > > > -- > > > > So the module "maven" should be a directory under the > C:/project/maven > > or > > > > the directory contains module "maven" can be named as others and its > > > > artifactId should be "maven"? > > > > > > > > > > > > > > > > -- > > > Regards, > > > Alexander > > > > > > > > > -- > Regards, > Alexander >
Re: the module in maven
Yeah, thats right. There are some problems? 2009/12/3 maven apache > 2009/12/3 Alexander > > > Maven way is to name module directory as module artifact id. > > > I want to rename the module since the old project are not well named.So I > should rename both the module directory and module artifact id? > > > > > 2009/12/3 maven apache > > > > > Hi: > > > I want to know how do maven find the module of the parent project: > > > for example in the root project whose packaging is pom and the > directory > > is > > > C:/project, I define the following modules: > > > - > > > maven > > > platform > > > main > > > -- > > > So the module "maven" should be a directory under the C:/project/maven > or > > > the directory contains module "maven" can be named as others and its > > > artifactId should be "maven"? > > > > > > > > > > > -- > > Regards, > > Alexander > > > -- Regards, Alexander
Re: the module in maven
2009/12/3 Alexander > Maven way is to name module directory as module artifact id. > I want to rename the module since the old project are not well named.So I should rename both the module directory and module artifact id? > > 2009/12/3 maven apache > > > Hi: > > I want to know how do maven find the module of the parent project: > > for example in the root project whose packaging is pom and the directory > is > > C:/project, I define the following modules: > > - > > maven > > platform > > main > > -- > > So the module "maven" should be a directory under the C:/project/maven or > > the directory contains module "maven" can be named as others and its > > artifactId should be "maven"? > > > > > > -- > Regards, > Alexander >
Re: the module in maven
Maven way is to name module directory as module artifact id. 2009/12/3 maven apache > Hi: > I want to know how do maven find the module of the parent project: > for example in the root project whose packaging is pom and the directory is > C:/project, I define the following modules: > - > maven > platform > main > -- > So the module "maven" should be a directory under the C:/project/maven or > the directory contains module "maven" can be named as others and its > artifactId should be "maven"? > -- Regards, Alexander
the module in maven
Hi: I want to know how do maven find the module of the parent project: for example in the root project whose packaging is pom and the directory is C:/project, I define the following modules: - maven platform main -- So the module "maven" should be a directory under the C:/project/maven or the directory contains module "maven" can be named as others and its artifactId should be "maven"?
WAR manifest customization - not again!
http://maven.apache.org/plugins/maven-war-plugin/examples/war-manifest-guide.html According to this guide, marking dependency as optional=true should be regarded by war plugin to not copy jars in web-inf / lib I cant get it to work without packagingExcludes If I want to copy some jars in web-inf/lib and refer some from EAR/lib using manifest, this would become messy it seems like optional tag is not respected anymore? I am using Apache Maven 2.2.1 (r801777; 2009-08-06 14:16:01-0500) Java version: 1.6.0_16 Java home: C:\Apps\Java\jdk160_16\jre Default locale: en_US, platform encoding: Cp1252 OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows" Here is my pom 4.0.0 cpa.tuscany.example.service ExampleTuscanyService ExampleTuscanyService war 1.0-SNAPSHOT org.apache.tuscany.sca tuscany-sca-api 2.0-M4 true org.apache.tuscany.sca tuscany-implementation-web-runtime 2.0-M4 true ${artifactId} src org.mortbay.jetty maven-jetty-plugin 6.1.18 org.apache.maven.plugins maven-war-plugin 2.1-beta-1 web WEB-INF/lib/*.jar WEB-INF/lib/*.jar true lib/ package manifest true - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: What is the 'Maven way' to handle multi-artifact code generation from a single model source?
Hi KJ, On Wed, Dec 2, 2009 at 3:19 PM, K J wrote: > Does anyone have any examples or tips about how to handle the > generation of multiple artifacts based on a shared model? For example, > I have a project which needs to produce both Java and ActionScript > code based on a shared UML model. I'm having trouble figuring out how > to best setup and manage these types of projects, so that a change to > the source project can easily result in the build of all the various > generated outputs. Thanks in advance for the help. To go the real Maven way, I think that I'd probably put the shared model data (perhaps some sort of XML?) into a Maven module. Then I'd have more Maven modules for Java and ActionScript, each, that would depend on the model data module. They would use it as a dependency and then generate their source codes accordingly. -jesse - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Building Maven
Hello, I've followed the instructions for building Maven (http://maven.apache.org/guides/development/guide-building-m2.html) but I am not sure what to do after the "mvn install" step. I am trying to get up and running with Maven 3.x (trunk). I am building with Maven 2.2.1. I thought the output would be a directory under target that would resemble the distribution I download from the website? Thanks, -Ryan - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: What is the 'Maven way' to handle multi-artifact code generation from a single model source?
Since the build artifacts are output of the same source, they should part of the same module. Use classifiers to specify the different artifacts. If you are using custom scripts to produce the output (i.e. not plugins that attach additional artifacts automatically), use buildhelper plugin to attach them (and specify the classifiers) see http://mojo.codehaus.org/build-helper-maven-plugin/usage.html. The actionscript code should be packaged up to produce a single artifact (zip it up if a specific packaging format like swf won't do). Kalle On Wed, Dec 2, 2009 at 12:19 PM, K J wrote: > Does anyone have any examples or tips about how to handle the > generation of multiple artifacts based on a shared model? For example, > I have a project which needs to produce both Java and ActionScript > code based on a shared UML model. I'm having trouble figuring out how > to best setup and manage these types of projects, so that a change to > the source project can easily result in the build of all the various > generated outputs. Thanks in advance for the help. > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Timestamped -1.0-SNAPSHOT is being packaged
Hi, When I am packaging a WAR artifact which indirectly depends on 1.0-SNAPSHOT version of XYZ.jar, somehow XYZ-1.0.jar is actually packaged inside the WAR file. This is happening with some artifacts. Wouldn't the latest copy of XYZ-1.0.jar get picked up from the repository and get renamed to XYZ-1.0-SNAPSHOT.jar while packaging ? What I am doing wrong here? I am using the following command to deploy... mvn deploy:deploy-file -DgroupId= -DartifactId=XYZ -Dversion=1.0-SNAPSHOT -Dpackaging=jar -DgeneratePom=true -DrepositoryId=snapshots -Durl= -Dfile= Thanks, Venkat - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
What is the 'Maven way' to handle multi-artifact code generation from a single model source?
Does anyone have any examples or tips about how to handle the generation of multiple artifacts based on a shared model? For example, I have a project which needs to produce both Java and ActionScript code based on a shared UML model. I'm having trouble figuring out how to best setup and manage these types of projects, so that a change to the source project can easily result in the build of all the various generated outputs. Thanks in advance for the help. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Release Plugin with Flat Multi-Module Projects
I have done enough research and found a few things. 1. 2.0-beta-10 partially addresses this issue, but that is not a desired solution (will explain this later) 2. Better not to rely on the maven release plugin if you want to save some time before they fix it completely. I have multiple flat multi-modules in my project. Ex. There are projects A, B, C, D, ABCD, K, L, M, KLM, X, Y, Z, XYZ. ABCD is a project with parent pom in it which will have module entries for all the projects A, B, C, and D. KLM is a project with parent pom in it which will have module entries for all the projects K, L and M and the same way the third one. With the plugin 2.0-beta-9, what I see is the same as yours. If I build ABCD, i.e my working directory will be /trunk/ABCD/ the release plug-in is tagging only the sources under the project ABCD/. Though the module references are there in ABCD/pom.xml, tagging A, B, C and D are ignored. I have come across a fix in 2.0-beta-10 and I applied those patches on the top of 2.0-beta-9 to see how it works. What is happening now is, instead of considering the files under ABCD/, at the time of tagging it is going a step back and tagging all projects from that directory. i.e All projects A, B, C, D, ABCD, K, L, M, KLM, etc., all are being tagged now. Actual solution desired is, if you build ABCD, it suppose to tag A, B, C, D, the same way if you build KLM, it suppose to tag K, L, M with the next tag in sequence. etc., In my scenario, I cannot have one pom in the trunk/ as I have multiple projects under trunk. Finally, what I did was, stopped using the release plugin and did the things manually using direct svn commands. 1. Created a file under ABCD (projects.txt) which will have A, B, C, D (project names) each in a new line. 2. after the maven clean install, I execute the script, which will read that file projects.txt and gets all the projects which are the child projects of ABCD project and will tag each of them. Note: Am I passing the tag each time when I build the project? NO. I am using hudson, and which has a few environment variables and one is the build number. I have passed this number with a desired prefix to have a tag name appear like ABCD_x_%BUILD_NUMBER%. Each time I build for release, it takes a different number for tag and tags all projects related to ABCD. In the same way, it will do for KLM and XYZ. I had spent unnecessarily a lot of time in research of this. Thanks, Guru Neil Chaudhuri-2 wrote: > > I have a flat multi-module project as follows: > > myapp-parent > --pom.xml > myapp-persistence > --pom.xml > myapp-services > --pom.xml > > The parent module is simply inherited by the others, and services > aggregates persistence. > > I am using SVN SCM and Maven Release Plugin 2.0-beta-9. My goal with each > release is simply to create a folder in the tags directory that looks as > follows: > > /myapp/tags/ > --myapp-0.8.0 > myapp-parent-0.8.0 > -- > myapp-persistence-0.8.0 > -- > myapp-services-0.8.0 > -- > > When I run the Maven Release Plugin at the parent pom level, all I get is > this: > > /myapp/tags > --myapp-parent-0.8.0 > > > Even though it may not be obvious from the high art of dash indentation, I > have two problems: > 1) The parent module is not contained in some "larger" folder beneath > myapp-0.8.0/tags. > 2) It is only the parent module being tagged. > > Here is my configuration of the plugin in the parent pom: > > > org.apache.maven.plugins > maven-release-plugin > 2.0-beta-9 > > > false > clean install > -Dmaven.test.skip > svn:tags > > > > After doing some research, I discovered the following: > http://jira.codehaus.org/browse/MRELEASE-261. Here it says that Maven > Release Plugin 2.0-beta-10 should support multi-module projects and that > in fact the issue I an seeing is closed. > > At long last, here are my questions: > > 1) Is my desired tag structure (myapp-0.8.0 folder beneath tags and > containing all the flat modules) possible with the currently released > plugin? How would I do it? > 2) Is the fact I am not tagging the other modules a result of the same > issue addressed by that JIRA page, or am I mixing things up and just doing > something wrong with my current configuration? > 3) Will what I want be possible with the next version? When is the next > version due? > > Please let me know if I need to clarify anything. I appreciate your > insight. > > Thanks. > > -- View this message in context: http://old.nabble.com/Release-Plugin-with-Flat-Multi-Module-Projects-tp26040211p26614408.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-m
repo2 and repo1 the same? (Was Re: please tell me repository)
Wendy Smoak-3 wrote: > > On Wed, Oct 29, 2008 at 1:45 PM, miro wrote: >> >> please tell me repository where I can find all dependency for an >> application >> using hibernate , spring, wicket jdk 1.6 > > It depends on exactly what artifacts and version numbers you need, but > most of that should be in the central repo which is searched by > default -- http://repo2.maven.org/maven2/ . > > -- > Wendy > But the Sonatype Maven book[1] states that the Super POM has http://repo1.maven.org/maven2 by default, not http://repo2.maven.org/maven2/ . Do these two URLs point to the same repository location, *or* are they replicated and should be in sync but may not be for particular dependencies? When I type in the first URL it redirects me to the second, but no such redirection occurs when I add an extended path to a particular dependency to the end of those URLs. I'm confused over this because I'm presently having a problem with Axis2, it appears that their artifacts are different between the two URLs[2], but I'm unsure if those URL's are actually just pointing to the same repo, so somehow the error might be on my end. Thanks, Glen [1] http://www.sonatype.com/books/maven-book/reference/pom-relationships-sect-pom.html#pom-relationships-sect-super-pom [2] https://issues.apache.org/jira/browse/AXIS2-4571 -- View this message in context: http://old.nabble.com/please-tell-me-repository-tp20235538p26614031.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Upload Apache Pivot artifacts to central repository
Hi all, Apache Pivot is preparing for graduation, and we would like to upload our next set of release artifacts to the central Maven repository. We don't currently use Maven as a build tool, so I have been trying to follow the manual upload instructions listed here: http://www.apache.org/dev/release-publishing.html#maven-repo There is a section at the bottom that is meant to explain how to create an appropriate POM file, but it does not appear to be complete: http://www.apache.org/dev/release-publishing.html#repository-descriptor I have created some POMs that I think should work, but it would be very helpful if someone with a knowledgeable eye could take a quick look to make sure that they contain the correct information, are structured properly, etc. There is a root POM in the trunk, and a POM in each project-specific subdirectory that we plan to publish to the repository (note that these files refer to the anticipated future name and location of the project, as opposed to its current Incubator name and location): http://svn.apache.org/repos/asf/incubator/pivot/trunk/ Based on the documentation I have read thus far, I assume that we'll want to place our compiled JARs in a pivot/jars directory, and structure our POMs as follows: pivot/poms pom.xml /core/pom.xml /web/pom.xml /wtk/pom.xml /wtk-terra/pom.xml I don't think we'll need to use the distributions directory, and I assume that the licenses directory should simply contain a copy of our main LICENSE file. Is this all correct? Also, one of our mentors, Martijn Dashorst, suggested that there might be a top-level ASF POM that the root Pivot POM could extend (rather than duplicating the ASF info). If so, could you point us to it? Thanks - your assistance is very much appreciated! Greg Brown Apache Pivot - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Maven Run & Manifest entries
Thanks Milos, is there a variable for like for className, packageClassName? Toni Bugzilla from mkle...@gmail.com wrote: > > I would say you need to change the Run project action mapping in the ide > not > to use mvn exec:exec to execute "java -cp " but to execute > :java > -jar " > > Regards > > > Milos Kleint > > > > On Wed, Dec 2, 2009 at 5:46 PM, eppleton wrote: > >> >> Hi, >> >> I've created a Maven Project in NetBeans. It writes an entry into the >> JARs >> manifest. That works fine. At runtime I'm reading that entry (which >> points >> to a configuration file) and use it for configuration. That works fine as >> well… >> >> The problem is, that when running the project from the IDE instead of the >> JAR, the class files in the target folder is used, so there's no >> manifest. >> When I copy my manifest there, it works fine. What would be the best >> approach to do that automatically? >> >> Thanks >> >> Toni >> -- >> View this message in context: >> http://old.nabble.com/Maven-Run---Manifest-entries-tp26612165p26612165.html >> Sent from the Maven - Users mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org >> For additional commands, e-mail: users-h...@maven.apache.org >> >> > > -- View this message in context: http://old.nabble.com/Maven-Run---Manifest-entries-tp26612165p26612608.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Maven Run & Manifest entries
or somehow generate the manifest file in the target area. Milos On Wed, Dec 2, 2009 at 6:02 PM, Milos Kleint wrote: > I would say you need to change the Run project action mapping in the ide > not to use mvn exec:exec to execute "java -cp " but to execute > :java -jar " > > Regards > > > Milos Kleint > > > On Wed, Dec 2, 2009 at 5:46 PM, eppleton wrote: > >> >> Hi, >> >> I've created a Maven Project in NetBeans. It writes an entry into the JARs >> manifest. That works fine. At runtime I'm reading that entry (which points >> to a configuration file) and use it for configuration. That works fine as >> well… >> >> The problem is, that when running the project from the IDE instead of the >> JAR, the class files in the target folder is used, so there's no manifest. >> When I copy my manifest there, it works fine. What would be the best >> approach to do that automatically? >> >> Thanks >> >> Toni >> -- >> View this message in context: >> http://old.nabble.com/Maven-Run---Manifest-entries-tp26612165p26612165.html >> Sent from the Maven - Users mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org >> For additional commands, e-mail: users-h...@maven.apache.org >> >> >
Re: Maven Run & Manifest entries
I would say you need to change the Run project action mapping in the ide not to use mvn exec:exec to execute "java -cp " but to execute :java -jar " Regards Milos Kleint On Wed, Dec 2, 2009 at 5:46 PM, eppleton wrote: > > Hi, > > I've created a Maven Project in NetBeans. It writes an entry into the JARs > manifest. That works fine. At runtime I'm reading that entry (which points > to a configuration file) and use it for configuration. That works fine as > well… > > The problem is, that when running the project from the IDE instead of the > JAR, the class files in the target folder is used, so there's no manifest. > When I copy my manifest there, it works fine. What would be the best > approach to do that automatically? > > Thanks > > Toni > -- > View this message in context: > http://old.nabble.com/Maven-Run---Manifest-entries-tp26612165p26612165.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Maven Run & Manifest entries
Hi, I've created a Maven Project in NetBeans. It writes an entry into the JARs manifest. That works fine. At runtime I'm reading that entry (which points to a configuration file) and use it for configuration. That works fine as well… The problem is, that when running the project from the IDE instead of the JAR, the class files in the target folder is used, so there's no manifest. When I copy my manifest there, it works fine. What would be the best approach to do that automatically? Thanks Toni -- View this message in context: http://old.nabble.com/Maven-Run---Manifest-entries-tp26612165p26612165.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
RE: How to access Maven default properties from a Junit test?
As you suggest you can also read them in from somewhere. Create a test resources property file that gets filtered and read that. Much simpler and easier to maintain when there's more than a few properties. -Original Message- From: Dan Tran [mailto:dant...@gmail.com] Sent: Wednesday, December 02, 2009 9:25 AM To: Maven Users List Subject: Re: How to access Maven default properties from a Junit test? You need to pass them in explicitly using surefire plugin's properties configuration -D On Wed, Dec 2, 2009 at 4:55 AM, Costin Caraivan wrote: > > Hello, > > Does Maven pass the default properties to a Junit test launched? If > so, how can I access them? > > For example I would like to know ${project.groupId} or ${project.version}. > Is there any way I can access these from the Junit tests? > > Thank you, > Costin. > > PS: What I really want to know if there is a mechanism in place, I > don't really want to fill the configuration with duplicate properties, > or make a temporary file which I read later. If there's no elegant > solution, I'll just read the from somewhere :) > -- > View this message in context: > http://old.nabble.com/How-to-access-Maven-default-properties-from-a-Ju > nit-test--tp26608418p26608418.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org --- CONFIDENTIALITY NOTICE: This e-mail and any files attached may contain confidential and proprietary information of Alcatel-Lucent and/or its affiliated entities. Access by the intended recipient only is authorized. Any liability arising from any party acting, or refraining from acting, on any information contained in this e-mail is hereby excluded. If you are not the intended recipient, please notify the sender immediately, destroy the original transmission and its attachments and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Copyright in this e-mail and any attachments belongs to Alcatel-Lucent and/or its affiliated entities. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Global shared memory
MavenSession? 2009/12/2 Gajo Csaba : > Hello, > > Is there a way I can share some values between mojos, and so that they > aren't Strings? I know that there is a mavenProject.getProperties() thing > which can be used, but in this case I would like to share a HashMap. > > Regards, Csaba > > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Global shared memory
Hello, Is there a way I can share some values between mojos, and so that they aren't Strings? I know that there is a mavenProject.getProperties() thing which can be used, but in this case I would like to share a HashMap. Regards, Csaba - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: How to access Maven default properties from a Junit test?
You need to pass them in explicitly using surefire plugin's properties configuration -D On Wed, Dec 2, 2009 at 4:55 AM, Costin Caraivan wrote: > > Hello, > > Does Maven pass the default properties to a Junit test launched? If so, how > can I access them? > > For example I would like to know ${project.groupId} or ${project.version}. > Is there any way I can access these from the Junit tests? > > Thank you, > Costin. > > PS: What I really want to know if there is a mechanism in place, I don't > really want to fill the configuration with duplicate properties, or make a > temporary file which I read later. If there's no elegant solution, I'll just > read the from somewhere :) > -- > View this message in context: > http://old.nabble.com/How-to-access-Maven-default-properties-from-a-Junit-test--tp26608418p26608418.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
How to access Maven default properties from a Junit test?
Hello, Does Maven pass the default properties to a Junit test launched? If so, how can I access them? For example I would like to know ${project.groupId} or ${project.version}. Is there any way I can access these from the Junit tests? Thank you, Costin. PS: What I really want to know if there is a mechanism in place, I don't really want to fill the configuration with duplicate properties, or make a temporary file which I read later. If there's no elegant solution, I'll just read the from somewhere :) -- View this message in context: http://old.nabble.com/How-to-access-Maven-default-properties-from-a-Junit-test--tp26608418p26608418.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
How to change the plugin config from a mojo?
Hello, I have a mojo which requires a project. When it starts, it gets the project's build plugins, searches for a specific one, and then takes its configuration and changes is. The configuration is an Xpp3Dom object, which I convert to String with toString()... but how do I convert that String back to Xpp3Dom? This is what I mean: String config = plugin.getConfiguration().toString(); config = doStuff(config); plugin.setConfiguration(config); Thanks, Csaba - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Issue with assembly plugin executions and phase binding (prepare-package)
Hello, I have some questions about assembly and inheritance... Purpose is to generate a tar.gz archive, containing a text file with the list of checksums of the tar.gz content (excluding the checksums file itself of course). So the wanted order of execution would be : - call assembly plugin with "directory-single" to generate folder (prepare-package) - call antrun plugin to generate checksums file from and in previous folder (prepare-package) - call assembly plugin with "single" to create final archive file (package) Antrun plugin is located first in list of plugins, and is binded to phase "package", goal "run". My assembly plugin is next and configured with the following executions : prepare-checksums prepare-package directory-single tar-gz package single tar-gz-from-dir The parent of this pom just declares assembly plugin and version, binding the default execution to phase package and goal single, overloaded in this pom. If I bind the first execution (prepare-checksums) to "directory-single", the following error occur : [INFO] Error creating assembly: Error adding file 'com.gemalto.europetelcosoft.projects.country.customer.w_project_sample:SayHello:jar:1.0-SNAPSHOT' to archive: Z:\MKS\CUBv2\Dev\sample-project-2.0.1\SayHello\target\classes isn't a file. This is not occurring only in m2eclipse, but in maven 2.2.1 command line also. The workaround I found, was to configure my assembly like this : prepare-checksums package directory-single tar-gz package assembly tar-gz-from-dir And configure antrun to be bound to package phase (and located after assembly plugin). So the execution becomes : 1- [assembly:single {execution: default}] generates the .tar.gz 2- [assembly:directory-single {execution: prepare-checksums}] generate content folder 3- [antrun:run {execution: generate-checksum}] generates checksums the checksum file 4- [assembly:assembly {execution: default}] generates tar.gz a second time 5- [assembly:single {execution: default}] generates tar.gz a third time 6- [assembly:directory-single {execution: prepare-checksums}] again 7- [antrun:run {execution: generate-checksum}] I believe step 4 is the beginning of the forked life-cycle caused by goal "assembly". Then all package phase is re-executed. I believe also that "default" executions of "assembly:single" come from the parent pom, while "default" executions of "assembly:assembly" come from this pom. Strangely, it seems these default executions are not overloaded but executed twice, maybe because goal is different. That being so, it's not possible to use "skipAssembly" on the child pom for the "assembly:single", because you're not permitted to declare the same execution twice in the same pom (even though both are executed, it's a bit strange). As expected, removing the assembly plugin declaration in the parent removes steps 1, 5 and 6. So I see 2 problems here, and would be grateful to hear any comments : - why isn't it possible to bind "assembly:directory-single" to another phase than "package" ? - why the default execution is not inherited the same way named executions are ? Why Maven would consider 2 different "default" executions in parent and child only because goal is different ? I would expect the child to impose it's declared goal. I'm using Maven 2.2.1 command-line. Thanks for help, Jeremie
Re: Security credentials to repository on the command line
As you say you either grant anonymous access to the repo or you don't. If you don't allow anonymous access, every user needs to provide his/her credentials. This is what the user specific settings.xml file is for. Put it there. If you think that creating that file is difficult for a user, you need to look into some tool aiding you with that. One way is through a Maven plugin included in Nexus Pro (the licensed version of Nexus), but it shouldn't be too hard creating some default template file somewhere and then provide a script or the command to copy that file. /Anders On Wed, Dec 2, 2009 at 11:22, wujek.srujek wrote: > > Hi. Here is my situation: we have an internal repository that used HTTP > basic > authentication. This repository is defined in the parent pom of the project > to create a portable build. However, when I check this project out along > with its submodules, mvn package doesn't download the dependencies, as > maven > complains it doesn't have the security credentials and cannot authenticate. > The only way I could find is to put the credentials in the settings.xml > file. However, this will require the user to create this file somehow, so > the build will be environment-dependent. I can make this settings.xml file > available somewhere, but this will require more actions from the user and > also it will have to be remembered. The other option is to allow anonymous > read access to our repository, but this is outside my decision, and it will > not happen. Another option would be to be able to specify the security > credentials and repository id on the command line; I couldn't find anything > on the net, however. > Is specifying the credentials on the command line possible at all? I know > this can be messy, as there can be many repositories and I would have to > somehow bind the credentials to the correct repo. Something like this > maybe: > mvn package -DrepositoryId.1=id1 -Did1.username=user1 -Did1.password=pass1 > -DrepositoryId.2=id2 -Did2.username=user2 -Did2.password=pass2 > > or maybe there is any other way? > > Regards. > -- > View this message in context: > http://old.nabble.com/Security-credentials-to-repository-on-the-command-line-tp26606415p26606415.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Security credentials to repository on the command line
Hi. Here is my situation: we have an internal repository that used HTTP basic authentication. This repository is defined in the parent pom of the project to create a portable build. However, when I check this project out along with its submodules, mvn package doesn't download the dependencies, as maven complains it doesn't have the security credentials and cannot authenticate. The only way I could find is to put the credentials in the settings.xml file. However, this will require the user to create this file somehow, so the build will be environment-dependent. I can make this settings.xml file available somewhere, but this will require more actions from the user and also it will have to be remembered. The other option is to allow anonymous read access to our repository, but this is outside my decision, and it will not happen. Another option would be to be able to specify the security credentials and repository id on the command line; I couldn't find anything on the net, however. Is specifying the credentials on the command line possible at all? I know this can be messy, as there can be many repositories and I would have to somehow bind the credentials to the correct repo. Something like this maybe: mvn package -DrepositoryId.1=id1 -Did1.username=user1 -Did1.password=pass1 -DrepositoryId.2=id2 -Did2.username=user2 -Did2.password=pass2 or maybe there is any other way? Regards. -- View this message in context: http://old.nabble.com/Security-credentials-to-repository-on-the-command-line-tp26606415p26606415.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: File system repo
Seems as we keep on repeating this best-practice. Still people try to prove us wrong... /Anders 2009/12/2 Tamás Cservenák > Hi there, > > This thread started at Mon, Nov 9, 2009 at 8:00 PM, and last response is > sent on Tue, Dec 1, 2009 at 11:58 PM (my local TZ, but i want to point out > the duration). > > Installing _any_ MRM out there lasts certainly well under 1 hrs (some of > them even under 10 minutes if you don't count the download ;) > Uploading those two artifacts should not last more then 10 minutes. > Setting up your POMs to refer to that MRM is what, more 10 minutes? > > So, in an hour and half (upper limit!) you would be done. Without system > scope. > > > Thanks, > ~t~ > > On Tue, Dec 1, 2009 at 10:39 PM, monkeyden wrote: > > > > > So I guess the question is, how then can you get a jar file, which is not > > installed in any repository, onto the compile classpath then into your > > ear/war file? > > > > > > Wayne Fay wrote: > > > > > >> Hi Wayne. I have my build working fine, it's just not including the > > >> system > > >> scoped jars in my war's WEB-INF/lib directory. It seems the system > > scope > > >> does not include them. Any idea how I can get them into the resulting > > >> artifact? > > > > > > This is exactly how system scope is supposed to work -- it means "this > > > artifact will be provided by the system" therefore Maven does not > > > include them in packages it builds. > > > > > > Add the artifacts to your corporate repo/local repo cache, and change > > > scope to "compile" if you need them included. > > > > > > As I've said before in this thread, do NOT use system scope. > > > > > > Wayne > > > > > > - > > > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > > > For additional commands, e-mail: users-h...@maven.apache.org > > > > > > > > > > > > > -- > > View this message in context: > > http://old.nabble.com/File-system-repo-tp26271810p26599512.html > > Sent from the Maven - Users mailing list archive at Nabble.com. > > > > > > - > > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > > For additional commands, e-mail: users-h...@maven.apache.org > > > > >
Re: Running ANT task before pulling down dependencies
Golder rule of build scripts: If they are not broken, don't fix them Now if you want to refactor your build scripts from ANT to Maven (which IMHO is a good thing) here is what I would recommend: 1. Set up a Maven Repository Manager (I use nexus, but there are others, e.g. artifactory) 2. Start by adding Maven ANT Tasks to your ANT builds scripts. 2.1 Add an to deploy your artifacts to the Maven Repository Manager. 2.2 New projects can use Maven. 2.3 Stop using the "big bag of jars" lib folder concept and pull down the intra-project artifacts from the MRM in the ANT build scripts 3. Take the ANT projects one at a time and convert to Maven projects... if you do this slowly, you can probably keep the ANT build script working in parallel. Once you have passed step 2.1 above, you are free to mavenize projects at leasure HTH -Stephen 2009/12/2 Vijay Venkataraman : > Hi Anders > > You are right. Unfortunately all the product builds are ant builds and there > is no central repository concept which holds the artifacts in the way that > is prescribed by maven. Again i cannot change all those pieces one shot. I > want to try this out on one project and then slowly work on moving other > pieces one by one. > > Thanks, > Vijay > > On Tue, Dec 1, 2009 at 11:21 PM, Anders Hammar wrote: > >> Any reason why you're trying to build your own solution instead of going >> the >> Maven way by setting up a corporate repository populated with these >> artifacts? Not only would it be the right solution, my guess is that it >> would be so much easier than going against Maven. >> >> /Anders >> >> On Wed, Dec 2, 2009 at 07:06, Vijay Venkataraman < >> vijay.venkatara...@gmail.com> wrote: >> >> > Hi, >> > Currently i am trying to get maven project setup which creates a jar >> > artifact. I have setup the project structure. >> > Unfortunately i we don't have the libraries in central repository as per >> > maven layout and jars don't have version numbers. >> > They are jars like product1.jar, product2.jar. These jars are the project >> > dependencies. >> > I was thinking of running ant task which will move the jars to necessary >> > location and rename the jars during validate phase. After which i expect >> > the >> > compile to execute. >> > >> > But i see that dependency resolution happens first before any tasks can >> be >> > executed. Is it that i should write a separate ant script to do this >> before >> > running maven. >> > I am using maven 2.1.0. >> > >> > Is there a better way to accomplish this? >> > >> > Thanks, >> > Vijay >> > >> > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: File system repo
Hi there, This thread started at Mon, Nov 9, 2009 at 8:00 PM, and last response is sent on Tue, Dec 1, 2009 at 11:58 PM (my local TZ, but i want to point out the duration). Installing _any_ MRM out there lasts certainly well under 1 hrs (some of them even under 10 minutes if you don't count the download ;) Uploading those two artifacts should not last more then 10 minutes. Setting up your POMs to refer to that MRM is what, more 10 minutes? So, in an hour and half (upper limit!) you would be done. Without system scope. Thanks, ~t~ On Tue, Dec 1, 2009 at 10:39 PM, monkeyden wrote: > > So I guess the question is, how then can you get a jar file, which is not > installed in any repository, onto the compile classpath then into your > ear/war file? > > > Wayne Fay wrote: > > > >> Hi Wayne. I have my build working fine, it's just not including the > >> system > >> scoped jars in my war's WEB-INF/lib directory. It seems the system > scope > >> does not include them. Any idea how I can get them into the resulting > >> artifact? > > > > This is exactly how system scope is supposed to work -- it means "this > > artifact will be provided by the system" therefore Maven does not > > include them in packages it builds. > > > > Add the artifacts to your corporate repo/local repo cache, and change > > scope to "compile" if you need them included. > > > > As I've said before in this thread, do NOT use system scope. > > > > Wayne > > > > - > > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > > For additional commands, e-mail: users-h...@maven.apache.org > > > > > > > > -- > View this message in context: > http://old.nabble.com/File-system-repo-tp26271810p26599512.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re: Running ANT task before pulling down dependencies
Well, set up a repository manager for your project then. Setting up Nexus shouldn't take more than half a day and it doesn't require a super computer. Then deploy the artifacts there. As stated in many threads by many people, if you fight Maven you'll just be sorry and likely you'd be better off staying with your old build tool. On the other hand, if you just put a little extra effort into doing things the Maven way you'll be greatly rewarded. :-) /Anders On Wed, Dec 2, 2009 at 09:21, Vijay Venkataraman < vijay.venkatara...@gmail.com> wrote: > Hi Anders > > You are right. Unfortunately all the product builds are ant builds and > there > is no central repository concept which holds the artifacts in the way that > is prescribed by maven. Again i cannot change all those pieces one shot. I > want to try this out on one project and then slowly work on moving other > pieces one by one. > > Thanks, > Vijay > > On Tue, Dec 1, 2009 at 11:21 PM, Anders Hammar wrote: > > > Any reason why you're trying to build your own solution instead of going > > the > > Maven way by setting up a corporate repository populated with these > > artifacts? Not only would it be the right solution, my guess is that it > > would be so much easier than going against Maven. > > > > /Anders > > > > On Wed, Dec 2, 2009 at 07:06, Vijay Venkataraman < > > vijay.venkatara...@gmail.com> wrote: > > > > > Hi, > > > Currently i am trying to get maven project setup which creates a jar > > > artifact. I have setup the project structure. > > > Unfortunately i we don't have the libraries in central repository as > per > > > maven layout and jars don't have version numbers. > > > They are jars like product1.jar, product2.jar. These jars are the > project > > > dependencies. > > > I was thinking of running ant task which will move the jars to > necessary > > > location and rename the jars during validate phase. After which i > expect > > > the > > > compile to execute. > > > > > > But i see that dependency resolution happens first before any tasks can > > be > > > executed. Is it that i should write a separate ant script to do this > > before > > > running maven. > > > I am using maven 2.1.0. > > > > > > Is there a better way to accomplish this? > > > > > > Thanks, > > > Vijay > > > > > >
Re: Running ANT task before pulling down dependencies
Hi Anders You are right. Unfortunately all the product builds are ant builds and there is no central repository concept which holds the artifacts in the way that is prescribed by maven. Again i cannot change all those pieces one shot. I want to try this out on one project and then slowly work on moving other pieces one by one. Thanks, Vijay On Tue, Dec 1, 2009 at 11:21 PM, Anders Hammar wrote: > Any reason why you're trying to build your own solution instead of going > the > Maven way by setting up a corporate repository populated with these > artifacts? Not only would it be the right solution, my guess is that it > would be so much easier than going against Maven. > > /Anders > > On Wed, Dec 2, 2009 at 07:06, Vijay Venkataraman < > vijay.venkatara...@gmail.com> wrote: > > > Hi, > > Currently i am trying to get maven project setup which creates a jar > > artifact. I have setup the project structure. > > Unfortunately i we don't have the libraries in central repository as per > > maven layout and jars don't have version numbers. > > They are jars like product1.jar, product2.jar. These jars are the project > > dependencies. > > I was thinking of running ant task which will move the jars to necessary > > location and rename the jars during validate phase. After which i expect > > the > > compile to execute. > > > > But i see that dependency resolution happens first before any tasks can > be > > executed. Is it that i should write a separate ant script to do this > before > > running maven. > > I am using maven 2.1.0. > > > > Is there a better way to accomplish this? > > > > Thanks, > > Vijay > > >