Re: Newbie question: how to find a) latest version and b) repository given an artifactID
You can try RSO and do a search: https://repository.sonatype.org/index.html#nexus-search;gav~~gwt-servlet~~~ It indexes "most popular" Maven repositories, but not all of them ;) Also, it seems that 2.1.0-RC1 is not in central yet (because it is an "RC"?). Hope helps, ~t~ On Thu, Oct 21, 2010 at 9:17 PM, Stephen Boesch wrote: > If I am looking for an artificat and have its artifactID and want to find > the versions available in public maven repos' (maven central, etc). What > might be recommended way to do that? > > Do I have to already know in advance which repo's to try? E.g. maven > central, mvnrepository.com etc. Or is there a better (more sane..) way > to > do this? > > Here's a specific case: I am looking for gwt-servlet I think the latest > version is 2.1.0-RC1. But i have been going in circles trying to find out > where a mvn repo is for it. This is however just the latest case: I have > been in this pattern of confusion for maven artifacts a number of times > already. > > thanks >
Re: Newbie question: how to find a) latest version and b) repository given an artifactID
The repository URl is nothing more than just a root URL of the specified directory structure. You can use the url I gave as repository URL. It was not my decision to create a repository for each seperate version, and also in Subversion. ;) With regards, Nick Stolwijk ~Java Developer~ IPROFS BV. Claus Sluterweg 125 2012 WS Haarlem http://www.iprofs.nl On Thu, Oct 21, 2010 at 9:32 PM, Stephen Boesch wrote: > This shows how to pick up the artifact. What is the repository url that I > would use? > > > > 2010/10/21 Nick Stolwijk > >> It is hard to get the repository, because everyone can start their own >> (and in their own way). >> >> I googled on filetype:jar gwt-servlet:2.1.0-RC1 and found the repository >> here: >> >> >> http://code.google.com/p/google-web-toolkit/source/browse/#svn/2.1.0/gwt/maven >> for the latest version. >> >> With regards, >> >> Nick Stolwijk >> ~Java Developer~ >> >> IPROFS BV. >> Claus Sluterweg 125 >> 2012 WS Haarlem >> http://www.iprofs.nl >> >> >> >> On Thu, Oct 21, 2010 at 9:17 PM, Stephen Boesch wrote: >> > 2.1.0-RC1 >> >> - >> 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: Newbie question: how to find a) latest version and b) repository given an artifactID
This shows how to pick up the artifact. What is the repository url that I would use? 2010/10/21 Nick Stolwijk > It is hard to get the repository, because everyone can start their own > (and in their own way). > > I googled on filetype:jar gwt-servlet:2.1.0-RC1 and found the repository > here: > > > http://code.google.com/p/google-web-toolkit/source/browse/#svn/2.1.0/gwt/maven > for the latest version. > > With regards, > > Nick Stolwijk > ~Java Developer~ > > IPROFS BV. > Claus Sluterweg 125 > 2012 WS Haarlem > http://www.iprofs.nl > > > > On Thu, Oct 21, 2010 at 9:17 PM, Stephen Boesch wrote: > > 2.1.0-RC1 > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re: Newbie question: how to find a) latest version and b) repository given an artifactID
It is hard to get the repository, because everyone can start their own (and in their own way). I googled on filetype:jar gwt-servlet:2.1.0-RC1 and found the repository here: http://code.google.com/p/google-web-toolkit/source/browse/#svn/2.1.0/gwt/maven for the latest version. With regards, Nick Stolwijk ~Java Developer~ IPROFS BV. Claus Sluterweg 125 2012 WS Haarlem http://www.iprofs.nl On Thu, Oct 21, 2010 at 9:17 PM, Stephen Boesch wrote: > 2.1.0-RC1 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Newbie question: how to find a) latest version and b) repository given an artifactID
If I am looking for an artificat and have its artifactID and want to find the versions available in public maven repos' (maven central, etc). What might be recommended way to do that? Do I have to already know in advance which repo's to try? E.g. maven central, mvnrepository.com etc. Or is there a better (more sane..) way to do this? Here's a specific case: I am looking for gwt-servlet I think the latest version is 2.1.0-RC1. But i have been going in circles trying to find out where a mvn repo is for it. This is however just the latest case: I have been in this pattern of confusion for maven artifacts a number of times already. thanks
Re: newbie question
Thanks for the advice, I've already installed it and began uploading my artifacts. Thanks! On May 26, 2010, at 19:57, "Ron Wheeler" software.com> wrote: Save yourself a lot of grief and needless screwing about. Install the free version of Nexus. 1) Solves one of your immediate problems - It gives you a good place to put third party libraries. 2) Gives you a lot more visibility into the "Maven way" 3) Forces you to come to grips with Releases and Snapshots early in the process - add clarity to your development process. 4) Encourages you to build proper utility libraries and sharable artifacts. Everyone is pulling their stuff from the same place. 5) Reduces the jar equivalent of DLL hell. You can see what versions are available. YOu don't have to search all over the place for libraries. and more. I wish we had done this when we first started with Maven. Would have saved us months of time guessing our way through Maven and various project structures, dependency issues, library version nonsense, etc. Ron On 26/05/2010 2:06 PM, Shan Syed wrote: you need to specify a dependencies for everything; in the case you depend on a jar that's not publicly available (3rd party vendor, in-house jar, etc), you have a few options: -maintain a repository for these sorts of things, using a tool like archiva, nexus, or artifactory (ideal for teams of more than 1) -install it locally http://maven.apache.org/guides/mini/guide-3rd-party-jars-local.html -specify a local location for the JAR, by using "system scope" (not the greatest solution) On Wed, May 26, 2010 at 2:00 PM, Meeusen, Christopher W.< meeusen.christop...@mayo.edu> wrote: I guess I miss understood the concept of dependencies. I thought that it was used only for .jars that were in a repository say commons- lang-2.4, but if you have some api from a vendor, say vendor.jar, that you didn't have to configure a decency for that. -Original Message- From: users-return-111621-meeusen.christopher=mayo@maven.apache.org [mailto: users-return-111621-meeusen.christopher=mayo@maven.apache.org] On Behalf Of Wayne Fay Sent: Wednesday, May 26, 2010 12:50 PM To: Maven Users List Subject: Re: newbie question Getting a bunch of these. Do I have to configure the compiler plugin and explicitly tell it to use the .jars referenced in my build path? No configuration of the compiler plugin should be necessary. You simply need to properly configure your list. Most likely you are simply missing one or more dependencies -- looks like axis2 is the first, but I don't recognize the com.idx one and assume it is an internal artifact that you're working on. Wayne --- -- 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 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: newbie question
Save yourself a lot of grief and needless screwing about. Install the free version of Nexus. 1) Solves one of your immediate problems - It gives you a good place to put third party libraries. 2) Gives you a lot more visibility into the "Maven way" 3) Forces you to come to grips with Releases and Snapshots early in the process - add clarity to your development process. 4) Encourages you to build proper utility libraries and sharable artifacts. Everyone is pulling their stuff from the same place. 5) Reduces the jar equivalent of DLL hell. You can see what versions are available. YOu don't have to search all over the place for libraries. and more. I wish we had done this when we first started with Maven. Would have saved us months of time guessing our way through Maven and various project structures, dependency issues, library version nonsense, etc. Ron On 26/05/2010 2:06 PM, Shan Syed wrote: you need to specify a dependencies for everything; in the case you depend on a jar that's not publicly available (3rd party vendor, in-house jar, etc), you have a few options: -maintain a repository for these sorts of things, using a tool like archiva, nexus, or artifactory (ideal for teams of more than 1) -install it locally http://maven.apache.org/guides/mini/guide-3rd-party-jars-local.html -specify a local location for the JAR, by using "system scope" (not the greatest solution) On Wed, May 26, 2010 at 2:00 PM, Meeusen, Christopher W.< meeusen.christop...@mayo.edu> wrote: I guess I miss understood the concept of dependencies. I thought that it was used only for .jars that were in a repository say commons-lang-2.4, but if you have some api from a vendor, say vendor.jar, that you didn't have to configure a decency for that. -Original Message- From: users-return-111621-meeusen.christopher=mayo@maven.apache.org[mailto: users-return-111621-meeusen.christopher=mayo@maven.apache.org] On Behalf Of Wayne Fay Sent: Wednesday, May 26, 2010 12:50 PM To: Maven Users List Subject: Re: newbie question Getting a bunch of these. Do I have to configure the compiler plugin and explicitly tell it to use the .jars referenced in my build path? No configuration of the compiler plugin should be necessary. You simply need to properly configure your list. Most likely you are simply missing one or more dependencies -- looks like axis2 is the first, but I don't recognize the com.idx one and assume it is an internal artifact that you're working on. Wayne - 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: newbie question
you need to specify a dependencies for everything; in the case you depend on a jar that's not publicly available (3rd party vendor, in-house jar, etc), you have a few options: -maintain a repository for these sorts of things, using a tool like archiva, nexus, or artifactory (ideal for teams of more than 1) -install it locally http://maven.apache.org/guides/mini/guide-3rd-party-jars-local.html -specify a local location for the JAR, by using "system scope" (not the greatest solution) On Wed, May 26, 2010 at 2:00 PM, Meeusen, Christopher W. < meeusen.christop...@mayo.edu> wrote: > I guess I miss understood the concept of dependencies. I thought that it > was used only for .jars that were in a repository say commons-lang-2.4, but > if you have some api from a vendor, say vendor.jar, that you didn't have to > configure a decency for that. > > -Original Message- > From: > users-return-111621-meeusen.christopher=mayo@maven.apache.org[mailto: > users-return-111621-meeusen.christopher=mayo@maven.apache.org] On > Behalf Of Wayne Fay > Sent: Wednesday, May 26, 2010 12:50 PM > To: Maven Users List > Subject: Re: newbie question > > > Getting a bunch of these. Do I have to configure the compiler plugin > > and explicitly tell it to use the .jars referenced in my build path? > > No configuration of the compiler plugin should be necessary. You simply > need to properly configure your list. > > Most likely you are simply missing one or more dependencies -- looks like > axis2 is the first, but I don't recognize the com.idx one and assume it is > an internal artifact that you're working on. > > Wayne > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re: newbie question
> I guess I miss understood the concept of dependencies. I thought that it > was used only for .jars that were in a repository say commons-lang-2.4, > but if you have some api from a vendor, say vendor.jar, that you didn't have > to configure a decency for that. Yes, this is a misunderstanding on your part. Eventually, everything you depend on needs to be in a repository somewhere for Maven to use it -- either your local repo cache, a corporate repo with limited access to your local dev team, or a public repo like Central. Don't get suckered into thinking you can get around this by using system-scope, that is a guaranteed path to failure. Instead, use install:install-file and deploy:deploy-file. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
RE: newbie question
I guess I miss understood the concept of dependencies. I thought that it was used only for .jars that were in a repository say commons-lang-2.4, but if you have some api from a vendor, say vendor.jar, that you didn't have to configure a decency for that. -Original Message- From: users-return-111621-meeusen.christopher=mayo@maven.apache.org [mailto:users-return-111621-meeusen.christopher=mayo@maven.apache.org] On Behalf Of Wayne Fay Sent: Wednesday, May 26, 2010 12:50 PM To: Maven Users List Subject: Re: newbie question > Getting a bunch of these. Do I have to configure the compiler plugin > and explicitly tell it to use the .jars referenced in my build path? No configuration of the compiler plugin should be necessary. You simply need to properly configure your list. Most likely you are simply missing one or more dependencies -- looks like axis2 is the first, but I don't recognize the com.idx one and assume it is an internal artifact that you're working on. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: newbie question
i totally agree with Wayne, you are missing some dependencies in your pom.xml x.x hope it helps 2010/5/26 Wayne Fay > > Getting a bunch of these. Do I have to configure the compiler > > plugin and explicitly tell it to use the .jars referenced in my build > path? > > No configuration of the compiler plugin should be necessary. You > simply need to properly configure your list. > > Most likely you are simply missing one or more dependencies -- looks > like axis2 is the first, but I don't recognize the com.idx one and > assume it is an internal artifact that you're working on. > > Wayne > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > -- Zayen Fradj Ingénieur Informaticien Sun Certified Programmer
Re: newbie question
> Getting a bunch of these. Do I have to configure the compiler > plugin and explicitly tell it to use the .jars referenced in my build path? No configuration of the compiler plugin should be necessary. You simply need to properly configure your list. Most likely you are simply missing one or more dependencies -- looks like axis2 is the first, but I don't recognize the com.idx one and assume it is an internal artifact that you're working on. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: newbie question
please post your entire POM; you don't have to tell the compiler much, but this just reads like you might be missing dependency blocks On Wed, May 26, 2010 at 1:46 PM, Meeusen, Christopher W. < meeusen.christop...@mayo.edu> wrote: > Yes, that did the trick, now new errors though. > > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile > (default-compile) on project wsaxisM: Compilation failure: Compilation > failure: > C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web > Service\wsaxis2_m\src\main\java\com\gehc\ce\ws\GEHCUtils.java:[5,31] package > org.apache.axis2.context does not exist > > C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web > Service\wsaxis2_m\src\main\java\com\gehc\ce\ws\GEHCUtils.java:[7,33] package > com.idx.carecast.ca.common does not exist > > Getting a bunch of these. Do I have to configure the compiler plugin and > explicitly tell it to use the .jars referenced in my build path? > > Thanks, > Chris > > -Original Message- > From: > users-return-111617-meeusen.christopher=mayo@maven.apache.org[mailto: > users-return-111617-meeusen.christopher=mayo@maven.apache.org] On > Behalf Of fradj zayen > Sent: Wednesday, May 26, 2010 12:37 PM > To: Maven Users List > Subject: Re: newbie question > > hi Chris, > I think you didnt't properly configured the compiler plugin. > below an extract pom.xml file > > > ... > > .. > >maven-compiler-plugin > > 1.5 > 1.5 > > > > > > > Regards > > 2010/5/26 Meeusen, Christopher W. > > > Hi, > > > > > > > > I'm brand new to maven, read through a few books, and built a simple > > maven project to produce a .jar. I've installed the m2ecplipse pugin > > and have got it to work properly on a few simple projects. Now I'm > > having an issue when I try to build a more complex project, which > > requires at least java 1.5 (because it uses enums and other things). > > When I build my project I get a clean build, however when I try to do > > Run As > Maven package I get the following errors in the console: > > > > > > > > [ERROR] Failed to execute goal > > org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile > > (default-compile) on project wsaxisM: Compilation failure: Compilation > > failure: > > > > C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web > > Service\wsaxis2_m\src\main\java\edu\mayo\util\VTInfoType.java:[10,7] > > enums are not supported in -source 1.3 > > > > (use -source 5 or higher to enable enums) > > > > public enum VTInfoType > > > > > > > > I get similar errors for annotations and generics. Anyone know what > > might be going on? Please help a maven newb! > > > > > > > > Thanks, > > > > Chris > > > > > > > -- > Zayen Fradj > Ingénieur Informaticien > Sun Certified Programmer > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re: newbie question
> I get similar errors for annotations and generics. Anyone know what > might be going on? Please help a maven newb! This is documented in the Maven FAQ, directly linked from the Maven homepage on the left side under "About Maven". http://maven.apache.org/general.html#Compiling-J2SE-5 Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
RE: newbie question
Yes, that did the trick, now new errors though. [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile (default-compile) on project wsaxisM: Compilation failure: Compilation failure: C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web Service\wsaxis2_m\src\main\java\com\gehc\ce\ws\GEHCUtils.java:[5,31] package org.apache.axis2.context does not exist C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web Service\wsaxis2_m\src\main\java\com\gehc\ce\ws\GEHCUtils.java:[7,33] package com.idx.carecast.ca.common does not exist Getting a bunch of these. Do I have to configure the compiler plugin and explicitly tell it to use the .jars referenced in my build path? Thanks, Chris -Original Message- From: users-return-111617-meeusen.christopher=mayo@maven.apache.org [mailto:users-return-111617-meeusen.christopher=mayo@maven.apache.org] On Behalf Of fradj zayen Sent: Wednesday, May 26, 2010 12:37 PM To: Maven Users List Subject: Re: newbie question hi Chris, I think you didnt't properly configured the compiler plugin. below an extract pom.xml file ... .. maven-compiler-plugin 1.5 1.5 Regards 2010/5/26 Meeusen, Christopher W. > Hi, > > > > I'm brand new to maven, read through a few books, and built a simple > maven project to produce a .jar. I've installed the m2ecplipse pugin > and have got it to work properly on a few simple projects. Now I'm > having an issue when I try to build a more complex project, which > requires at least java 1.5 (because it uses enums and other things). > When I build my project I get a clean build, however when I try to do > Run As > Maven package I get the following errors in the console: > > > > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile > (default-compile) on project wsaxisM: Compilation failure: Compilation > failure: > > C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web > Service\wsaxis2_m\src\main\java\edu\mayo\util\VTInfoType.java:[10,7] > enums are not supported in -source 1.3 > > (use -source 5 or higher to enable enums) > > public enum VTInfoType > > > > I get similar errors for annotations and generics. Anyone know what > might be going on? Please help a maven newb! > > > > Thanks, > > Chris > > -- Zayen Fradj Ingénieur Informaticien Sun Certified Programmer - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: newbie question
hi Chris, I think you didnt't properly configured the compiler plugin. below an extract pom.xml file ... .. maven-compiler-plugin 1.5 1.5 Regards 2010/5/26 Meeusen, Christopher W. > Hi, > > > > I'm brand new to maven, read through a few books, and built a simple > maven project to produce a .jar. I've installed the m2ecplipse pugin > and have got it to work properly on a few simple projects. Now I'm > having an issue when I try to build a more complex project, which > requires at least java 1.5 (because it uses enums and other things). > When I build my project I get a clean build, however when I try to do > Run As > Maven package I get the following errors in the console: > > > > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile > (default-compile) on project wsaxisM: Compilation failure: Compilation > failure: > > C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web > Service\wsaxis2_m\src\main\java\edu\mayo\util\VTInfoType.java:[10,7] > enums are not supported in -source 1.3 > > (use -source 5 or higher to enable enums) > > public enum VTInfoType > > > > I get similar errors for annotations and generics. Anyone know what > might be going on? Please help a maven newb! > > > > Thanks, > > Chris > > -- Zayen Fradj Ingénieur Informaticien Sun Certified Programmer
newbie question
Hi, I'm brand new to maven, read through a few books, and built a simple maven project to produce a .jar. I've installed the m2ecplipse pugin and have got it to work properly on a few simple projects. Now I'm having an issue when I try to build a more complex project, which requires at least java 1.5 (because it uses enums and other things). When I build my project I get a clean build, however when I try to do Run As > Maven package I get the following errors in the console: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile (default-compile) on project wsaxisM: Compilation failure: Compilation failure: C:\my_clearcase_views\m042872_view\MICS-Team\DIOS\Web Service\wsaxis2_m\src\main\java\edu\mayo\util\VTInfoType.java:[10,7] enums are not supported in -source 1.3 (use -source 5 or higher to enable enums) public enum VTInfoType I get similar errors for annotations and generics. Anyone know what might be going on? Please help a maven newb! Thanks, Chris
Re: Newbie Question
Thanks for the help Baptiste. That didn't work but -Darguments=-Pversion did. Thanks for pointing me in the right direction. Cheers Jeremy Banks Development Team Lead BIS² Level 2 45 Tory Street PO Box 19204 Wellington New Zealand +64 21 686 986 On 23 February 2010 19:31, Baptiste MATHUS wrote: > Hi Jeremy, > > The maven-release-plugin forks to do the release. So I think you have to use > an additional -Dparameters="-Pversion" (See > http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html#arguments > ). > > Be aware I'm not totally sure it will work for profiles since I never needed > it, although I did a lot of releases with this plugin; > > Btw, shouldn't this profile be always on? Is there cases where you don't > want to generate this file? > > Cheers. > > 2010/2/23 Jeremy Banks > >> Hi All >> >> I've picked up a system set up by someone else and there's an aspect >> of it that's not quite working properly, which I was hoping someone >> may be able to help me with. >> >> We're building a flex project using maven. The project has 5 modules. >> >> One of the modules has a profile that uses the maven-antrun-plugin to >> copy a file and then substitute some properties in to it in the >> generate-sources phase. We are using it to insert the pom version and >> an environment variable containing the subversion revision in to a >> file that reports on the version of the software. >> >> The module in question is building an swc which is a dependency in >> some of the other modules. >> >> What's happening is if I run compile or install or deploy in the >> module in question then the file copy and substitution works. If >> however I call the release targets (i.e. "mvn release:prepare >> release:perform -Dresume=false -P version") it doesn't work. >> >> If I look at the release repository for the module itself and open up >> the sources.jar I can verify that the substitution hasn't worked, as >> the source file hasn't been updated. >> >> So I guess my question is that in this case it appears that >> generate-sources isn't being called as part of the release targets, is >> this correct? Any suggestions on how to make what is intended here >> work? >> >> Below is the section of the pom that performs the copy and substitution. >> >> Regards >> >> Jeremy Banks >> >> >> >> version >> >> >> >> maven-antrun-plugin >> >> >> version >> generate-sources >> >> >> > value="${project.basedir}" /> >> >> > value="${env.SVN_REVISION}" /> >> > file="${project_basedir}/src/main/flex/net/.../VersionTemplate._as" >> tofile="${project_basedir}/src/main/flex/net/.../Version.as" >> overwrite="true" /> >> > file="${project_basedir}/src/main/flex/net/.../Version.as" >> token="%SVNVERSION%" value="${svn_revision}" /> >> > file="${project_basedir}/src/main/flex/net/.../Version.as" >> token="%SVNURL%" value="${pom_version}" /> >> >> >> >> run >> >> >> >> >> >> >> >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org >> For additional commands, e-mail: users-h...@maven.apache.org >> >> > > > -- > Baptiste MATHUS - http://batmat.net > Sauvez un arbre, > Mangez un castor ! > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Newbie Question
Hi Jeremy, The maven-release-plugin forks to do the release. So I think you have to use an additional -Dparameters="-Pversion" (See http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html#arguments ). Be aware I'm not totally sure it will work for profiles since I never needed it, although I did a lot of releases with this plugin; Btw, shouldn't this profile be always on? Is there cases where you don't want to generate this file? Cheers. 2010/2/23 Jeremy Banks > Hi All > > I've picked up a system set up by someone else and there's an aspect > of it that's not quite working properly, which I was hoping someone > may be able to help me with. > > We're building a flex project using maven. The project has 5 modules. > > One of the modules has a profile that uses the maven-antrun-plugin to > copy a file and then substitute some properties in to it in the > generate-sources phase. We are using it to insert the pom version and > an environment variable containing the subversion revision in to a > file that reports on the version of the software. > > The module in question is building an swc which is a dependency in > some of the other modules. > > What's happening is if I run compile or install or deploy in the > module in question then the file copy and substitution works. If > however I call the release targets (i.e. "mvn release:prepare > release:perform -Dresume=false -P version") it doesn't work. > > If I look at the release repository for the module itself and open up > the sources.jar I can verify that the substitution hasn't worked, as > the source file hasn't been updated. > > So I guess my question is that in this case it appears that > generate-sources isn't being called as part of the release targets, is > this correct? Any suggestions on how to make what is intended here > work? > > Below is the section of the pom that performs the copy and substitution. > > Regards > > Jeremy Banks > > > > version > > > >maven-antrun-plugin > > >version >generate-sources > > >value="${project.basedir}" /> > > value="${env.SVN_REVISION}" /> > file="${project_basedir}/src/main/flex/net/.../VersionTemplate._as" > tofile="${project_basedir}/src/main/flex/net/.../Version.as" > overwrite="true" /> > file="${project_basedir}/src/main/flex/net/.../Version.as" > token="%SVNVERSION%" value="${svn_revision}" /> > file="${project_basedir}/src/main/flex/net/.../Version.as" > token="%SVNURL%" value="${pom_version}" /> > > > > run > > > > > > > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > -- Baptiste MATHUS - http://batmat.net Sauvez un arbre, Mangez un castor !
Newbie Question
Hi All I've picked up a system set up by someone else and there's an aspect of it that's not quite working properly, which I was hoping someone may be able to help me with. We're building a flex project using maven. The project has 5 modules. One of the modules has a profile that uses the maven-antrun-plugin to copy a file and then substitute some properties in to it in the generate-sources phase. We are using it to insert the pom version and an environment variable containing the subversion revision in to a file that reports on the version of the software. The module in question is building an swc which is a dependency in some of the other modules. What's happening is if I run compile or install or deploy in the module in question then the file copy and substitution works. If however I call the release targets (i.e. "mvn release:prepare release:perform -Dresume=false -P version") it doesn't work. If I look at the release repository for the module itself and open up the sources.jar I can verify that the substitution hasn't worked, as the source file hasn't been updated. So I guess my question is that in this case it appears that generate-sources isn't being called as part of the release targets, is this correct? Any suggestions on how to make what is intended here work? Below is the section of the pom that performs the copy and substitution. Regards Jeremy Banks version maven-antrun-plugin version generate-sources run - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven+netbeans+cpp newbie question
Hi Stephan, Netbeans doesn't work well with Maven and C++ project. We use the nar maven plugin to compile C++ project. Actually, we build from CLI but I use Netbeans for Java too. I think Netbeans doesn't know about "nar" package. So some editor features don't work anymore. For example, the src directory isn't display in project view. I don't know about the other native plugin. Regards, Vincent Hardion Le 26 nov. 2009 à 09:53, stephane ancelot a écrit : Hi, I have got a problem ! I have to use netbeans in multiproject environment. multiproject means I have to generate a package that is composed of many C/C++ applications executable. however, it looks like netbeans does not support well multiproject environment. So, may be using maven will solve this problem ? I would like to know if I can use maven with netbeans in this context, my project structure would be similar to : project1/ project2/ somelib1/ somelibx/ What are necessary customisations in order doing this ? I tried making a pom.xml with native settings, importing it in netbeans but it creates some java files. Inside the IDE , when I add new files to the project, I would like it to be transparent for the user. I do not want him to hack some pom files ...Is it working ? Best Regards Steph - 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: maven+netbeans+cpp newbie question
On Thu, Nov 26, 2009 at 9:53 AM, stephane ancelot wrote: > Hi, > > I have got a problem ! > > I have to use netbeans in multiproject environment. multiproject means I > have to generate a package that is composed of many C/C++ applications > executable. > > however, it looks like netbeans does not support well multiproject > environment. > > So, may be using maven will solve this problem ? > depends. check first whether after using maven you still get most/all of the c++ editor features you get in the C++ projects. The support could be bound exclusively to these and be absent in maven projects.. > > I would like to know if I can use maven with netbeans in this context, my > project structure would be similar to : > > project1/ > project2/ > somelib1/ > somelibx/ > > > What are necessary customisations in order doing this ? > I tried making a pom.xml with native settings, importing it in netbeans > but it creates some java files. > you will need to find maven plugins specific to c++ developement and see from there how the maven project is to be customized. > > Inside the IDE , when I add new files to the project, I would like it to > be transparent for the user. > I do not want him to hack some pom files ...Is it working ? > It should as far as I can tell. Milos > > Best Regards > Steph > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
maven+netbeans+cpp newbie question
Hi, I have got a problem ! I have to use netbeans in multiproject environment. multiproject means I have to generate a package that is composed of many C/C++ applications executable. however, it looks like netbeans does not support well multiproject environment. So, may be using maven will solve this problem ? I would like to know if I can use maven with netbeans in this context, my project structure would be similar to : project1/ project2/ somelib1/ somelibx/ What are necessary customisations in order doing this ? I tried making a pom.xml with native settings, importing it in netbeans but it creates some java files. Inside the IDE , when I add new files to the project, I would like it to be transparent for the user. I do not want him to hack some pom files ...Is it working ? Best Regards Steph - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Newbie question about defining goals
Super thanks !!! UseTheFork -- View this message in context: http://www.nabble.com/Newbie-question-about-defining-goals-tp25428980p25433476.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: Newbie question about defining goals
group p 1.0 p some-unique-id h g UseTheFork wrote: > Hi, > > This is a newbie clarification question. The set of default goals attached > to phases does depend on the packaging setting in the pom.xml. > > Lets imagine that I want to add a goal G from plugin P to execute in phase > H. Let's imagine that this plugin P must be retrieved from a remote > repository R. What do I exactly need to put in my pom.xml? > > Thanks, > > UseTheFork > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Newbie question about defining goals
Hi, This is a newbie clarification question. The set of default goals attached to phases does depend on the packaging setting in the pom.xml. Lets imagine that I want to add a goal G from plugin P to execute in phase H. Let's imagine that this plugin P must be retrieved from a remote repository R. What do I exactly need to put in my pom.xml? Thanks, UseTheFork -- View this message in context: http://www.nabble.com/Newbie-question-about-defining-goals-tp25428980p25428980.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: newbie question about specifying testClassesDirectory
On 02/07/09 21:26, Anders Hammar wrote: The surefire plugin forks by default. Possibly there is a bug in the surefire plugin you're using (and you can't upgrade to the newest one as it requires a newer Maven version than you're using, hence my upgrade recommendation). I'm thinking that the class path isn't correctly passed when forking. You could try turn off the forking by the forkMode configuration: http://maven.apache.org/plugins/maven-surefire-plugin/test-mojo.html#forkMode Hi Anders, Adding the following to the pom.xml allows the tests to run through correctly. org.apache.maven.plugins maven-surefire-plugin never ... Thanks!!! Tom /Anders On Thu, Jul 2, 2009 at 22:07, Tom H wrote: Hi, Thanks for the reply, I've some comments in-lined below; On 02/07/09 20:09, Anders Hammar wrote: Hi, As a starter, you should probably upgrade Maven as version 2.0.4 is VERY old. You can tell from your attached output that there are newer surefire plugin versions that can't be used with Maven 2.0.4. I am pretty much stuck with what's in the fedora11 repos, so I am hoping to fix the problem or send in a bug report... Regarding your problem: Try running with "-X" (debug) instead of "-e" and then check the output. Look for the test classpath and verify that ./target/test-classes/ is included in the path. Just before the ClassNotFoundException it tries to run this; Forking command line: /bin/sh -c "cd /home/tomhodder/eclipse/workspace/simple&& /usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre/bin/java -jar /tmp/surefirebooter4m1yoz.jar /tmp/surefire4m1yoxtmp /tmp/surefire4m1yoytmp" org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; the surefire booter jar only contains this; [tomhod...@localhost simple]$ unzip -t /tmp/surefirebooter4m1yoz.jar Archive: /tmp/surefirebooter4m1yoz.jar testing: META-INF/MANIFEST.MF OK No errors detected in compressed data of /tmp/surefirebooter4m1yoz.jar. And the MANIFEST file contains the correct test-classes path If I strace that fork command it does what looks like find the correct AppTest class, and then gives up; stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 ftruncate(9, 69632) = 0 mmap(NULL, 4096, PROT_READ|PROT_EXEC, MAP_SHARED, 9, 0x1) = 0x7ff109a66000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_SHARED, 9, 0x1) = 0x7ff109a65000 write(2, "org.apache.maven.surefire.booter."..., 500org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; nested exception is java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebooter4m1yoz.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}; nested exception is org.apache.maven.surefire.testset.TestSetFailedException: Unable to create test class 'com.mytutorial.AppTest'; nested exception i) = 500 write(2, "s java.lang.ClassNotFoundExceptio"..., 100s java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassL) = 100 any ideas on that? Tom - 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 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: newbie question about specifying testClassesDirectory
The surefire plugin forks by default. Possibly there is a bug in the surefire plugin you're using (and you can't upgrade to the newest one as it requires a newer Maven version than you're using, hence my upgrade recommendation). I'm thinking that the class path isn't correctly passed when forking. You could try turn off the forking by the forkMode configuration: http://maven.apache.org/plugins/maven-surefire-plugin/test-mojo.html#forkMode /Anders On Thu, Jul 2, 2009 at 22:07, Tom H wrote: > Hi, > > Thanks for the reply, I've some comments in-lined below; > > > On 02/07/09 20:09, Anders Hammar wrote: >> >> Hi, >> >> As a starter, you should probably upgrade Maven as version 2.0.4 is >> VERY old. You can tell from your attached output that there are newer >> surefire plugin versions that can't be used with Maven 2.0.4. >> > > I am pretty much stuck with what's in the fedora11 repos, so I am hoping to > fix the problem or send in a bug report... > >> Regarding your problem: Try running with "-X" (debug) instead of "-e" >> and then check the output. Look for the test classpath and verify that >> ./target/test-classes/ is included in the path. >> > > Just before the ClassNotFoundException it tries to run this; > > Forking command line: /bin/sh -c "cd > /home/tomhodder/eclipse/workspace/simple && > /usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre/bin/java -jar > /tmp/surefirebooter4m1yoz.jar /tmp/surefire4m1yoxtmp /tmp/surefire4m1yoytmp" > org.apache.maven.surefire.booter.SurefireExecutionException: Unable to > create test class 'com.mytutorial.AppTest'; > > the surefire booter jar only contains this; > [tomhod...@localhost simple]$ unzip -t /tmp/surefirebooter4m1yoz.jar > Archive: /tmp/surefirebooter4m1yoz.jar > testing: META-INF/MANIFEST.MF OK > No errors detected in compressed data of /tmp/surefirebooter4m1yoz.jar. > > And the MANIFEST file contains the correct test-classes path > > If I strace that fork command it does what looks like find the correct > AppTest class, and then gives up; > > stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", > {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 > stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", > {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 > ftruncate(9, 69632) = 0 > mmap(NULL, 4096, PROT_READ|PROT_EXEC, MAP_SHARED, 9, 0x1) = > 0x7ff109a66000 > mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_SHARED, 9, 0x1) = > 0x7ff109a65000 > write(2, "org.apache.maven.surefire.booter."..., > 500org.apache.maven.surefire.booter.SurefireExecutionException: Unable to > create test class 'com.mytutorial.AppTest'; nested exception is > java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in > gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebooter4m1yoz.jar], > parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}; nested > exception is org.apache.maven.surefire.testset.TestSetFailedException: > Unable to create test class 'com.mytutorial.AppTest'; nested exception i) = > 500 > write(2, "s java.lang.ClassNotFoundExceptio"..., 100s > java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in > gnu.gcj.runtime.SystemClassL) = 100 > > > > > any ideas on that? > > Tom > > > > - > 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: newbie question about specifying testClassesDirectory
Oh dear, maven seems to be using a different java to my eclipse installation; [t...@localhost simple]$ /usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre/bin/java -version java version "1.5.0" gij (GNU libgcj) version 4.4.0 20090506 (Red Hat 4.4.0-4) Copyright (C) 2007 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. [t...@localhost simple]$ java -version java version "1.6.0_0" OpenJDK Runtime Environment (IcedTea6 1.5) (fedora-22.b16.fc11-x86_64) OpenJDK 64-Bit Server VM (build 14.0-b15, mixed mode) Tom On 02/07/09 21:07, Tom H wrote: Hi, Thanks for the reply, I've some comments in-lined below; On 02/07/09 20:09, Anders Hammar wrote: Hi, As a starter, you should probably upgrade Maven as version 2.0.4 is VERY old. You can tell from your attached output that there are newer surefire plugin versions that can't be used with Maven 2.0.4. I am pretty much stuck with what's in the fedora11 repos, so I am hoping to fix the problem or send in a bug report... Regarding your problem: Try running with "-X" (debug) instead of "-e" and then check the output. Look for the test classpath and verify that ./target/test-classes/ is included in the path. Just before the ClassNotFoundException it tries to run this; Forking command line: /bin/sh -c "cd /home/tomhodder/eclipse/workspace/simple && /usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre/bin/java -jar /tmp/surefirebooter4m1yoz.jar /tmp/surefire4m1yoxtmp /tmp/surefire4m1yoytmp" org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; the surefire booter jar only contains this; [tomhod...@localhost simple]$ unzip -t /tmp/surefirebooter4m1yoz.jar Archive: /tmp/surefirebooter4m1yoz.jar testing: META-INF/MANIFEST.MF OK No errors detected in compressed data of /tmp/surefirebooter4m1yoz.jar. And the MANIFEST file contains the correct test-classes path If I strace that fork command it does what looks like find the correct AppTest class, and then gives up; stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 ftruncate(9, 69632) = 0 mmap(NULL, 4096, PROT_READ|PROT_EXEC, MAP_SHARED, 9, 0x1) = 0x7ff109a66000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_SHARED, 9, 0x1) = 0x7ff109a65000 write(2, "org.apache.maven.surefire.booter."..., 500org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; nested exception is java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebooter4m1yoz.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}; nested exception is org.apache.maven.surefire.testset.TestSetFailedException: Unable to create test class 'com.mytutorial.AppTest'; nested exception i) = 500 write(2, "s java.lang.ClassNotFoundExceptio"..., 100s java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassL) = 100 any ideas on that? Tom - 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: newbie question about specifying testClassesDirectory
Hi, Thanks for the reply, I've some comments in-lined below; On 02/07/09 20:09, Anders Hammar wrote: Hi, As a starter, you should probably upgrade Maven as version 2.0.4 is VERY old. You can tell from your attached output that there are newer surefire plugin versions that can't be used with Maven 2.0.4. I am pretty much stuck with what's in the fedora11 repos, so I am hoping to fix the problem or send in a bug report... Regarding your problem: Try running with "-X" (debug) instead of "-e" and then check the output. Look for the test classpath and verify that ./target/test-classes/ is included in the path. Just before the ClassNotFoundException it tries to run this; Forking command line: /bin/sh -c "cd /home/tomhodder/eclipse/workspace/simple && /usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre/bin/java -jar /tmp/surefirebooter4m1yoz.jar /tmp/surefire4m1yoxtmp /tmp/surefire4m1yoytmp" org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; the surefire booter jar only contains this; [tomhod...@localhost simple]$ unzip -t /tmp/surefirebooter4m1yoz.jar Archive: /tmp/surefirebooter4m1yoz.jar testing: META-INF/MANIFEST.MF OK No errors detected in compressed data of /tmp/surefirebooter4m1yoz.jar. And the MANIFEST file contains the correct test-classes path If I strace that fork command it does what looks like find the correct AppTest class, and then gives up; stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 stat("/home/tomhodder/eclipse/workspace/simple/target/test-classes/com/mytutorial/AppTest.class", {st_mode=S_IFREG|0664, st_size=1006, ...}) = 0 ftruncate(9, 69632) = 0 mmap(NULL, 4096, PROT_READ|PROT_EXEC, MAP_SHARED, 9, 0x1) = 0x7ff109a66000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_SHARED, 9, 0x1) = 0x7ff109a65000 write(2, "org.apache.maven.surefire.booter."..., 500org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; nested exception is java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebooter4m1yoz.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}; nested exception is org.apache.maven.surefire.testset.TestSetFailedException: Unable to create test class 'com.mytutorial.AppTest'; nested exception i) = 500 write(2, "s java.lang.ClassNotFoundExceptio"..., 100s java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassL) = 100 any ideas on that? Tom - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: newbie question about specifying testClassesDirectory
Hi, As a starter, you should probably upgrade Maven as version 2.0.4 is VERY old. You can tell from your attached output that there are newer surefire plugin versions that can't be used with Maven 2.0.4. Regarding your problem: Try running with "-X" (debug) instead of "-e" and then check the output. Look for the test classpath and verify that ./target/test-classes/ is included in the path. /Anders On Thu, Jul 2, 2009 at 18:44, Tom H wrote: > > Hi, > > I am new to maven (about 2 hours in), and I am working through a tutorial > that I download here; > http://www.lulu.com/content/1080910 > I can run the "Hello world" app under eclipse. > > However I am having a problem that when I run ; > > $ mvn -e clean package > > I get an error; > org.apache.maven.surefire.booter.SurefireExecutionException: Unable to > create test class 'com.mytutorial.AppTest'; > > Now, the "com.mytutorial.AppTest" class has been created in the > "./target/test-classes/" folder, so I guess that either there is something > wrong with the test class, which seems to compile ok; > [INFO] Compiling 1 source file to > /home/tomh/eclipse/workspace/simple/target/test-classes > > or that the surefire:test cannot find the test-classes folder with the test > class. > > Any ideas? > > Thanks, > > Tom > > Fedora11 x86_64 > $ mvn -version > /usr/lib/jvm/java > Maven version: 2.0.4 > $ java -version > java version "1.6.0_0" > OpenJDK Runtime Environment (IcedTea6 1.5) (fedora-22.b16.fc11-x86_64) > OpenJDK 64-Bit Server VM (build 14.0-b15, mixed mode) > eclipse-platform-3.4.2-9.fc11.x86_64 > > > > > [tomhod...@localhost simple]$ mvn -e clean package > /usr/lib/jvm/java > + Error stacktraces are turned on. > [INFO] Scanning for projects... > [INFO] > > [INFO] Building simple > [INFO] task-segment: [clean, package] > [INFO] > > [INFO] Ignoring available plugin update: 2.3 as it requires Maven version > 2.0.6 > [INFO] [clean:clean] > [INFO] Deleting directory /home/tomh/eclipse/workspace/simple/target > [INFO] Ignoring available plugin update: 2.3 as it requires Maven version > 2.0.6 > [INFO] Ignoring available plugin update: 2.4.3 as it requires Maven version > 2.0.6 > [INFO] Ignoring available plugin update: 2.2 as it requires Maven version > 2.0.6 > [INFO] [resources:resources] > [INFO] Using default encoding to copy filtered resources. > [INFO] [compiler:compile] > [INFO] Compiling 1 source file to > /home/tomh/eclipse/workspace/simple/target/classes > [INFO] [resources:testResources] > [INFO] Using default encoding to copy filtered resources. > [INFO] [compiler:testCompile] > [INFO] Compiling 1 source file to > /home/tomh/eclipse/workspace/simple/target/test-classes > [INFO] [surefire:test] > [INFO] Surefire report directory: > /home/tomh/eclipse/workspace/simple/target/surefire-reports > org.apache.maven.surefire.booter.SurefireExecutionException: Unable to > create test class 'com.mytutorial.AppTest'; nested exception is > java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in > gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], > parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}; nested > exception is org.apache.maven.surefire.testset.TestSetFailedException: > Unable to create test class 'com.mytutorial.AppTest'; nested exception is > java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in > gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], > parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}} > org.apache.maven.surefire.testset.TestSetFailedException: Unable to create > test class 'com.mytutorial.AppTest'; nested exception is > java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in > gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], > parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}} > java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in > gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], > parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}} > at java.net.URLClassLoader.findClass(libgcj.so.10) > at java.lang.ClassLoader.loadClass(libgcj.so.10) > at java.lang.ClassLoader.loadClass(libgcj.so.10) > at > org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.locateTestSets(AbstractDirectoryTestSuite.java:87) > at > org.apache.maven.surefire.Surefire.createSuiteFromDefinition(Surefire.java:209) > at org.apache.maven.surefire.Surefire.run(Surefire.java:156) > at java.lang.reflect.Method.invoke(libgcj.so.10) > at > org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:338) > at > org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:997) > [INFO] >
newbie question about specifying testClassesDirectory
Hi, I am new to maven (about 2 hours in), and I am working through a tutorial that I download here; http://www.lulu.com/content/1080910 I can run the "Hello world" app under eclipse. However I am having a problem that when I run ; $ mvn -e clean package I get an error; org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; Now, the "com.mytutorial.AppTest" class has been created in the "./target/test-classes/" folder, so I guess that either there is something wrong with the test class, which seems to compile ok; [INFO] Compiling 1 source file to /home/tomh/eclipse/workspace/simple/target/test-classes or that the surefire:test cannot find the test-classes folder with the test class. Any ideas? Thanks, Tom Fedora11 x86_64 $ mvn -version /usr/lib/jvm/java Maven version: 2.0.4 $ java -version java version "1.6.0_0" OpenJDK Runtime Environment (IcedTea6 1.5) (fedora-22.b16.fc11-x86_64) OpenJDK 64-Bit Server VM (build 14.0-b15, mixed mode) eclipse-platform-3.4.2-9.fc11.x86_64 [tomhod...@localhost simple]$ mvn -e clean package /usr/lib/jvm/java + Error stacktraces are turned on. [INFO] Scanning for projects... [INFO] [INFO] Building simple [INFO]task-segment: [clean, package] [INFO] [INFO] Ignoring available plugin update: 2.3 as it requires Maven version 2.0.6 [INFO] [clean:clean] [INFO] Deleting directory /home/tomh/eclipse/workspace/simple/target [INFO] Ignoring available plugin update: 2.3 as it requires Maven version 2.0.6 [INFO] Ignoring available plugin update: 2.4.3 as it requires Maven version 2.0.6 [INFO] Ignoring available plugin update: 2.2 as it requires Maven version 2.0.6 [INFO] [resources:resources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:compile] [INFO] Compiling 1 source file to /home/tomh/eclipse/workspace/simple/target/classes [INFO] [resources:testResources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:testCompile] [INFO] Compiling 1 source file to /home/tomh/eclipse/workspace/simple/target/test-classes [INFO] [surefire:test] [INFO] Surefire report directory: /home/tomh/eclipse/workspace/simple/target/surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: Unable to create test class 'com.mytutorial.AppTest'; nested exception is java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}; nested exception is org.apache.maven.surefire.testset.TestSetFailedException: Unable to create test class 'com.mytutorial.AppTest'; nested exception is java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}} org.apache.maven.surefire.testset.TestSetFailedException: Unable to create test class 'com.mytutorial.AppTest'; nested exception is java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}} java.lang.ClassNotFoundException: com.mytutorial.AppTest not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/tmp/surefirebootern98x3v.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}} at java.net.URLClassLoader.findClass(libgcj.so.10) at java.lang.ClassLoader.loadClass(libgcj.so.10) at java.lang.ClassLoader.loadClass(libgcj.so.10) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.locateTestSets(AbstractDirectoryTestSuite.java:87) at org.apache.maven.surefire.Surefire.createSuiteFromDefinition(Surefire.java:209) at org.apache.maven.surefire.Surefire.run(Surefire.java:156) at java.lang.reflect.Method.invoke(libgcj.so.10) at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:338) at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:997) [INFO] [ERROR] BUILD FAILURE [INFO] [INFO] There are test failures. Please refer to /home/tomh/eclipse/workspace/simple/target/surefire-reports for the individual test results. [INFO] [INFO] Trace org.apache.maven.BuildFailureException: There are test failures. Please refer to /home/tomh/eclipse/workspace/simple/target/surefire-reports for the individual test results. at org.apache.maven.lifecycle.DefaultLifecycle
Re: Newbie question - Resuming lifecycles
On Fri, Jun 26, 2009 at 10:48 PM, alexischr wrote: > > Hello everyone, > > My team has been evaluating Maven as a solution for a data-processing > pipeline. I've created a prototype of what our project would look like, and > it includes a Mojo plug-in and a custom default lifecycle. > > My question regards resuming failed runs: If a goal inside the plugin throws > an exception and fails, will the entire lifecycle be repeated when I > re-execute the lifecycle? Will it know not to execute previous successful > goals, or do I need to design each goal so that it checks if its output > already exist? Maven will *re-run* the lifecyle. Any goals that successfully worked before the exception was thrown will be re-run. It is therefore important to ensure those goals have some sort of smarts to avoid regenerating artifacts that do not need it. i.e. timestamp checking, etc. > Please keep in mind that I'm using a custom packaging/lifecycle, if it makes > a difference. Resume is an important function in our case, since the > pipeline has many fail points out of our control, and some goals can take > days to execute. Have a look at the release plugin, especially the prepare goal. This plugin manages its own "lifecycle" stages within that goal. They are not real maven lifecycles but rather resumable steps of the prepare goal. You may be able to leverage of that knowledge to allow you to build your mojo in a similar manner. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Newbie question - Resuming lifecycles
Hello everyone, My team has been evaluating Maven as a solution for a data-processing pipeline. I've created a prototype of what our project would look like, and it includes a Mojo plug-in and a custom default lifecycle. My question regards resuming failed runs: If a goal inside the plugin throws an exception and fails, will the entire lifecycle be repeated when I re-execute the lifecycle? Will it know not to execute previous successful goals, or do I need to design each goal so that it checks if its output already exist? Please keep in mind that I'm using a custom packaging/lifecycle, if it makes a difference. Resume is an important function in our case, since the pipeline has many fail points out of our control, and some goals can take days to execute. Thank you! -- View this message in context: http://www.nabble.com/Newbie-question---Resuming-lifecycles-tp24220125p24220125.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
Newbie question about site
What is the best way for a site to inherit not only the site.xml from its parent but also the /src/site/resources from the parent too? I'd like to be able to share images across projects but when I run mvn site on my child projects I do not get the /src/site/resources from the parent. Is this even possible? - This e-mail message may contain privileged and/or confidential information, and is intended to be received only by persons entitled to receive such information. If you have received this e-mail in error, please notify the sender immediately. Please delete it and all attachments from any servers, hard drives or any other media. Other use of this e-mail by you is strictly prohibited. All e-mails and attachments sent and received are subject to monitoring, reading and archival by Monsanto, including its subsidiaries. The recipient of this e-mail is solely responsible for checking for the presence of "Viruses" or other "Malware". Monsanto, along with its subsidiaries, accepts no liability for any damage caused by any such code transmitted by or accompanying this e-mail or any attachment. - - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Newbie Question: Dependencies among Sibling Projects?
Wayne Fay wrote: > >> It seems that I need to "install" librarya before libraryb will compile. > > This is correct. Unless you are running "mvn compile" from the top > parent/aggregation pom. > I am running "mvn compile" from the top aggregation pom and I still get the dependency failure. I'm using a super simple dummy project setup to test this... Is this behavior documented anywhere? Wayne Fay wrote: > > Yes, but make sure you are using x.y.z-SNAPSHOT until you ready to > freeze a version number. In the Maven world (and its a good policy in > general), there is only ONE true artifact for a given > groupId/artifactId/version (GAV) combination. > That makes perfect. There should only be one true build of a released version, but development snapshots are moving targets. Is Maven treating the text "SNAPSHOT" as a special-case in the version string? Is this behavior documented? Thanks so much for the response! -- View this message in context: http://n2.nabble.com/Newbie-Question%3A-Dependencies-among-Sibling-Projects--tp2477109p2484210.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: Newbie Question: Dependencies among Sibling Projects?
> It seems that I need to "install" librarya before libraryb will compile. This is correct. Unless you are running "mvn compile" from the top parent/aggregation pom. > Is there any way to define dependencies among sibling projects like this > (that are part of the same aggregation group) so that they do not need to be > individually installed (preferably not installed at all) and Maven can > auto-detect dependencies and properly build/rebuild? Yes, if you run compile from the top parent. > Also, during development, I do not update the version tag during every > single build/debug cycle. Will Maven properly detect source changes, rebuild > necessary libraries, and update the local repository? Yes, but make sure you are using x.y.z-SNAPSHOT until you ready to freeze a version number. In the Maven world (and its a good policy in general), there is only ONE true artifact for a given groupId/artifactId/version (GAV) combination. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Newbie Question: Dependencies among Sibling Projects?
I have a software project that is roughly organized like this: master (aggregation project) librarya libraryb (depends on librarya) It seems that I need to "install" librarya before libraryb will compile. Is there any way to define dependencies among sibling projects like this (that are part of the same aggregation group) so that they do not need to be individually installed (preferably not installed at all) and Maven can auto-detect dependencies and properly build/rebuild? Also, during development, I do not update the version tag during every single build/debug cycle. Will Maven properly detect source changes, rebuild necessary libraries, and update the local repository? -- View this message in context: http://n2.nabble.com/Newbie-Question%3A-Dependencies-among-Sibling-Projects--tp2477109p2477109.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: newbie question - creating web projects
Best practices with Maven would suggest that you not embed the Java files in the Web project. Rather, you should create a standard jar project, put the Java files there, and then put a in the Web project so that Jar file is brought in when the War is created. Alternatively, you can simply create the src/main/java directory yourself. The webapp archetype does not create this directory as it does not comply with best practices, but there's nothing stopping you from doing so. I'd suggest reading more about creating J2EE projects with Maven in "Better Builds with Maven" and other online resources. Wayne On 7/18/08, snakelocks <[EMAIL PROTECTED]> wrote: > > When I create a web project using: > mvn archetype:create \ >-DarchetypeGroupId=org.apache.maven.archetypes \ >-DarchetypeArtifactId=maven-archetype-webapp \ >-DgroupId=com.mycompany.app \ >-DartifactId=my-webapp > > I do not get the src/main/java folder created. > > But I do get this created when I create a 'regular' project using: > mvn archetype:create \ > -DarchetypeGroupId=org.apache.maven.archetypes \ > -DgroupId=com.mycompany.app \ > -DartifactId=my-app > But then, of course, I don't get me src/main/resources and src/main/webapp > etc. > > How do I create a web project AND have a src/main/java created as a base > from which to develop? > -- > View this message in context: > http://www.nabble.com/newbie-question---creating-web-projects-tp18530489p18530489.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
newbie question - creating web projects
When I create a web project using: mvn archetype:create \ -DarchetypeGroupId=org.apache.maven.archetypes \ -DarchetypeArtifactId=maven-archetype-webapp \ -DgroupId=com.mycompany.app \ -DartifactId=my-webapp I do not get the src/main/java folder created. But I do get this created when I create a 'regular' project using: mvn archetype:create \ -DarchetypeGroupId=org.apache.maven.archetypes \ -DgroupId=com.mycompany.app \ -DartifactId=my-app But then, of course, I don't get me src/main/resources and src/main/webapp etc. How do I create a web project AND have a src/main/java created as a base from which to develop? -- View this message in context: http://www.nabble.com/newbie-question---creating-web-projects-tp18530489p18530489.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Maven newbie question
Thanks Richard!!! -Original Message- From: Richard Chamberlain [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 21, 2008 11:06 AM To: Maven Users List Subject: RE: Maven newbie question I'm not sure what you're getting at here: 1) you got some source code that you have checked out from CVS that you want imported into a maven project? You'll have to do this manually. Create the example maven project using an archetype and moved your source code into it 2) you've got a maven project that you've checked out and want to import it into eclipse? Use file > import > general > maven project when using m2eclipse Or Run mvn eclipse:eclipse to generate a maven project 3) I've not understood you correctly! :) Rich -Original Message- From: King, Leon C [mailto:[EMAIL PROTECTED] Sent: 21 May 2008 15:55 To: users@maven.apache.org Subject: Maven newbie question Hi All, I have a question regarding the use of cvs and maven. I'm converting from Ant builds to maven. All of my source code is currently checked into a CVS repository.How do I create a Maven project using code checked out from cvs? Are there any examples using m2eclipse? Thanks, Leon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Maven newbie question
I'm not sure what you're getting at here: 1) you got some source code that you have checked out from CVS that you want imported into a maven project? You'll have to do this manually. Create the example maven project using an archetype and moved your source code into it 2) you've got a maven project that you've checked out and want to import it into eclipse? Use file > import > general > maven project when using m2eclipse Or Run mvn eclipse:eclipse to generate a maven project 3) I've not understood you correctly! :) Rich -Original Message- From: King, Leon C [mailto:[EMAIL PROTECTED] Sent: 21 May 2008 15:55 To: users@maven.apache.org Subject: Maven newbie question Hi All, I have a question regarding the use of cvs and maven. I'm converting from Ant builds to maven. All of my source code is currently checked into a CVS repository.How do I create a Maven project using code checked out from cvs? Are there any examples using m2eclipse? Thanks, Leon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Maven Newbie Question
Hi All, I have a question regarding the use of cvs and maven. I'm converting from Ant builds to maven. All of my source code is currently checked into a CVS repository.How do I create a Maven project using code checked out from cvs? Are there any examples using m2eclipse? Thanks, Leon
Maven newbie question
Hi All, I have a question regarding the use of cvs and maven. I'm converting from Ant builds to maven. All of my source code is currently checked into a CVS repository.How do I create a Maven project using code checked out from cvs? Are there any examples using m2eclipse? Thanks, Leon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: cocoon / maven 2 newbie question ...
BWS wrote: > I exported JAVA_HOME and viola that did the trick very simply. > I thought It had to be in the pom.xml file. It can't because the pom.xml is read my maven which itself needs java... Jan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: cocoon / maven 2 newbie question ...
thanks Simon, javac in the path so? ...anyway. I exported JAVA_HOME and viola that did the trick very simply. I thought It had to be in the pom.xml file. thanks again On Thu, 2008-03-13 at 21:42 +0100, simon wrote: > On Fri, 2008-03-14 at 21:02 -0800, BWS wrote: > > hello, > > > > I'm going through a cocoon tutorial but this is a maven question. > > http://cocoon.apache.org/2.2/1159_1_1.html > > > > jdk1.6 and Maven 2 / fedora8 > > > > I've read through a ton of issues with this error. > > "Failure executing javac, but could not parse the error:" > > when using jdk 1.4 and switching to 1.5 but nothing about > > my situation. > > > > I'm trying to compile a cocoon app. I'm in "myBlock1" and run: > > mvn jetty:run > > or > > mvn compile > > > > it can't find javac because it looks like it's looking in ... > > /usr/lib/jvm/java which points to a simlink-> /etc/alternatives/java_sdk > > > > I had to use this to configure java on this os. > > SO MY QUESTION IS :: > > > > Where in the POM.XML can I include a path to "/usr/java/jdk1.6.0_02" > > /etc/alternatives/java_sdk is pointing there but that's the only thing I > > can think of that is screwing this up so I can compile it. > > You can't set a path to the JDK in the pom.xml. The pom.xml is what gets > published to other people (via the repository), so having paths to jdks > on your machine would not be useful. > > Try > export JAVA_HOME=/path/to/your/jdk > mvn jetty:run > > Regards, > Simon > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: cocoon / maven 2 newbie question ...
On Fri, 2008-03-14 at 21:02 -0800, BWS wrote: > hello, > > I'm going through a cocoon tutorial but this is a maven question. > http://cocoon.apache.org/2.2/1159_1_1.html > > jdk1.6 and Maven 2 / fedora8 > > I've read through a ton of issues with this error. > "Failure executing javac, but could not parse the error:" > when using jdk 1.4 and switching to 1.5 but nothing about > my situation. > > I'm trying to compile a cocoon app. I'm in "myBlock1" and run: > mvn jetty:run > or > mvn compile > > it can't find javac because it looks like it's looking in ... > /usr/lib/jvm/java which points to a simlink-> /etc/alternatives/java_sdk > > I had to use this to configure java on this os. > SO MY QUESTION IS :: > > Where in the POM.XML can I include a path to "/usr/java/jdk1.6.0_02" > /etc/alternatives/java_sdk is pointing there but that's the only thing I > can think of that is screwing this up so I can compile it. You can't set a path to the JDK in the pom.xml. The pom.xml is what gets published to other people (via the repository), so having paths to jdks on your machine would not be useful. Try export JAVA_HOME=/path/to/your/jdk mvn jetty:run Regards, Simon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: cocoon / maven 2 newbie question ...
You must be able to successfully run "javac" from your command line before attempting to execute "mvn". Make sure JAVA_HOME is set and that it is in your PATH. Symlinks should not matter. Wayne On 3/15/08, BWS <[EMAIL PROTECTED]> wrote: > hello, > > I'm going through a cocoon tutorial but this is a maven question. > http://cocoon.apache.org/2.2/1159_1_1.html > > jdk1.6 and Maven 2 / fedora8 > > I've read through a ton of issues with this error. > "Failure executing javac, but could not parse the error:" > when using jdk 1.4 and switching to 1.5 but nothing about > my situation. > > I'm trying to compile a cocoon app. I'm in "myBlock1" and run: > mvn jetty:run > or > mvn compile > > it can't find javac because it looks like it's looking in ... > /usr/lib/jvm/java which points to a simlink-> /etc/alternatives/java_sdk > > I had to use this to configure java on this os. > SO MY QUESTION IS :: > > Where in the POM.XML can I include a path to "/usr/java/jdk1.6.0_02" > /etc/alternatives/java_sdk is pointing there but that's the only thing I > can think of that is screwing this up so I can compile it. > > > thanx:) > if this should be on the cocoon list I'm sorry I posted it here. > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cocoon / maven 2 newbie question ...
hello, I'm going through a cocoon tutorial but this is a maven question. http://cocoon.apache.org/2.2/1159_1_1.html jdk1.6 and Maven 2 / fedora8 I've read through a ton of issues with this error. "Failure executing javac, but could not parse the error:" when using jdk 1.4 and switching to 1.5 but nothing about my situation. I'm trying to compile a cocoon app. I'm in "myBlock1" and run: mvn jetty:run or mvn compile it can't find javac because it looks like it's looking in ... /usr/lib/jvm/java which points to a simlink-> /etc/alternatives/java_sdk I had to use this to configure java on this os. SO MY QUESTION IS :: Where in the POM.XML can I include a path to "/usr/java/jdk1.6.0_02" /etc/alternatives/java_sdk is pointing there but that's the only thing I can think of that is screwing this up so I can compile it. thanx:) if this should be on the cocoon list I'm sorry I posted it here. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Maven1 Project.xml. Does it have a DTD? Newbie question
The maven 1 pom is explained here [1] and there is an xsd available there [2]. As you see, id is not a valid tag for a contributor (the developer id is an scm id, so it's pointless for a contributor), and contrary to m1.0, the parser in maven 1.1 enforces the rules. HTH, -Lukas [1] http://maven.apache.org/maven-1.x/reference/maven-model/3.0.2/maven.html [2] http://maven.apache.org/maven-v3_0_0.xsd JG Flowers wrote: Hi folks, I'm using Maven 1 to look at XDoclet. It falls over with an error parsing an id node in the contributor section C:\Tools\XDoclet\xdoclet-all\xdoclet\project.xml' [exec] >> ParseError at [row,col]:[295,17] [exec] Message: Unrecognised tag: 'id' So it begs the question is there a DTD for project.xml files or something of this nature There is this weird DOCTYPE at top of document ]> And it says is 3.. Can someone point me to a guide that explains this stuff. Cheers. BTW: I'm using Maven 1.1 Here is snippet that's failing Alon Salant Andreas "Mad" Schaefer schaefera [EMAIL PROTECTED] JBossGroup - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Maven1 Project.xml. Does it have a DTD? Newbie question
Hi folks, I'm using Maven 1 to look at XDoclet. It falls over with an error parsing an id node in the contributor section C:\Tools\XDoclet\xdoclet-all\xdoclet\project.xml' [exec] >> ParseError at [row,col]:[295,17] [exec] Message: Unrecognised tag: 'id' So it begs the question is there a DTD for project.xml files or something of this nature There is this weird DOCTYPE at top of document ]> And it says is 3.. Can someone point me to a guide that explains this stuff. Cheers. -- View this message in context: http://www.nabble.com/Maven1-Project.xml.-Does-it-have-a-DTD--Newbie-question-tp16012546s177p16012546.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie Question. Handling the module dependencies
You just declare the dependency in the pom.xml file as any other dependency. Wayne On 3/5/08, krishnan.1000 <[EMAIL PROTECTED]> wrote: > > Hi Wayne, > > Suppose, I have a situation where foo-utils is a dependency on some other > project not under the foo directory. What can I do to add the dependency in > the pom.xml > > Thanks, > > Karthik > > Wayne Fay wrote: > > > > If you want to have both modules built when you change code in one, > > you must build from the parent (which in your case seems to be foo). > > > > foo > > --foo-utils > > --foo-core > > > > There is no other option. > > > > Wayne > > > > On 3/5/08, krishnan.1000 <[EMAIL PROTECTED]> wrote: > >> > >> Hi, > >> > >> I am working on a project which has two modules on the same hierarchy > >> level > >> foo-utils and foo-core. The foo-core has a dependency on foo-util. If I > >> try > >> to change something in foo-util, I have to build foo-util before I build > >> foo-core. I would like to avoid that by having foo-util built before > >> foo-core is when mvn compile is executed in foo-core directory. I have > >> seen > >> posts where the dependent modules > >> > >> Is there a better way to handle dependencies. In my foo-core pom.xml, > >> this > >> is what I have. > >> > >> > >> > >> > >> foo > >> foo-utils > >> ${project.version} > >> compile > >> > >> > >> > >> Is there anything else that I can do otherwise? > >> > >> Thanks, > >> > >> Karthik > >> -- > >> View this message in context: > >> http://www.nabble.com/Newbie-Question.-Handling-the-module-dependencies-tp15855637s177p15855637.html > >> Sent from the Maven - Users mailing list archive at Nabble.com. > >> > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > -- > View this message in context: > http://www.nabble.com/Newbie-Question.-Handling-the-module-dependencies-tp15855637s177p15860640.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie Question. Handling the module dependencies
Hi Wayne, Suppose, I have a situation where foo-utils is a dependency on some other project not under the foo directory. What can I do to add the dependency in the pom.xml Thanks, Karthik Wayne Fay wrote: > > If you want to have both modules built when you change code in one, > you must build from the parent (which in your case seems to be foo). > > foo > --foo-utils > --foo-core > > There is no other option. > > Wayne > > On 3/5/08, krishnan.1000 <[EMAIL PROTECTED]> wrote: >> >> Hi, >> >> I am working on a project which has two modules on the same hierarchy >> level >> foo-utils and foo-core. The foo-core has a dependency on foo-util. If I >> try >> to change something in foo-util, I have to build foo-util before I build >> foo-core. I would like to avoid that by having foo-util built before >> foo-core is when mvn compile is executed in foo-core directory. I have >> seen >> posts where the dependent modules >> >> Is there a better way to handle dependencies. In my foo-core pom.xml, >> this >> is what I have. >> >> >> >> >> foo >> foo-utils >> ${project.version} >> compile >> >> >> >> Is there anything else that I can do otherwise? >> >> Thanks, >> >> Karthik >> -- >> View this message in context: >> http://www.nabble.com/Newbie-Question.-Handling-the-module-dependencies-tp15855637s177p15855637.html >> Sent from the Maven - Users mailing list archive at Nabble.com. >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Newbie-Question.-Handling-the-module-dependencies-tp15855637s177p15860640.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie Question. Handling the module dependencies
If you want to have both modules built when you change code in one, you must build from the parent (which in your case seems to be foo). foo --foo-utils --foo-core There is no other option. Wayne On 3/5/08, krishnan.1000 <[EMAIL PROTECTED]> wrote: > > Hi, > > I am working on a project which has two modules on the same hierarchy level > foo-utils and foo-core. The foo-core has a dependency on foo-util. If I try > to change something in foo-util, I have to build foo-util before I build > foo-core. I would like to avoid that by having foo-util built before > foo-core is when mvn compile is executed in foo-core directory. I have seen > posts where the dependent modules > > Is there a better way to handle dependencies. In my foo-core pom.xml, this > is what I have. > > > > > foo > foo-utils > ${project.version} > compile > > > > Is there anything else that I can do otherwise? > > Thanks, > > Karthik > -- > View this message in context: > http://www.nabble.com/Newbie-Question.-Handling-the-module-dependencies-tp15855637s177p15855637.html > Sent from the Maven - Users mailing list archive at Nabble.com. > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie Question. Handling the module dependencies
Hi, I am working on a project which has two modules on the same hierarchy level foo-utils and foo-core. The foo-core has a dependency on foo-util. If I try to change something in foo-util, I have to build foo-util before I build foo-core. I would like to avoid that by having foo-util built before foo-core is when mvn compile is executed in foo-core directory. I have seen posts where the dependent modules Is there a better way to handle dependencies. In my foo-core pom.xml, this is what I have. foo foo-utils ${project.version} compile Is there anything else that I can do otherwise? Thanks, Karthik -- View this message in context: http://www.nabble.com/Newbie-Question.-Handling-the-module-dependencies-tp15855637s177p15855637.html Sent from the Maven - Users mailing list archive at Nabble.com.
RE: Local Maven repository. Newbie question...
Hi JG, You should use a real operating system :-) All that stuff about creating a settings.xml file is optional "advanced" stuff. By the time you need to create that file you should already have run maven quite a few times, so the .m2 directory will already exist. Well, unless you are behind a corporate firewall that blocks port 80.. Unfortunately with many technical subjects there is no perfect order to present information. There are "circular dependencies" between topics. There is also the need to keep people interested by giving them info they need, rather than starting with the absolute basics. Imagine a maths textbook that started with number theory rather than basic arithmetic. No schoolkid would ever learn to add.. Regards, Simon On Tue, 2008-02-12 at 11:04 -0800, JG Flowers wrote: > Argh!!! It's a Windows Explorer thing.. :-U > Can name a directory with . prefix with md from command prompt... > Still directory has no repositoty in it. But reading on a bit further it > talks about creating a settings.xml file. > I think it's a chicken or egg thing. In writing the book they talk about > things in chapter 1 than get covered for first time in chapter 2... %-| > Cheers for reply, Jeremy > > > Allen, Daniel wrote: > > > > Not saying for sure that this is what's going on, but in my experience > > it seems like XP only makes that complaint if *you* try to name a folder > > that, while automated processes can get away with it. That is, the check > > is only part of the UI, not an actual file system rule. I'm developing > > on XP, and my local repository cache is in C:\Docs & > > Settings\username\.m2 as usual, and in fact I have several other apps > > born on Unix that name directories with a leading dot. > > > > You mileage may vary, though; I'm on a fancy corporate network set up to > > share drives between Unix systems and Windows desktops, so maybe IT did > > something magical that they never told me about to make this possible. > > Try to run Maven, and see if it autocreates the directory. > > > > ~Dan Allen > > > > -Original Message- > > From: JG Flowers [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, February 12, 2008 1:32 PM > > To: users@maven.apache.org > > Subject: Local Maven repository. Newbie question... > > > > > > Reading Better Builds with Maven. from Devzuz > > It says on page 32 "When you install and run Maven for the first time, > > it > > will create your local repository and populate it > > with artifacts as a result of dependency requests. By default, Maven > > creates > > your local repository in > > /.m2/repository. You must have a local repository in order > > for > > Maven to work." > > > > Now I'm using XP and I'm assuming will be substituted with > > %USERPROFILE% environment variable. > > But on XP you can't have a directory named ".m2", XP groans and says you > > must have a file name, for it thinks you are just specifying an > > extension. > > > > Have done the install. When I run mvn --version it says everything's ok. > > So > > where is my repository? > > The last thing booksays is you must have local repository for Maven to > > work. > > Confused.. You bet :confused: > > Any > > -- > > View this message in context: > > http://www.nabble.com/Local-Maven-repository.-Newbie-question...-tp15439 > > 648s177p15439648.html > > Sent from the Maven - Users mailing list archive at Nabble.com. > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > -- > > This message may contain confidential, proprietary, or legally privileged > > information. No confidentiality or privilege is waived by any transmission > > to an unintended recipient. If you are not an intended recipient, please > > notify the sender and delete this message immediately. Any views expressed > > in this message are those of the sender, not those of any entity within > > the KBC Financial Products group of companies (together referred to as > > "KBC FP"). > > > > This message does not create any obligation, contractual or otherwise, on > > the part of KBC FP. It is not an offer (or solicitation of an offer) of, > > or a recommendation to buy or sell, any financial product. Any prices or > > other values included in this message are indicative only, and do not > > nec
RE: Local Maven repository. Newbie question...
I'm not sure what's going on... The first time I ran maven 2, it autocreated both the .m2/repository directory and the .m2/settings.xml file. Both empty, but just present is sufficient if nothing needs to be in them yet. Have you tried to run Maven and found that it crashes? Or are you just reading the documents right now? (In the latter case, yeah, I had better luck skimming them for basic ideas and then reading newsgroup posts and doing trial and error to figure out the details for myself.) ~DVA -Original Message- From: JG Flowers [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 12, 2008 2:05 PM To: users@maven.apache.org Subject: RE: Local Maven repository. Newbie question... Argh!!! It's a Windows Explorer thing.. :-U Can name a directory with . prefix with md from command prompt... Still directory has no repositoty in it. But reading on a bit further it talks about creating a settings.xml file. I think it's a chicken or egg thing. In writing the book they talk about things in chapter 1 than get covered for first time in chapter 2... %-| Cheers for reply, Jeremy Allen, Daniel wrote: > > Not saying for sure that this is what's going on, but in my experience > it seems like XP only makes that complaint if *you* try to name a folder > that, while automated processes can get away with it. That is, the check > is only part of the UI, not an actual file system rule. I'm developing > on XP, and my local repository cache is in C:\Docs & > Settings\username\.m2 as usual, and in fact I have several other apps > born on Unix that name directories with a leading dot. > > You mileage may vary, though; I'm on a fancy corporate network set up to > share drives between Unix systems and Windows desktops, so maybe IT did > something magical that they never told me about to make this possible. > Try to run Maven, and see if it autocreates the directory. > > ~Dan Allen > > -Original Message- > From: JG Flowers [mailto:[EMAIL PROTECTED] > Sent: Tuesday, February 12, 2008 1:32 PM > To: users@maven.apache.org > Subject: Local Maven repository. Newbie question... > > > Reading Better Builds with Maven. from Devzuz > It says on page 32 "When you install and run Maven for the first time, > it > will create your local repository and populate it > with artifacts as a result of dependency requests. By default, Maven > creates > your local repository in > /.m2/repository. You must have a local repository in order > for > Maven to work." > > Now I'm using XP and I'm assuming will be substituted with > %USERPROFILE% environment variable. > But on XP you can't have a directory named ".m2", XP groans and says you > must have a file name, for it thinks you are just specifying an > extension. > > Have done the install. When I run mvn --version it says everything's ok. > So > where is my repository? > The last thing booksays is you must have local repository for Maven to > work. > Confused.. You bet :confused: > Any > -- > View this message in context: > http://www.nabble.com/Local-Maven-repository.-Newbie-question...-tp15439 > 648s177p15439648.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- > This message may contain confidential, proprietary, or legally privileged > information. No confidentiality or privilege is waived by any transmission > to an unintended recipient. If you are not an intended recipient, please > notify the sender and delete this message immediately. Any views expressed > in this message are those of the sender, not those of any entity within > the KBC Financial Products group of companies (together referred to as > "KBC FP"). > > This message does not create any obligation, contractual or otherwise, on > the part of KBC FP. It is not an offer (or solicitation of an offer) of, > or a recommendation to buy or sell, any financial product. Any prices or > other values included in this message are indicative only, and do not > necessarily represent current market prices, prices at which KBC FP would > enter into a transaction, or prices at which similar transactions may be > carried on KBC FP's own books. The information contained in this message > is provided "as is", without representations or warranties, express or > implied, of any kind. Past performance is not indicative of future > returns. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For
RE: Local Maven repository. Newbie question...
Argh!!! It's a Windows Explorer thing.. :-U Can name a directory with . prefix with md from command prompt... Still directory has no repositoty in it. But reading on a bit further it talks about creating a settings.xml file. I think it's a chicken or egg thing. In writing the book they talk about things in chapter 1 than get covered for first time in chapter 2... %-| Cheers for reply, Jeremy Allen, Daniel wrote: > > Not saying for sure that this is what's going on, but in my experience > it seems like XP only makes that complaint if *you* try to name a folder > that, while automated processes can get away with it. That is, the check > is only part of the UI, not an actual file system rule. I'm developing > on XP, and my local repository cache is in C:\Docs & > Settings\username\.m2 as usual, and in fact I have several other apps > born on Unix that name directories with a leading dot. > > You mileage may vary, though; I'm on a fancy corporate network set up to > share drives between Unix systems and Windows desktops, so maybe IT did > something magical that they never told me about to make this possible. > Try to run Maven, and see if it autocreates the directory. > > ~Dan Allen > > -Original Message- > From: JG Flowers [mailto:[EMAIL PROTECTED] > Sent: Tuesday, February 12, 2008 1:32 PM > To: users@maven.apache.org > Subject: Local Maven repository. Newbie question... > > > Reading Better Builds with Maven. from Devzuz > It says on page 32 "When you install and run Maven for the first time, > it > will create your local repository and populate it > with artifacts as a result of dependency requests. By default, Maven > creates > your local repository in > /.m2/repository. You must have a local repository in order > for > Maven to work." > > Now I'm using XP and I'm assuming will be substituted with > %USERPROFILE% environment variable. > But on XP you can't have a directory named ".m2", XP groans and says you > must have a file name, for it thinks you are just specifying an > extension. > > Have done the install. When I run mvn --version it says everything's ok. > So > where is my repository? > The last thing booksays is you must have local repository for Maven to > work. > Confused.. You bet :confused: > Any > -- > View this message in context: > http://www.nabble.com/Local-Maven-repository.-Newbie-question...-tp15439 > 648s177p15439648.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- > This message may contain confidential, proprietary, or legally privileged > information. No confidentiality or privilege is waived by any transmission > to an unintended recipient. If you are not an intended recipient, please > notify the sender and delete this message immediately. Any views expressed > in this message are those of the sender, not those of any entity within > the KBC Financial Products group of companies (together referred to as > "KBC FP"). > > This message does not create any obligation, contractual or otherwise, on > the part of KBC FP. It is not an offer (or solicitation of an offer) of, > or a recommendation to buy or sell, any financial product. Any prices or > other values included in this message are indicative only, and do not > necessarily represent current market prices, prices at which KBC FP would > enter into a transaction, or prices at which similar transactions may be > carried on KBC FP's own books. The information contained in this message > is provided "as is", without representations or warranties, express or > implied, of any kind. Past performance is not indicative of future > returns. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Local-Maven-repository.-Newbie-question...-tp15439648s177p15440135.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Local Maven repository. Newbie question...
Dan is correct. You can run "mkdir .blah" and "rmdir .blah" from DOS, its just Windows Explorer that prevents it from working. Wayne On 2/12/08, Allen, Daniel <[EMAIL PROTECTED]> wrote: > Not saying for sure that this is what's going on, but in my experience > it seems like XP only makes that complaint if *you* try to name a folder > that, while automated processes can get away with it. That is, the check > is only part of the UI, not an actual file system rule. I'm developing > on XP, and my local repository cache is in C:\Docs & > Settings\username\.m2 as usual, and in fact I have several other apps > born on Unix that name directories with a leading dot. > > You mileage may vary, though; I'm on a fancy corporate network set up to > share drives between Unix systems and Windows desktops, so maybe IT did > something magical that they never told me about to make this possible. > Try to run Maven, and see if it autocreates the directory. > > ~Dan Allen > > -Original Message- > From: JG Flowers [mailto:[EMAIL PROTECTED] > Sent: Tuesday, February 12, 2008 1:32 PM > To: users@maven.apache.org > Subject: Local Maven repository. Newbie question... > > > Reading Better Builds with Maven. from Devzuz > It says on page 32 "When you install and run Maven for the first time, > it > will create your local repository and populate it > with artifacts as a result of dependency requests. By default, Maven > creates > your local repository in > /.m2/repository. You must have a local repository in order > for > Maven to work." > > Now I'm using XP and I'm assuming will be substituted with > %USERPROFILE% environment variable. > But on XP you can't have a directory named ".m2", XP groans and says you > must have a file name, for it thinks you are just specifying an > extension. > > Have done the install. When I run mvn --version it says everything's ok. > So > where is my repository? > The last thing booksays is you must have local repository for Maven to > work. > Confused.. You bet :confused: > Any > -- > View this message in context: > http://www.nabble.com/Local-Maven-repository.-Newbie-question...-tp15439 > 648s177p15439648.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- > This message may contain confidential, proprietary, or legally privileged > information. No confidentiality or privilege is waived by any transmission > to an unintended recipient. If you are not an intended recipient, please > notify the sender and delete this message immediately. Any views expressed > in this message are those of the sender, not those of any entity within the > KBC Financial Products group of companies (together referred to as "KBC > FP"). > > This message does not create any obligation, contractual or otherwise, on > the part of KBC FP. It is not an offer (or solicitation of an offer) of, or > a recommendation to buy or sell, any financial product. Any prices or other > values included in this message are indicative only, and do not necessarily > represent current market prices, prices at which KBC FP would enter into a > transaction, or prices at which similar transactions may be carried on KBC > FP's own books. The information contained in this message is provided "as > is", without representations or warranties, express or implied, of any kind. > Past performance is not indicative of future returns. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Local Maven repository. Newbie question...
Not saying for sure that this is what's going on, but in my experience it seems like XP only makes that complaint if *you* try to name a folder that, while automated processes can get away with it. That is, the check is only part of the UI, not an actual file system rule. I'm developing on XP, and my local repository cache is in C:\Docs & Settings\username\.m2 as usual, and in fact I have several other apps born on Unix that name directories with a leading dot. You mileage may vary, though; I'm on a fancy corporate network set up to share drives between Unix systems and Windows desktops, so maybe IT did something magical that they never told me about to make this possible. Try to run Maven, and see if it autocreates the directory. ~Dan Allen -Original Message- From: JG Flowers [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 12, 2008 1:32 PM To: users@maven.apache.org Subject: Local Maven repository. Newbie question... Reading Better Builds with Maven. from Devzuz It says on page 32 "When you install and run Maven for the first time, it will create your local repository and populate it with artifacts as a result of dependency requests. By default, Maven creates your local repository in /.m2/repository. You must have a local repository in order for Maven to work." Now I'm using XP and I'm assuming will be substituted with %USERPROFILE% environment variable. But on XP you can't have a directory named ".m2", XP groans and says you must have a file name, for it thinks you are just specifying an extension. Have done the install. When I run mvn --version it says everything's ok. So where is my repository? The last thing booksays is you must have local repository for Maven to work. Confused.. You bet :confused: Any -- View this message in context: http://www.nabble.com/Local-Maven-repository.-Newbie-question...-tp15439 648s177p15439648.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- This message may contain confidential, proprietary, or legally privileged information. No confidentiality or privilege is waived by any transmission to an unintended recipient. If you are not an intended recipient, please notify the sender and delete this message immediately. Any views expressed in this message are those of the sender, not those of any entity within the KBC Financial Products group of companies (together referred to as "KBC FP"). This message does not create any obligation, contractual or otherwise, on the part of KBC FP. It is not an offer (or solicitation of an offer) of, or a recommendation to buy or sell, any financial product. Any prices or other values included in this message are indicative only, and do not necessarily represent current market prices, prices at which KBC FP would enter into a transaction, or prices at which similar transactions may be carried on KBC FP's own books. The information contained in this message is provided "as is", without representations or warranties, express or implied, of any kind. Past performance is not indicative of future returns. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Local Maven repository. Newbie question...
Reading Better Builds with Maven. from Devzuz It says on page 32 "When you install and run Maven for the first time, it will create your local repository and populate it with artifacts as a result of dependency requests. By default, Maven creates your local repository in /.m2/repository. You must have a local repository in order for Maven to work." Now I'm using XP and I'm assuming will be substituted with %USERPROFILE% environment variable. But on XP you can't have a directory named ".m2", XP groans and says you must have a file name, for it thinks you are just specifying an extension. Have done the install. When I run mvn --version it says everything's ok. So where is my repository? The last thing booksays is you must have local repository for Maven to work. Confused.. You bet :confused: Any -- View this message in context: http://www.nabble.com/Local-Maven-repository.-Newbie-question...-tp15439648s177p15439648.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: add dependency (newbie question) ?
I think that the following link can help you: http://maven.apache.org/guides/getting-started/index.html#How_do_I_use_external_dependencies Giancarlo 2007/11/14, Nicola Benaglia <[EMAIL PROTECTED]>: > Hi ! > This is my first partecipation at this mailing listand obviously > with a very simple question. > I need to add a postgres jdbc dependency to maven. > > Googling I found these lines to add to pom.xml: > > > postgresql > postgresql > 8.1-407.jdbc3 > http://www.postgresql.org/ > > > It worked, but I'd like to know what to write as groupID, artifactID, ... ? > Could you please help me or point me to the documentation explaining it? > > Thank you, > Nicola > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
add dependency (newbie question) ?
Hi ! This is my first partecipation at this mailing listand obviously with a very simple question. I need to add a postgres jdbc dependency to maven. Googling I found these lines to add to pom.xml: postgresql postgresql 8.1-407.jdbc3 http://www.postgresql.org/ It worked, but I'd like to know what to write as groupID, artifactID, ... ? Could you please help me or point me to the documentation explaining it? Thank you, Nicola - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question on deployment strategy
Generally yes this means a complete undeploy plus deploy of the new war, unless you've got some special J2EE server that does it another way. Schedule downtime or find a low-usage time to push your WARs, just like everybody else. Ideally you're not pushing updates out to Prod on a daily basis but instead using your Dev and Test/QA environments for those types of builds, and then pushing bigger updates or emergency bugfixes out to Prod. Wayne On 10/24/07, Ross Mcdonald <[EMAIL PROTECTED]> wrote: > Hi, > > thanks for that, I am trying to get my head into this method of > working.. I am just a little worried about having to reload a war each > time, doesn't that require complete reloading of the war in the web > server, which is perhaps too much of an interruption to a production > application in some cases ? > > Regards, > > Ross > > > Nick Stolwijk wrote: > > Normally, even with a few updated files, you would release your > > project again. Then it will create a new version number, a tag and the > > final artifacts, like jars and wars. This has nothing to do with how > > you deploy it to production. The deployment Maven talks about is > > deploying the artifacts to a Maven repository. > > > > The deployment to production will be the full war file again. This > > way, you can reproduce the deployment. (Changing some files on your > > production server is not a good idea.) Also, often these new artifacts > > will have to go through testing and acceptance again, before making it > > to a production server. (Our development cycle is Development, Test, > > Acceptance, Production) > > > > I hope this clears things up a bit. > > > > With regards, > > > > Nick Stolwijk > > > > Ross Mcdonald wrote: > >> Hi all, > >> > >> I am a newbie to this, carefully considering bringing Maven in house > >> to our small company to improve a number of different systems. I > >> have downloaded a couple of ebooks which are great, and I see many > >> ways in which Maven will make life easier, I am however finding it > >> difficult to track down information in the books and with the help of > >> google on deployment strategies for live setups. > >> > >> > >> I see the use of creating a war for initial deployment, but what > >> about later when just want to send a few updated files across to a > >> production server? I say there is a distributionManagement element, > >> which can use a number of different protocols to send files, but I > >> cannot see any real world examples, or find documentation with enough > >> detail. Can anyone point me towards some nice easy examples on this > >> topic? > >> > >> Thankyou in advance for your help. > >> > >> Regards, > >> > >> Ross > >> > >> > >> - > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question on deployment strategy
Hi, thanks for that, I am trying to get my head into this method of working.. I am just a little worried about having to reload a war each time, doesn't that require complete reloading of the war in the web server, which is perhaps too much of an interruption to a production application in some cases ? Regards, Ross Nick Stolwijk wrote: Normally, even with a few updated files, you would release your project again. Then it will create a new version number, a tag and the final artifacts, like jars and wars. This has nothing to do with how you deploy it to production. The deployment Maven talks about is deploying the artifacts to a Maven repository. The deployment to production will be the full war file again. This way, you can reproduce the deployment. (Changing some files on your production server is not a good idea.) Also, often these new artifacts will have to go through testing and acceptance again, before making it to a production server. (Our development cycle is Development, Test, Acceptance, Production) I hope this clears things up a bit. With regards, Nick Stolwijk Ross Mcdonald wrote: Hi all, I am a newbie to this, carefully considering bringing Maven in house to our small company to improve a number of different systems. I have downloaded a couple of ebooks which are great, and I see many ways in which Maven will make life easier, I am however finding it difficult to track down information in the books and with the help of google on deployment strategies for live setups. I see the use of creating a war for initial deployment, but what about later when just want to send a few updated files across to a production server? I say there is a distributionManagement element, which can use a number of different protocols to send files, but I cannot see any real world examples, or find documentation with enough detail. Can anyone point me towards some nice easy examples on this topic? Thankyou in advance for your help. Regards, Ross - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question on deployment strategy
Normally, even with a few updated files, you would release your project again. Then it will create a new version number, a tag and the final artifacts, like jars and wars. This has nothing to do with how you deploy it to production. The deployment Maven talks about is deploying the artifacts to a Maven repository. The deployment to production will be the full war file again. This way, you can reproduce the deployment. (Changing some files on your production server is not a good idea.) Also, often these new artifacts will have to go through testing and acceptance again, before making it to a production server. (Our development cycle is Development, Test, Acceptance, Production) I hope this clears things up a bit. With regards, Nick Stolwijk Ross Mcdonald wrote: Hi all, I am a newbie to this, carefully considering bringing Maven in house to our small company to improve a number of different systems. I have downloaded a couple of ebooks which are great, and I see many ways in which Maven will make life easier, I am however finding it difficult to track down information in the books and with the help of google on deployment strategies for live setups. I see the use of creating a war for initial deployment, but what about later when just want to send a few updated files across to a production server? I say there is a distributionManagement element, which can use a number of different protocols to send files, but I cannot see any real world examples, or find documentation with enough detail. Can anyone point me towards some nice easy examples on this topic? Thankyou in advance for your help. Regards, Ross - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie question on deployment strategy
Hi all, I am a newbie to this, carefully considering bringing Maven in house to our small company to improve a number of different systems. I have downloaded a couple of ebooks which are great, and I see many ways in which Maven will make life easier, I am however finding it difficult to track down information in the books and with the help of google on deployment strategies for live setups. I see the use of creating a war for initial deployment, but what about later when just want to send a few updated files across to a production server? I say there is a distributionManagement element, which can use a number of different protocols to send files, but I cannot see any real world examples, or find documentation with enough detail. Can anyone point me towards some nice easy examples on this topic? Thankyou in advance for your help. Regards, Ross - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Very newbie question
Doesn't http://maven.apache.org/plugins/maven-archetype-plugin/examples/simple.html help you? Have you had a look at http://maven.apache.org/guides/introduction/introduction-to-the-standard-directory-layout.html and http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html already? -Gisbert ichasco wrote: Ok, it´s what i wanted: to create my own archetype (now i know that it is not recommended). Then, i have a new question. If i want to make a project with a structure like: root src java test testDB testUnit doc build what i have to do? Wayne Fay wrote: The question was really directed to the original poster, ichasco. I have seen other people new to Maven who seem to believe that they must create archetypes themselves manually rather than simply reusing the existing archetypes. I want to make sure that ichasco is not heading down the wrong path. People who are new to Maven generally should not be creating archetypes. Wayne On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: One application of it for me was a multi-project layout for an EAR with a myfaces web application, EJB3, a persistence archive, a custom login module, skeleton config files, etc. It's helpful if you create several projects using the same pattern. On 10/15/07, Wayne Fay <[EMAIL PROTECTED]> wrote: Just curious, why do you think you need to CREATE an archetype? Most people will simply USE an archetype that has been previously created. "mvn archetype:create ..." is simply the command to create a new project using an archetype. I'd be very surprised that a new user would want to create an archetype. What exactly are you hoping to do with Maven2? Wayne On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: An archetype is installed the same way as a normal artifact; so running 'mvn install' in the directory will do it. In case you haven't seen it, this guide to creating archetypes helped me along: http://maven.apache.org/guides/mini/guide-creating-archetypes.html Harlan On 10/15/07, ichasco <[EMAIL PROTECTED]> wrote: Hi all, I have just started with maven and i have some questions. I have read the guide to creating archetype and i do not understand very well it. I know that i have to create an archetype.xml, pom.xml, ... but where i have to saved all these files? in .m2? where are stored archetypes? Thanks -- View this message in context: http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13214344 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Harlan Iverson http://blog.devspan.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Harlan Iverson http://blog.devspan.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Gisbert Amm Softwareentwickler Infrastruktur Telefon: (0721) 91374 - 4224 Telefax: (0721) 91374 - 2740 E-Mail: [EMAIL PROTECTED] Internet: www.1und1.de 1&1 Internet AG Elgendorfer Strasse 57 56410 Montabaur Amtsgericht Montabaur HRB 6484 Vorstand: Henning Ahlert, Ralph Dommermuth, Matthias Ehrlich, Andreas Gauger, Thomas Gottschlich, Matthias Greve, Robert Hoffmann, Norbert Lang, Achim Weiss Aufsichtsratsvorsitzender: Michael Scheeren - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Very newbie question
Ok, it´s what i wanted: to create my own archetype (now i know that it is not recommended). Then, i have a new question. If i want to make a project with a structure like: root src java test testDB testUnit doc build what i have to do? Wayne Fay wrote: > > The question was really directed to the original poster, ichasco. > > I have seen other people new to Maven who seem to believe that they > must create archetypes themselves manually rather than simply reusing > the existing archetypes. > > I want to make sure that ichasco is not heading down the wrong path. > People who are new to Maven generally should not be creating > archetypes. > > Wayne > > On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: >> One application of it for me was a multi-project layout for an EAR with a >> myfaces web application, EJB3, a persistence archive, a custom login >> module, >> skeleton config files, etc. It's helpful if you create several projects >> using the same pattern. >> >> On 10/15/07, Wayne Fay <[EMAIL PROTECTED]> wrote: >> > >> > Just curious, why do you think you need to CREATE an archetype? Most >> > people will simply USE an archetype that has been previously created. >> > >> > "mvn archetype:create ..." is simply the command to create a new >> > project using an archetype. I'd be very surprised that a new user >> > would want to create an archetype. >> > >> > What exactly are you hoping to do with Maven2? >> > >> > Wayne >> > >> > On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: >> > > An archetype is installed the same way as a normal artifact; so >> running >> > 'mvn >> > > install' in the directory will do it. >> > > >> > > In case you haven't seen it, this guide to creating archetypes helped >> me >> > > along: >> > http://maven.apache.org/guides/mini/guide-creating-archetypes.html >> > > >> > > Harlan >> > > >> > > On 10/15/07, ichasco <[EMAIL PROTECTED]> wrote: >> > > > >> > > > >> > > > Hi all, >> > > > >> > > > I have just started with maven and i have some questions. I have >> read >> > the >> > > > guide to creating archetype and i do not understand very well it. >> > > > >> > > > I know that i have to create an archetype.xml, pom.xml, ... but >> where >> > i >> > > > have >> > > > to saved all these files? in .m2? where are stored archetypes? >> > > > >> > > > Thanks >> > > > >> > > > >> > > > -- >> > > > View this message in context: >> > > > >> > http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13214344 >> > > > Sent from the Maven - Users mailing list archive at Nabble.com. >> > > > >> > > > >> > > > >> ----- >> > > > To unsubscribe, e-mail: [EMAIL PROTECTED] >> > > > For additional commands, e-mail: [EMAIL PROTECTED] >> > > > >> > > > >> > > >> > > >> > > -- >> > > Harlan Iverson >> > > http://blog.devspan.com >> > > >> > >> > - >> > To unsubscribe, e-mail: [EMAIL PROTECTED] >> > For additional commands, e-mail: [EMAIL PROTECTED] >> > >> > >> >> >> -- >> Harlan Iverson >> http://blog.devspan.com >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13227493 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Very newbie question
The question was really directed to the original poster, ichasco. I have seen other people new to Maven who seem to believe that they must create archetypes themselves manually rather than simply reusing the existing archetypes. I want to make sure that ichasco is not heading down the wrong path. People who are new to Maven generally should not be creating archetypes. Wayne On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: > One application of it for me was a multi-project layout for an EAR with a > myfaces web application, EJB3, a persistence archive, a custom login module, > skeleton config files, etc. It's helpful if you create several projects > using the same pattern. > > On 10/15/07, Wayne Fay <[EMAIL PROTECTED]> wrote: > > > > Just curious, why do you think you need to CREATE an archetype? Most > > people will simply USE an archetype that has been previously created. > > > > "mvn archetype:create ..." is simply the command to create a new > > project using an archetype. I'd be very surprised that a new user > > would want to create an archetype. > > > > What exactly are you hoping to do with Maven2? > > > > Wayne > > > > On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: > > > An archetype is installed the same way as a normal artifact; so running > > 'mvn > > > install' in the directory will do it. > > > > > > In case you haven't seen it, this guide to creating archetypes helped me > > > along: > > http://maven.apache.org/guides/mini/guide-creating-archetypes.html > > > > > > Harlan > > > > > > On 10/15/07, ichasco <[EMAIL PROTECTED]> wrote: > > > > > > > > > > > > Hi all, > > > > > > > > I have just started with maven and i have some questions. I have read > > the > > > > guide to creating archetype and i do not understand very well it. > > > > > > > > I know that i have to create an archetype.xml, pom.xml, ... but where > > i > > > > have > > > > to saved all these files? in .m2? where are stored archetypes? > > > > > > > > Thanks > > > > > > > > > > > > -- > > > > View this message in context: > > > > > > http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13214344 > > > > Sent from the Maven - Users mailing list archive at Nabble.com. > > > > > > > > > > > > - > > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > > > > > > > > > -- > > > Harlan Iverson > > > http://blog.devspan.com > > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > -- > Harlan Iverson > http://blog.devspan.com > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Very newbie question
One application of it for me was a multi-project layout for an EAR with a myfaces web application, EJB3, a persistence archive, a custom login module, skeleton config files, etc. It's helpful if you create several projects using the same pattern. On 10/15/07, Wayne Fay <[EMAIL PROTECTED]> wrote: > > Just curious, why do you think you need to CREATE an archetype? Most > people will simply USE an archetype that has been previously created. > > "mvn archetype:create ..." is simply the command to create a new > project using an archetype. I'd be very surprised that a new user > would want to create an archetype. > > What exactly are you hoping to do with Maven2? > > Wayne > > On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: > > An archetype is installed the same way as a normal artifact; so running > 'mvn > > install' in the directory will do it. > > > > In case you haven't seen it, this guide to creating archetypes helped me > > along: > http://maven.apache.org/guides/mini/guide-creating-archetypes.html > > > > Harlan > > > > On 10/15/07, ichasco <[EMAIL PROTECTED]> wrote: > > > > > > > > > Hi all, > > > > > > I have just started with maven and i have some questions. I have read > the > > > guide to creating archetype and i do not understand very well it. > > > > > > I know that i have to create an archetype.xml, pom.xml, ... but where > i > > > have > > > to saved all these files? in .m2? where are stored archetypes? > > > > > > Thanks > > > > > > > > > -- > > > View this message in context: > > > > http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13214344 > > > Sent from the Maven - Users mailing list archive at Nabble.com. > > > > > > > > > - > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > > > > -- > > Harlan Iverson > > http://blog.devspan.com > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Harlan Iverson http://blog.devspan.com
Re: Very newbie question
Just curious, why do you think you need to CREATE an archetype? Most people will simply USE an archetype that has been previously created. "mvn archetype:create ..." is simply the command to create a new project using an archetype. I'd be very surprised that a new user would want to create an archetype. What exactly are you hoping to do with Maven2? Wayne On 10/15/07, Harlan Iverson <[EMAIL PROTECTED]> wrote: > An archetype is installed the same way as a normal artifact; so running 'mvn > install' in the directory will do it. > > In case you haven't seen it, this guide to creating archetypes helped me > along: http://maven.apache.org/guides/mini/guide-creating-archetypes.html > > Harlan > > On 10/15/07, ichasco <[EMAIL PROTECTED]> wrote: > > > > > > Hi all, > > > > I have just started with maven and i have some questions. I have read the > > guide to creating archetype and i do not understand very well it. > > > > I know that i have to create an archetype.xml, pom.xml, ... but where i > > have > > to saved all these files? in .m2? where are stored archetypes? > > > > Thanks > > > > > > -- > > View this message in context: > > http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13214344 > > Sent from the Maven - Users mailing list archive at Nabble.com. > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > -- > Harlan Iverson > http://blog.devspan.com > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Very newbie question
An archetype is installed the same way as a normal artifact; so running 'mvn install' in the directory will do it. In case you haven't seen it, this guide to creating archetypes helped me along: http://maven.apache.org/guides/mini/guide-creating-archetypes.html Harlan On 10/15/07, ichasco <[EMAIL PROTECTED]> wrote: > > > Hi all, > > I have just started with maven and i have some questions. I have read the > guide to creating archetype and i do not understand very well it. > > I know that i have to create an archetype.xml, pom.xml, ... but where i > have > to saved all these files? in .m2? where are stored archetypes? > > Thanks > > > -- > View this message in context: > http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13214344 > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Harlan Iverson http://blog.devspan.com
Very newbie question
Hi all, I have just started with maven and i have some questions. I have read the guide to creating archetype and i do not understand very well it. I know that i have to create an archetype.xml, pom.xml, ... but where i have to saved all these files? in .m2? where are stored archetypes? Thanks -- View this message in context: http://www.nabble.com/Very-newbie-question-tf4628024s177.html#a13214344 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question: including a jar in maven
Arrowx7 wrote: Hello, I'm new to maven I wanted to include the hibernate jar so I can import classes like: import org.springframework.orm.hibernate3.HibernateCallback; I know I have to add something to the pom.xml files, but I'm not sure what. Is it the hibernate plugin for maven? Can someone point me in the right direction? You need to add a dependency on hibernate in your pom.xml. More info available here: http://maven.apache.org/guides/getting-started/index.html#How_do_I_use_external_dependencies -- Dennis Lundberg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie question: including a jar in maven
Hello, I'm new to maven I wanted to include the hibernate jar so I can import classes like: import org.springframework.orm.hibernate3.HibernateCallback; I know I have to add something to the pom.xml files, but I'm not sure what. Is it the hibernate plugin for maven? Can someone point me in the right direction? -- View this message in context: http://www.nabble.com/Newbie-question%3A-including-a-jar-in-maven-tf4331215s177.html#a12335154 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question 1
I think there's still a problem with Archiva when you add a repo that is not in your local file system. From my experience, when I tried to add a repo with this url --> http://repo1.maven.org/maven2.. I get this instead: file:/[home_dir]/http://repo1.maven.org/maven2. All repos that I add regardless of it being in the local file system or not, 'file:/' is always prepended. Could that be your problem too? That's why you cannot index your repository? Also, have you checked your repo url/dir? Take note that Archiva creates the repo if it does not exist in the file system :) There's already an open issue for the add remote repo problem: http://jira.codehaus.org/browse/MRM-371 <http://jira.codehaus.org/browse/MRM-371> HTH, Deng Chris Helck wrote: I guess from the trunk: archiva-1.0-alpha-1-SNAPSHOT. -Chris -Original Message- From: Maria Odea Ching [mailto:[EMAIL PROTECTED] Sent: Sunday, June 03, 2007 11:39 PM To: [EMAIL PROTECTED] Subject: Re: Newbie question 1 Hi, Which version of archiva are you using? archiva-0.9-alpha-2 or did you build from trunk? -Deng Chris Helck wrote: Hi, I'm confused. I've added a managed repository that points to one of our in house repos. I delete my .m2/repository and was able to rebuild a project. Yet, if I click on the "scan repository now" button it says that it has zero files. I assumed that archiva would cache stuff that it downloads. Also, browse shows nothing and Search doesn't ever find anything. Thanks, Christopher Helck ** This communication and all information (including, but not limited to, market prices/levels and data) contained therein (the "Information") is for informational purposes only, is confidential, may be legally privileged and is the intellectual property of ICAP plc and its affiliates ("ICAP") or third parties. No confidentiality or privilege is waived or lost by any mistransmission. The Information is not, and should not be construed as, an offer, bid or solicitation in relation to any financial instrument or as an official confirmation of any transaction. The Information is not warranted, including, but not limited, as to completeness, timeliness or accuracy and is subject to change without notice. ICAP assumes no liability for use or misuse of the Information. All representations and warranties are expressly disclaimed. The Information does not necessarily reflect the views of ICAP. Access to the Information by anyone else other than the recipient is unauthorized and any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it is prohibited. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. ** ** This communication and all information (including, but not limited to, market prices/levels and data) contained therein (the "Information") is for informational purposes only, is confidential, may be legally privileged and is the intellectual property of ICAP plc and its affiliates ("ICAP") or third parties. No confidentiality or privilege is waived or lost by any mistransmission. The Information is not, and should not be construed as, an offer, bid or solicitation in relation to any financial instrument or as an official confirmation of any transaction. The Information is not warranted, including, but not limited, as to completeness, timeliness or accuracy and is subject to change without notice. ICAP assumes no liability for use or misuse of the Information. All representations and warranties are expressly disclaimed. The Information does not necessarily reflect the views of ICAP. Access to the Information by anyone else other than the recipient is unauthorized and any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it is prohibited. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. **
RE: Newbie question 1
I guess from the trunk: archiva-1.0-alpha-1-SNAPSHOT. -Chris -Original Message- From: Maria Odea Ching [mailto:[EMAIL PROTECTED] Sent: Sunday, June 03, 2007 11:39 PM To: [EMAIL PROTECTED] Subject: Re: Newbie question 1 Hi, Which version of archiva are you using? archiva-0.9-alpha-2 or did you build from trunk? -Deng Chris Helck wrote: > Hi, > > I'm confused. I've added a managed repository that points to one of > our in house repos. I delete my .m2/repository and was able to rebuild > a project. Yet, if I click on the "scan repository now" button it says > that it has zero files. I assumed that archiva would cache stuff that > it downloads. Also, browse shows nothing and Search doesn't ever find > anything. > > Thanks, > Christopher Helck > > > ** > This communication and all information (including, but not limited to, > market prices/levels and data) contained therein (the "Information") > is for informational purposes only, is confidential, may be legally > privileged and is the intellectual property of ICAP plc and its > affiliates > ("ICAP") or third parties. No confidentiality or privilege is waived > or lost by any mistransmission. The Information is not, and should > not be construed as, an offer, bid or solicitation in relation to any > financial instrument or as an official confirmation of any transaction. > The Information is not warranted, including, but not limited, as to > completeness, timeliness or accuracy and is subject to change without > notice. ICAP assumes no liability for use or misuse of the > Information. All representations and warranties are expressly > disclaimed. The Information does not necessarily reflect the views of > ICAP. Access to the Information by anyone else other than the > recipient is unauthorized and any disclosure, copying, distribution or > any action taken or omitted to be taken in reliance on it is > prohibited. If you receive this message in error, please immediately > delete it and all copies of it from your system, destroy any hard > copies of it and notify the sender. > ** > > > ** This communication and all information (including, but not limited to, market prices/levels and data) contained therein (the "Information") is for informational purposes only, is confidential, may be legally privileged and is the intellectual property of ICAP plc and its affiliates ("ICAP") or third parties. No confidentiality or privilege is waived or lost by any mistransmission. The Information is not, and should not be construed as, an offer, bid or solicitation in relation to any financial instrument or as an official confirmation of any transaction. The Information is not warranted, including, but not limited, as to completeness, timeliness or accuracy and is subject to change without notice. ICAP assumes no liability for use or misuse of the Information. All representations and warranties are expressly disclaimed. The Information does not necessarily reflect the views of ICAP. Access to the Information by anyone else other than the recipient is unauthorized and any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it is prohibited. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. **
Newbie Question 2
Hi, How do I make maven use Archiva to fetch things from the central repo? Thanks, Christopher Helck ** This communication and all information (including, but not limited to, market prices/levels and data) contained therein (the "Information") is for informational purposes only, is confidential, may be legally privileged and is the intellectual property of ICAP plc and its affiliates ("ICAP") or third parties. No confidentiality or privilege is waived or lost by any mistransmission. The Information is not, and should not be construed as, an offer, bid or solicitation in relation to any financial instrument or as an official confirmation of any transaction. The Information is not warranted, including, but not limited, as to completeness, timeliness or accuracy and is subject to change without notice. ICAP assumes no liability for use or misuse of the Information. All representations and warranties are expressly disclaimed. The Information does not necessarily reflect the views of ICAP. Access to the Information by anyone else other than the recipient is unauthorized and any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it is prohibited. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. **
Newbie question 1
Hi, I'm confused. I've added a managed repository that points to one of our in house repos. I delete my .m2/repository and was able to rebuild a project. Yet, if I click on the "scan repository now" button it says that it has zero files. I assumed that archiva would cache stuff that it downloads. Also, browse shows nothing and Search doesn't ever find anything. Thanks, Christopher Helck ** This communication and all information (including, but not limited to, market prices/levels and data) contained therein (the "Information") is for informational purposes only, is confidential, may be legally privileged and is the intellectual property of ICAP plc and its affiliates ("ICAP") or third parties. No confidentiality or privilege is waived or lost by any mistransmission. The Information is not, and should not be construed as, an offer, bid or solicitation in relation to any financial instrument or as an official confirmation of any transaction. The Information is not warranted, including, but not limited, as to completeness, timeliness or accuracy and is subject to change without notice. ICAP assumes no liability for use or misuse of the Information. All representations and warranties are expressly disclaimed. The Information does not necessarily reflect the views of ICAP. Access to the Information by anyone else other than the recipient is unauthorized and any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it is prohibited. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. **
Re: (newbie question) seding war somewhere else
Another option of course is to use the Cargo Maven2 plugin for your deployment. Depending on your container, this may be a better approach. Wayne On 5/10/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: Arrowx7 <[EMAIL PROTECTED]> wrote on 05/10/2007 12:16:04 PM: > > I have mevenide2 installed, and when I run lifecycle phase "install" > one of the output lines is > [INFO]Installing /root/sourcecode/myproject.war to > /root/.m2/repository/org/myproject.war > > is there a way to get it to install somewhere other than > /root/.m2/repository/... say /usr/local/tomcat/webapps/ ?? Do I have to > add some sort of property > > Thank you very much in advance, looking forward to replies. I think you want to look at the tomcat plugin and the tomcat:deploy goal. See: http://mojo.codehaus.org/tomcat-maven-plugin/deployment.html -Greg == Confidentiality Notice: The information contained in and transmitted with this communication is strictly confidential, is intended only for the use of the intended recipient, and is the property of Countrywide Financial Corporation or its affiliates and subsidiaries. If you are not the intended recipient, you are hereby notified that any use of the information contained in or transmitted with the communication or dissemination, distribution, or copying of this communication is strictly prohibited by law. If you have received this communication in error, please immediately return this communication to the sender and delete the original message and any copy of it in your possession. == - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: (newbie question) seding war somewhere else
Arrowx7 <[EMAIL PROTECTED]> wrote on 05/10/2007 12:16:04 PM: > > I have mevenide2 installed, and when I run lifecycle phase "install" > one of the output lines is > [INFO]Installing /root/sourcecode/myproject.war to > /root/.m2/repository/org/myproject.war > > is there a way to get it to install somewhere other than > /root/.m2/repository/... say /usr/local/tomcat/webapps/ ?? Do I have to > add some sort of property > > Thank you very much in advance, looking forward to replies. I think you want to look at the tomcat plugin and the tomcat:deploy goal. See: http://mojo.codehaus.org/tomcat-maven-plugin/deployment.html -Greg == Confidentiality Notice: The information contained in and transmitted with this communication is strictly confidential, is intended only for the use of the intended recipient, and is the property of Countrywide Financial Corporation or its affiliates and subsidiaries. If you are not the intended recipient, you are hereby notified that any use of the information contained in or transmitted with the communication or dissemination, distribution, or copying of this communication is strictly prohibited by law. If you have received this communication in error, please immediately return this communication to the sender and delete the original message and any copy of it in your possession. ==
Re: (newbie question) seding war somewhere else
how do I change the deployment location?? nhoj_p wrote: > > The common approache is to use deploy to get the war to the 'deployment' > location. Install is just to install into your local repository so its > avaliable to other projects your working on. > > On 10/05/07, Arrowx7 <[EMAIL PROTECTED]> wrote: >> >> >> Hello, >> I have mevenide2 installed, and when I run lifecycle phase "install" >> one of the output lines is >> [INFO]Installing /root/sourcecode/myproject.war to >> /root/.m2/repository/org/myproject.war >> >> is there a way to get it to install somewhere other than >> /root/.m2/repository/... say /usr/local/tomcat/webapps/ ?? Do I have to >> add some sort of property >> >> Thank you very much in advance, looking forward to replies. >> -- >> View this message in context: >> http://www.nabble.com/%28newbie-question%29-seding-war-somewhere-else-tf3722975s177.html#a10417737 >> Sent from the Maven - Users mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > -- View this message in context: http://www.nabble.com/%28newbie-question%29-seding-war-somewhere-else-tf3722975s177.html#a10418273 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: (newbie question) seding war somewhere else
The common approache is to use deploy to get the war to the 'deployment' location. Install is just to install into your local repository so its avaliable to other projects your working on. On 10/05/07, Arrowx7 <[EMAIL PROTECTED]> wrote: Hello, I have mevenide2 installed, and when I run lifecycle phase "install" one of the output lines is [INFO]Installing /root/sourcecode/myproject.war to /root/.m2/repository/org/myproject.war is there a way to get it to install somewhere other than /root/.m2/repository/... say /usr/local/tomcat/webapps/ ?? Do I have to add some sort of property Thank you very much in advance, looking forward to replies. -- View this message in context: http://www.nabble.com/%28newbie-question%29-seding-war-somewhere-else-tf3722975s177.html#a10417737 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
(newbie question) seding war somewhere else
Hello, I have mevenide2 installed, and when I run lifecycle phase "install" one of the output lines is [INFO]Installing /root/sourcecode/myproject.war to /root/.m2/repository/org/myproject.war is there a way to get it to install somewhere other than /root/.m2/repository/... say /usr/local/tomcat/webapps/ ?? Do I have to add some sort of property Thank you very much in advance, looking forward to replies. -- View this message in context: http://www.nabble.com/%28newbie-question%29-seding-war-somewhere-else-tf3722975s177.html#a10417737 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: A newbie question regarding mvn:site
Try deleting the maven-default-skin directory from you repo and try again. It may have been a bad download. Also, are you poiting to Central or a mirror? Sometimes the mirrors get out of sync (this is a known problem). Eric On 4/29/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: Hi. I use mvn site plugin for the 1st time. I thought this would run smoothly, however I get the following error when running "mvn site" (Maven 2.0.6): [INFO] artifact org.apache.maven.skins:maven-default-skin: checking for updates from >java.net [INFO] [ERROR] BUILD ERROR [INFO] [INFO] Unable to find skin Embedded error: Unable to store local copy of metadata: Error updating group repository metadata org.apache.maven.skins:maven-default-skin:jar:RELEASE C:\Documents and Settings\ord1\.m2\repository\org\apache\maven\skins\maven-default-skin\m aven-metadata->java.net.xml (The fil ename, directory name, or volume label syntax is incorrect) [INFO] I have no idea what the problem is. Can anyone give me a clue ... Thanks Daniel Ore -- Eric Redmond http://www.sonatype.com
A newbie question regarding mvn:site
Hi. I use mvn site plugin for the 1st time. I thought this would run smoothly, however I get the following error when running "mvn site" (Maven 2.0.6): [INFO] artifact org.apache.maven.skins:maven-default-skin: checking for updates from >java.net [INFO] [ERROR] BUILD ERROR [INFO] [INFO] Unable to find skin Embedded error: Unable to store local copy of metadata: Error updating group repository metadata org.apache.maven.skins:maven-default-skin:jar:RELEASE C:\Documents and Settings\ord1\.m2\repository\org\apache\maven\skins\maven-default-skin\m aven-metadata->java.net.xml (The fil ename, directory name, or volume label syntax is incorrect) [INFO] I have no idea what the problem is. Can anyone give me a clue ... Thanks Daniel Ore
Re: Newbie question: Building master projects with a single version number.
No. When releasing from a parent pom along with its modules, the release plugin will also update the module parent versions to the correct parent version. Its a different scenario though if you're ONLY releasing the parent pom. In which case, you have to manually update the module projects to the correct version. Hope that helps. ^_^ On 4/17/07, David C. Hicks <[EMAIL PROTECTED]> wrote: I've got a master project that contains a number of modules. I'd like to run the release:prepare goal on that master project and get the version number to filter down into the sub-projects. However, each sub-project must specify its parent, including a version number. When the release plug-in changes the version number of the master POM, won't this cause an error in the sub-projects that refer to that master POM? Is there a solution to this problem? Thanks, David - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie question: Building master projects with a single version number.
I've got a master project that contains a number of modules. I'd like to run the release:prepare goal on that master project and get the version number to filter down into the sub-projects. However, each sub-project must specify its parent, including a version number. When the release plug-in changes the version number of the master POM, won't this cause an error in the sub-projects that refer to that master POM? Is there a solution to this problem? Thanks, David - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie Question: How do I represent my current Ant builds with Maven?
Lacoste, Dana wrote: Once again, I'm far from the right person to provide "should" answers to this, but as I understand it, maven really wants one-pom:one-target:one-build-result-file ratios. As in a single directory > should build exactly one thing. BUT I do this kind of thing in several areas: build a .jar and a .zip that packages everything up in the same directory. So it _can_ be done, but as I understand it, it's not "best practice". ... Dana, Thanks for both of your replies. You've really helped me see that switching to Maven is an attainable goal, so I've decided to jump in with both feet. Well, with one foot ... I'm using it on my next project. I'm going to proceed with the plan to have one Maven project whose build product is a zip file that contains my jar containing original code, required 3rd party jars, and ancillary files. It might not be perfect but I don't currently see any flaws, and the only thing that will let me see any flaws is experience, and the only way to get experience is to get started. -- Danny MacMillan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Newbie Question: How do I represent my current Ant builds with Maven?
(extra info deleted to save space) Once again, I'm far from the right person to provide "should" answers to this, but as I understand it, maven really wants one-pom:one-target:one-build-result-file ratios. As in a single directory should build exactly one thing. BUT I do this kind of thing in several areas: build a .jar and a .zip that packages everything up in the same directory. So it _can_ be done, but as I understand it, it's not "best practice". The only catch (that I can see) is that the various published elements have to have different extensions (or different "" tags) so that there's no naming conflict. So it should definitely be possible to do what you want: make your pom build the .jar, then add the assembly code and package that up as a .zip and you'd have both published to your repository. It will work fine and reliable. But it's not "the way you're supposed to do it" if that makes sense Dana Lacoste -Original Message- From: Danny MacMillan [mailto:[EMAIL PROTECTED] Sent: Friday, April 13, 2007 3:43 PM To: Maven Users List Subject: Re: Newbie Question: How do I represent my current Ant builds with Maven? > Something like: > > Parent\pom.xml <- placeholder, effectively >jar1\pom.xml<- generates your .jar >war1\pom.xml<- generates your .war >dist1\pom.xml <- generates an assembly putting all the pieces > together >dist1\dist.xml <- descriptor > (http://maven.apache.org/plugins/maven-assembly-plugin/assembly.html) >dist1\resources <- "flat" files needed in your assembly, > referred to in the pom > Would it be 'wrong' to merge the jar1 and dist1 folders (in your example) and their corresponding poms together? The rationale for this question is that the jar being produced is nothing on its own. It's not a library or a shared component of any kind. Its reason for being is to provide an executable, which by its nature requires the contents of the resources directory. My prejudicial response to what you outline is that it seems kind of complicated, but I'm open minded and happy to revise my opinion if I understand the value in the split. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie Question: How do I represent my current Ant builds with Maven?
Lacoste, Dana wrote: I'm far from the expert in dealing with this, but Maven's "assembly" plugin will do what you need: make your staging area, populate it, and zip it up in the end. We do something similar: I need to produce an "autorun" CD image: we build, with each jar having its own directory and maven pom, and then a "packaging" pom that just generates .war files, and then another "packaging" pom that generates a .zip of the CD image. (It's much more complex than that in sheer number of components, so I can't give you a sample directory structure easily, but I'm sure someone else will speak up :) Something like: Parent\pom.xml <- placeholder, effectively jar1\pom.xml<- generates your .jar war1\pom.xml<- generates your .war dist1\pom.xml <- generates an assembly putting all the pieces together dist1\dist.xml <- descriptor (http://maven.apache.org/plugins/maven-assembly-plugin/assembly.html) dist1\resources <- "flat" files needed in your assembly, referred to in the pom Does that help? Dana Lacoste Yes, thanks. The assembly.html page you reference has certainly changed since the last time I looked at it. Last time I read it it seemed to suggest assemblies were for creating different 'views' of the same information (e.g. a source distribution, a binary distribution, etc.) Now it pretty plainly says it is the mechanism for doing exactly what I want :) The documentation on the page looks a lot more complete, too. I had considered the assembly plugin the last time I looked at this but I thought it would be counter to the design. It's good to have confirmation that this is indeed what others are using to achieve this goal. Would it be 'wrong' to merge the jar1 and dist1 folders (in your example) and their corresponding poms together? The rationale for this question is that the jar being produced is nothing on its own. It's not a library or a shared component of any kind. Its reason for being is to provide an executable, which by its nature requires the contents of the resources directory. My prejudicial response to what you outline is that it seems kind of complicated, but I'm open minded and happy to revise my opinion if I understand the value in the split. Thanks for your (astonishingly prompt) answer. -- Danny MacMillan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Newbie Question: How do I represent my current Ant builds with Maven?
I'm far from the expert in dealing with this, but Maven's "assembly" plugin will do what you need: make your staging area, populate it, and zip it up in the end. We do something similar: I need to produce an "autorun" CD image: we build, with each jar having its own directory and maven pom, and then a "packaging" pom that just generates .war files, and then another "packaging" pom that generates a .zip of the CD image. (It's much more complex than that in sheer number of components, so I can't give you a sample directory structure easily, but I'm sure someone else will speak up :) Something like: Parent\pom.xml <- placeholder, effectively jar1\pom.xml<- generates your .jar war1\pom.xml<- generates your .war dist1\pom.xml <- generates an assembly putting all the pieces together dist1\dist.xml <- descriptor (http://maven.apache.org/plugins/maven-assembly-plugin/assembly.html) dist1\resources <- "flat" files needed in your assembly, referred to in the pom Does that help? Dana Lacoste -Original Message- From: Danny MacMillan [mailto:[EMAIL PROTECTED] Sent: Friday, April 13, 2007 2:42 PM To: [EMAIL PROTECTED] Subject: Newbie Question: How do I represent my current Ant builds with Maven? Hi, I've looked at Maven, read quite a bit of the documentation, and I can't figure out quite how to represent my current typical Ant build with Maven. Hopefully someone here can help me. I write a lot of console utilities in Java. These are comprised of the original code for the utility, that goes in a jar, 3rd-party libraries the utility uses, and ancillary files. Today, my typical folder structure for one of these projects looks like this: trunk (contains IDE project files, build.xml, build.properties) trunk/dist (contains content to be deployed 'as is') trunk/dist/doc (contains product documentation) trunk/dist/etc (configuration files read at runtime) trunk/dist/lib (holds 3rd-party jars) trunk/dist/... trunk/java (main source code) trunk/test (test source code) I have a 'deploy' target in my ant build that 1. copies the contents of 'dist' to a staging area for deployment 2. then compiles the java source into a jar 3. copies the jar to the staging area dist/lib directory 4. zips up the staging area The product is a zip file I can take to a client's site and deploy by unzipping and editing a few configuration files (which exist in their unedited state in trunk/dist/etc) and possibly batch files (which exist in their unedited state in trunk/dist). Everything I read about Maven suggests that there should be one build product per Maven project. Okay, I can see creating a project just for the jar holding the compiled Java code, but I can't quite wrap my head around what I'm 'supposed' to do here for the non-Java source files (the batch files, the configuration files, etc.) Switching to Maven becomes a non-starter because at a minimum I need to duplicate the functionality that is currently present in my ant builds. I would appreciate any guidance or advice you can offer. -- Danny MacMillan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie Question: How do I represent my current Ant builds with Maven?
Hi, I've looked at Maven, read quite a bit of the documentation, and I can't figure out quite how to represent my current typical Ant build with Maven. Hopefully someone here can help me. I write a lot of console utilities in Java. These are comprised of the original code for the utility, that goes in a jar, 3rd-party libraries the utility uses, and ancillary files. Today, my typical folder structure for one of these projects looks like this: trunk (contains IDE project files, build.xml, build.properties) trunk/dist (contains content to be deployed 'as is') trunk/dist/doc (contains product documentation) trunk/dist/etc (configuration files read at runtime) trunk/dist/lib (holds 3rd-party jars) trunk/dist/... trunk/java (main source code) trunk/test (test source code) I have a 'deploy' target in my ant build that 1. copies the contents of 'dist' to a staging area for deployment 2. then compiles the java source into a jar 3. copies the jar to the staging area dist/lib directory 4. zips up the staging area The product is a zip file I can take to a client's site and deploy by unzipping and editing a few configuration files (which exist in their unedited state in trunk/dist/etc) and possibly batch files (which exist in their unedited state in trunk/dist). Everything I read about Maven suggests that there should be one build product per Maven project. Okay, I can see creating a project just for the jar holding the compiled Java code, but I can't quite wrap my head around what I'm 'supposed' to do here for the non-Java source files (the batch files, the configuration files, etc.) Switching to Maven becomes a non-starter because at a minimum I need to duplicate the functionality that is currently present in my ant builds. I would appreciate any guidance or advice you can offer. -- Danny MacMillan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Antwort: Re: Newbie question: single project spanning multiple repository locations
Thanks a lot, Jo. I'll give it a try. > You will get 4 artifacts (jars probably) representing each trunk (if they > are seperately compilable).. well, not yet, but we're working on it... Regards, Dirk. "Jo Vandermeeren" <[EMAIL PROTECTED]> schrieb am 26.02.2007 22:25:55: > hi Dirk, > > You need to define each repository location as a maven module in a > pom-packaged parent project. > > Once you've done this, you could add the pom to continuum and it will create > 5 entries: 1 for each trunk and 1 for the parent. > You could easily setup continuum to enable recursive builds. This will > trigger the builds of the child modules when the parent module gets built. > But then you'll probably want to remove the continuum entries for the child > modules. > > This is very easy, because it's the default maven behaviour.. > Continuum adds by default the "non-recursive" flag to a project build, > because otherwise the child modules would be built twice. > > You will get 4 artifacts (jars probably) representing each trunk (if they > are seperately compilable).. > > Here's some information on enabling a recursive build: > http://maven.apache.org/continuum/faqs.html#build-entire-project- > recursively-from-parent > > Good luck > Jo > > > On 2/26/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > > Hi, > > > > we have an older project that -unfortunately- spans multiple repository > > locations: > > > > scm:svn://ourserver.com/repositories/ABRAHAM/basis/trunk/ > > scm:svn://ourserver.com/repositories/ABRAHAM/dev/trunk/ > > scm:svn://ourserver.com/repositories/ABRAHAM/access/trunk/ > > scm:svn://ourserver.com/repositories/ABRAHAM/hwm/trunk/ > > > > The main build file build.xml resides in basis/trunk. Before the build can > > beding, all 4 trunks must be checked out to 4 different directories side > > by side: basis/, dev/, access/ and hwm/. > > > > How can I define a single Continuum project for this kind of setup? > > > > Thanks, in advance, > > Dirk. > > > >
Re: Newbie question: single project spanning multiple repository locations
hi Dirk, You need to define each repository location as a maven module in a pom-packaged parent project. Once you've done this, you could add the pom to continuum and it will create 5 entries: 1 for each trunk and 1 for the parent. You could easily setup continuum to enable recursive builds. This will trigger the builds of the child modules when the parent module gets built. But then you'll probably want to remove the continuum entries for the child modules. This is very easy, because it's the default maven behaviour.. Continuum adds by default the "non-recursive" flag to a project build, because otherwise the child modules would be built twice. You will get 4 artifacts (jars probably) representing each trunk (if they are seperately compilable).. Here's some information on enabling a recursive build: http://maven.apache.org/continuum/faqs.html#build-entire-project-recursively-from-parent Good luck Jo On 2/26/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: Hi, we have an older project that -unfortunately- spans multiple repository locations: scm:svn://ourserver.com/repositories/ABRAHAM/basis/trunk/ scm:svn://ourserver.com/repositories/ABRAHAM/dev/trunk/ scm:svn://ourserver.com/repositories/ABRAHAM/access/trunk/ scm:svn://ourserver.com/repositories/ABRAHAM/hwm/trunk/ The main build file build.xml resides in basis/trunk. Before the build can beding, all 4 trunks must be checked out to 4 different directories side by side: basis/, dev/, access/ and hwm/. How can I define a single Continuum project for this kind of setup? Thanks, in advance, Dirk.
Newbie question: single project spanning multiple repository locations
Hi, we have an older project that -unfortunately- spans multiple repository locations: scm:svn://ourserver.com/repositories/ABRAHAM/basis/trunk/ scm:svn://ourserver.com/repositories/ABRAHAM/dev/trunk/ scm:svn://ourserver.com/repositories/ABRAHAM/access/trunk/ scm:svn://ourserver.com/repositories/ABRAHAM/hwm/trunk/ The main build file build.xml resides in basis/trunk. Before the build can beding, all 4 trunks must be checked out to 4 different directories side by side: basis/, dev/, access/ and hwm/. How can I define a single Continuum project for this kind of setup? Thanks, in advance, Dirk.
Re: Maven newbie question, problem with XDoclet destination directory
Ok found the issue. Got onto the Nabble public archive, which is fantastic and found a couple of earlier issues which identified it has been a bug in XDocllet 1.2.3 see http://jira.codehaus.org/browse/MOJO-265 XDoclet 1.2.3 Bug - MOJO-265 . The solution is to add explict destDir attributes to each of the subtasks. Pat Harms wrote: > > Hi All > > I'm relatively new to Maven so excuse what may seem like silly questions. > > At my work, I'm now working on a project that uses Maven. It has multiple > components, jars, ears, wars, etc. Up until now, it had only one EJB > project. It now has two EJB projects. Each project has its own POM file, > linked back to the Super POM. The problem I am having, is that the XDoclet > output from the "generate-sources" phase, for the two projects is ending > up > in the same destination directory, even though the destDir attribute on > the > ejbdoclet elements are different. It appears, that the second ejbdoclet > invocation ignores the destDir attribute. If I make the second destDir > attribute, rubbish it doesn't fail. If I swap the order of the EJB POMs in > the Super POM, the output is then switched. > > Am I doing something obviously wrong? Or do I need to have two separate > Maven invocations. > > Thanks in advance, for any assistance with this issue that I am having. > > Regards > Pat Harms > > -- View this message in context: http://www.nabble.com/Maven-newbie-question%2C-problem-with-XDoclet-destination-directory-tf3183998s177.html#a8838761 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Maven newbie question, problem with XDoclet destination directory
Hi All I'm relatively new to Maven so excuse what may seem like silly questions. At my work, I'm now working on a project that uses Maven. It has multiple components, jars, ears, wars, etc. Up until now, it had only one EJB project. It now has two EJB projects. Each project has its own POM file, linked back to the Super POM. The problem I am having, is that the XDoclet output from the "generate-sources" phase, for the two projects is ending up in the same destination directory, even though the destDir attribute on the ejbdoclet elements are different. It appears, that the second ejbdoclet invocation ignores the destDir attribute. If I make the second destDir attribute, rubbish it doesn't fail. If I swap the order of the EJB POMs in the Super POM, the output is then switched. Am I doing something obviously wrong? Or do I need to have two separate Maven invocations. Thanks in advance, for any assistance with this issue that I am having. Regards Pat Harms
Re: Newbie question- 3rd party jars
Maven is widely accepted. And it is an open source product from Apache (ASF). What specifically is your problem? Wayne On 12/31/06, Sagare, Vipul <[EMAIL PROTECTED]> wrote: Thank you all for your help. I guess, I have to wait until Maven becomes more widely accepted and becomes as open source product as ant or similar apache packages. Vipul. -Original Message- From: [EMAIL PROTECTED] on behalf of John Tolentino Sent: Sat 12/30/2006 11:48 PM To: Maven Users List Subject: Re: Newbie question- 3rd party jars On 12/31/06, Sagare, Vipul <[EMAIL PROTECTED]> wrote: > Thank you for quick response. Any way to do this by keeping lib directory? You can but users will always have to manually install the artifacts to their local repository. You can provide them with a batch file or script for this. Like what Wendy said, you'll benefit more though if you could setup an internal repo. With several environments and different network zones across which builds are done (dev, QA, production), the transition from ANT to Maven needs happen in more gradually to reduce the risk on quality of the software delivery. There are several projects that uses both Ant and Maven builds. They could live along with each other so you're not obligated to overhaul your projects in one go. > > In other words, without changing any directory structure, can I use Maven for full enterprise level J2EE application with EAR, JAR and WAR with WebLogic EJBs? Although you could stick with your existing directory structure, you'll benefit more if you'll follow the best practices that Maven suggests. Like with the 3rd party jars, you can create a script to regularly copy files into a Maven 2 directory structure (with Maven 2 POMs) and have it built there. Use this until you're comfortable with your migration. > > Thanks, > Vipul > > > > From: Wendy Smoak [mailto:[EMAIL PROTECTED] > Sent: Sat 12/30/2006 10:36 PM > To: Maven Users List > Subject: Re: Newbie question- 3rd party jars > > > > On 12/30/06, Sagare, Vipul <[EMAIL PROTECTED]> wrote: > > Both. > > > > I would like them to be in the classpath and in jar as well. > > Normally you would install them in your local repository and then use > a element in your pom. If you're working with other > developers, you'll probably want to establish an internal/corporate > repository so that each developer doesn't have to install them > individually. > > Then you won't need that "lib" directory at all, the jars in your > local repository will be shared across all of your Maven-built > projects. > > To include jars within a jar, I don't see a way to convince the jar > plugin to do it: >http://maven.apache.org/plugins/maven-jar-plugin/ > but you can use the assembly plugin: >http://maven.apache.org/plugins/maven-assembly-plugin/ > > -- > Wendy > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]