Re: [m2] How to deploy a war which is not includes directory WEB-INF/lib?
Hello, May the downloading wasn't completed successfully? Or please show your POM. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, It still report a error when I excute compile or antrun:run. ERROR: Internal error in the plugin manager executing goal ' org.apache.maven.plugins:maven-antrun-plugin:1.1:run': Unable to find the mojo 'org.apache.maven.plugins:maven-antrun-plugin:1.1:run' in the plugin ' org.apache.maven.plugins:maven-antrun-plugin' org/apache/tools/ant/PropertyHelper What the error means? 2007/2/13, sam [EMAIL PROTECTED]: Hi, Oh, I have excuted the antrun:run successfully just now.It may be the the problem of network. 2007/2/13, sam [EMAIL PROTECTED]: HI, I have excuted the antrun:run, but it report the same error. [INFO] [INFO] Building maven_itms Maven Webapp [INFO]task-segment: [antrun:run] [INFO] [INFO] Searching repository for plugin with prefix: 'antrun'. [INFO] artifact org.apache.maven.plugins:maven-antrun-plugin: checking for updates from central [WARN] repository metadata for: 'artifact org.apache.maven.plugins:maven-antrun-plugin' could not be retrieved from repository: central due to an error: Error transferring file [INFO] Repository 'central' will be blacklisted [ERROR] project-execute : com.novitech.itms:maven_itms:war:1.0 ( task-segment: [antrun:run] ) Diagnosis: The plugin 'org.apache.maven.plugins:maven-antrun-plugin ' does not exist or no valid version could be found FATAL ERROR: Error executing Maven for a project It is seems like the antrun plugin can't be downloaded from the central repository. 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hello, When you use maven-antrun-plugin first time, Maven would download the plugin and its dependencies to your local repo. Did you find that? Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: HI, Jiangsha,I have added the configurations you gave,but it report a error when I run compile,the error is show following: [ERROR] project-execute : com.novitech.itms:maven_itms:war:1.0 ( task-segment: [compile] ) Diagnosis: The plugin 'org.apache.maven.plugins:maven-antrun-plugin' does not exist or no valid version could be found FATAL ERROR: Error executing Maven for a project .. It seems like maven can't find the plugin of antrun. 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hello, The following scripts may can help you, build plugins plugin groupId org.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution idpackage/id phasegenerate-resources/phase configuration tasks copy file=path_to_jar_file todir=path_to_lib_directory overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin /plugins /build Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, jiangsha,can you give me the exact url of the subject about copies specific jars to specific directory?I can't find it to link to http://maven.apache.org/plugins/maven-antrun-plugin/. 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hello, How can I deploy the 3th party jar in the directory %JBOSS_HOME%server\ProjectName\lib ? I think maven-antrun-plugin may help you, http://maven.apache.org/plugins/maven-antrun-plugin/ copies specific jars to specific directory. a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, Yes ,It's feasible,I have excluded the directory WEB-INF/lib/. And How can I deploy the 3th party jar in the directory %JBOSS_HOME%server\ProjectName\lib ? 2007/2/13, mraible [EMAIL PROTECTED]: Here's how we do this in AppFuse: plugin artifactIdmaven-war-plugin/artifactId
Re: [m2] How to deploy a war which is not includes directory WEB-INF/lib?
Hi, I have searched the error via google,there is a discussion about the same error,you can have a look.http://jira.codehaus.org/browse/MANTRUN-37 My pom about build is here: build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasegenerate-resources/phase configuration tasks copy file=WEB-INF/lib/*.* todir=D:\jboss-4.0.4.GA\server\claim\lib overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId configuration warNameclaim/warName webXmlsrc/main/config/web/web.xml/webXml outputDirectory D:\jboss-4.0.4.GA\server\claim\deploy /outputDirectory warSourceExcludes WEB-INF/lib/*.jar, WEB-INF/classes/com/sinosafe/bom/, WEB-INF/classes/com/sinosafe/claim/autoclaim/biz/, WEB-INF/classes/com/sinosafe/claim/autoclaim/dto/, WEB-INF/classes/com/sinosafe/claim/autoclaim/flow/, WEB-INF/classes/com/sinosafe/claim/autoclaim/integration/, WEB-INF/classes/com/sinosafe/claim/autoclaim/util/, WEB-INF/classes/com/sinosafe/claim/common/biz/, WEB-INF/classes/com/sinosafe/claim/common/*.class, WEB-INF/classes/com/sinosafe/claim/common/dto/, WEB-INF/classes/com/sinosafe/claim/common/integration/, WEB-INF/classes/com/sinosafe/claim/life/biz/, WEB-INF/classes/com/sinosafe/claim/life/dto/, WEB-INF/classes/com/sinosafe/claim/life/flow/, WEB-INF/classes/com/sinosafe/claim/life/integration/, WEB-INF/classes/com/sinosafe/claim/property/biz/, WEB-INF/classes/com/sinosafe/claim/property/dto/, WEB-INF/classes/com/sinosafe/claim/property/flow/, WEB-INF/classes/com/sinosafe/claim/property/integration/, WEB-INF/classes/com/sinosafe/claim/setting/biz/, WEB-INF/classes/com/sinosafe/claim/setting/dto/, WEB-INF/classes/com/sinosafe/claim/setting/integration/, WEB-INF/classes/com/sinosafe/claim/test/, WEB-INF/classes/com/sinosafe/claim/util/ /warSourceExcludes webResources resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.xml/include /includes !-- there's no default value for this -- /resource resource !-- this is relative to the pom.xml directory -- directorysrc/main/config//directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include context-claim.properties /include /includes !-- there's no default value for this -- /resource resource !-- this is relative to the pom.xml directory -- directory src/main/config/printtemplate/ /directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- /resource resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.properties/include /includes !-- there's no default value for this -- /resource /webResources /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin /plugins /build 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hello, May the downloading wasn't completed successfully? Or please show your POM. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, It still report a error when I excute compile or antrun:run. ERROR: Internal error in the plugin manager executing goal ' org.apache.maven.plugins:maven-antrun-plugin:1.1:run': Unable to find the mojo 'org.apache.maven.plugins:maven-antrun-plugin:1.1:run' in the plugin ' org.apache.maven.plugins:maven-antrun-plugin' org/apache/tools/ant/PropertyHelper What the error means? 2007/2/13, sam [EMAIL PROTECTED]: Hi, Oh, I have excuted the antrun:run successfully just now.It may be the the problem of network. 2007/2/13, sam [EMAIL PROTECTED]: HI, I have excuted the antrun:run, but it report the same error. [INFO] [INFO] Building maven_itms Maven Webapp [INFO]task-segment: [antrun:run] [INFO] [INFO] Searching repository
Re: [m2] How to deploy a war which is not includes directory WEB-INF/lib?
Hi, I'm using Maven 2.0.4 + maven-antrun-plugin 1.1, all is OK. Do you use Maven 2.0.4? If can't resolve the trouble, you can download the plugin to local repo by manual, and then run mvn compile. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, I have searched the error via google,there is a discussion about the same error,you can have a look.http://jira.codehaus.org/browse/MANTRUN-37 My pom about build is here: build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasegenerate-resources/phase configuration tasks copy file=WEB-INF/lib/*.* todir=D:\jboss-4.0.4.GA\server\claim\lib overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId configuration warNameclaim/warName webXmlsrc/main/config/web/web.xml/webXml outputDirectory D:\jboss-4.0.4.GA\server\claim\deploy /outputDirectory warSourceExcludes WEB-INF/lib/*.jar, WEB-INF/classes/com/sinosafe/bom/, WEB-INF/classes/com/sinosafe/claim/autoclaim/biz/, WEB-INF/classes/com/sinosafe/claim/autoclaim/dto/, WEB-INF/classes/com/sinosafe/claim/autoclaim/flow/, WEB-INF/classes/com/sinosafe/claim/autoclaim/integration/, WEB-INF/classes/com/sinosafe/claim/autoclaim/util/, WEB-INF/classes/com/sinosafe/claim/common/biz/, WEB-INF/classes/com/sinosafe/claim/common/*.class, WEB-INF/classes/com/sinosafe/claim/common/dto/, WEB-INF/classes/com/sinosafe/claim/common/integration/, WEB-INF/classes/com/sinosafe/claim/life/biz/, WEB-INF/classes/com/sinosafe/claim/life/dto/, WEB-INF/classes/com/sinosafe/claim/life/flow/, WEB-INF/classes/com/sinosafe/claim/life/integration/, WEB-INF/classes/com/sinosafe/claim/property/biz/, WEB-INF/classes/com/sinosafe/claim/property/dto/, WEB-INF/classes/com/sinosafe/claim/property/flow/, WEB-INF/classes/com/sinosafe/claim/property/integration/, WEB-INF/classes/com/sinosafe/claim/setting/biz/, WEB-INF/classes/com/sinosafe/claim/setting/dto/, WEB-INF/classes/com/sinosafe/claim/setting/integration/, WEB-INF/classes/com/sinosafe/claim/test/, WEB-INF/classes/com/sinosafe/claim/util/ /warSourceExcludes webResources resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.xml/include /includes !-- there's no default value for this -- /resource resource !-- this is relative to the pom.xml directory -- directorysrc/main/config//directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include context-claim.properties /include /includes !-- there's no default value for this -- /resource resource !-- this is relative to the pom.xml directory -- directory src/main/config/printtemplate/ /directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- /resource resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.properties/include /includes !-- there's no default value for this -- /resource /webResources /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin /plugins /build 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hello, May the downloading wasn't completed successfully? Or please show your POM. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, It still report a error when I excute compile or antrun:run. ERROR: Internal error in the plugin manager executing goal ' org.apache.maven.plugins:maven-antrun-plugin:1.1:run': Unable to find the mojo 'org.apache.maven.plugins:maven-antrun-plugin:1.1:run' in the plugin ' org.apache.maven.plugins:maven-antrun-plugin' org/apache/tools/ant/PropertyHelper What the error means?
Maven, SCM and release builds
Hi all, Is it possible to forbid the SCM plugin to generate the complete SCM connection in a project's POM once a release build was performed? Most of the SCM settings are specified as variables in the parent POM in order to allow various developers performing release builds using alternating user ids for SCM authentication. Currently the SCM section of a released projects' POM must be changed manually by changing the user id in the connection string before performing a realease build using an alternative user id. any idea? cheers, chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
free test coverage plugin in maven
Dear all, Could you advice which test coverage plugin for maven is your favorite. Thanks! IMPORTANT NOTICE Email from OOCL is confidential and may be legally privileged. If it is not intended for you, please delete it immediately unread. The internet cannot guarantee that this communication is free of viruses, interception or interference and anyone who communicates with us by email is taken to accept the risks in doing so. Without limitation, OOCL and its affiliates accept no liability whatsoever and howsoever arising in connection with the use of this email. Under no circumstances shall this email constitute a binding agreement to carry or for provision of carriage services by OOCL, which is subject to the availability of carrier's equipment and vessels and the terms and conditions of OOCL's standard bill of lading which is also available at http://www.oocl.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
how to run a program build with maven
Hi, I have a java program which I used to build with ant. Now I switched to maven because of the easier handling of jar file dpenedencies. Unfortunately now these jar files are no longer there, they're somewhere in the repository but not inside my project directory and it's not trivial to find and add them to the classpath when I want to run my program. Is there a simple solution, how do I set the classpath in the shell to run the program? Or how do I make maven copy the jar files from the repository to somewhere I can use them? Thanks for your help, and best regards, ute - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] How to deploy a war which is not includes directory WEB-INF/lib?
HI, Yes , I use maven 2.0.4 too,and the plugin is downloaded successfully,hehe,well,I 'd like resolve the trouble after the Spring Festival,and I begin my holiday tomorrow,see you! Happy Spring Festival! 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hi, I'm using Maven 2.0.4 + maven-antrun-plugin 1.1, all is OK. Do you use Maven 2.0.4? If can't resolve the trouble, you can download the plugin to local repo by manual, and then run mvn compile. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, I have searched the error via google,there is a discussion about the same error,you can have a look .http://jira.codehaus.org/browse/MANTRUN-37 My pom about build is here: build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasegenerate-resources/phase configuration tasks copy file=WEB-INF/lib/*.* todir=D:\jboss-4.0.4.GA\server\claim\lib overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId configuration warNameclaim/warName webXmlsrc/main/config/web/web.xml/webXml outputDirectory D:\jboss-4.0.4.GA\server\claim\deploy /outputDirectory warSourceExcludes WEB-INF/lib/*.jar, WEB-INF/classes/com/sinosafe/bom/, WEB-INF/classes/com/sinosafe/claim/autoclaim/biz/, WEB-INF/classes/com/sinosafe/claim/autoclaim/dto/, WEB-INF/classes/com/sinosafe/claim/autoclaim/flow/, WEB-INF/classes/com/sinosafe/claim/autoclaim/integration/, WEB-INF/classes/com/sinosafe/claim/autoclaim/util/, WEB-INF/classes/com/sinosafe/claim/common/biz/, WEB-INF/classes/com/sinosafe/claim/common/*.class, WEB-INF/classes/com/sinosafe/claim/common/dto/, WEB-INF/classes/com/sinosafe/claim/common/integration/, WEB-INF/classes/com/sinosafe/claim/life/biz/, WEB-INF/classes/com/sinosafe/claim/life/dto/, WEB-INF/classes/com/sinosafe/claim/life/flow/, WEB-INF/classes/com/sinosafe/claim/life/integration/, WEB-INF/classes/com/sinosafe/claim/property/biz/, WEB-INF/classes/com/sinosafe/claim/property/dto/, WEB-INF/classes/com/sinosafe/claim/property/flow/, WEB-INF/classes/com/sinosafe/claim/property/integration/, WEB-INF/classes/com/sinosafe/claim/setting/biz/, WEB-INF/classes/com/sinosafe/claim/setting/dto/, WEB-INF/classes/com/sinosafe/claim/setting/integration/, WEB-INF/classes/com/sinosafe/claim/test/, WEB-INF/classes/com/sinosafe/claim/util/ /warSourceExcludes webResources resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.xml/include /includes !-- there's no default value for this -- /resource resource !-- this is relative to the pom.xml directory -- directorysrc/main/config//directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include context-claim.properties /include /includes !-- there's no default value for this -- /resource resource !-- this is relative to the pom.xml directory -- directory src/main/config/printtemplate/ /directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- /resource resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/classes//targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.properties/include /includes !-- there's no default value for this -- /resource /webResources /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin /plugins /build 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hello, May the downloading wasn't completed successfully? Or please show your POM. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, It still report a error when I excute compile or antrun:run. ERROR: Internal error in the plugin manager executing goal '
Re: how to run a program build with maven
Hi Ute You can use the Maven 2 Exec plugin... http://mojo.codehaus.org/exec-maven-plugin/ Although there is a bug which will prevent you passing parameters to the application. Alternatively the dependency plugin will copy your jar files to a folder. Try running: mvn dependency:copy-dependencies Your dependencies will all be copied to: target\dependency\ Hope this solves your problem, Patrick On 13/02/07, Ute Platzer [EMAIL PROTECTED] wrote: Hi, I have a java program which I used to build with ant. Now I switched to maven because of the easier handling of jar file dpenedencies. Unfortunately now these jar files are no longer there, they're somewhere in the repository but not inside my project directory and it's not trivial to find and add them to the classpath when I want to run my program. Is there a simple solution, how do I set the classpath in the shell to run the program? Or how do I make maven copy the jar files from the repository to somewhere I can use them? Thanks for your help, and best regards, ute - 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: [m2] how to run a program build with maven
Hello, Or how do I make maven copy the jar files from the repository to somewhere I can use them? I used the approach. dependency-maven-plugin(http://mojo.codehaus.org/dependency-maven-plugin/) may help you. The plugin can copy all dependencies from the repository to a specific location. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang Ute Platzer-2 wrote: Hi, I have a java program which I used to build with ant. Now I switched to maven because of the easier handling of jar file dpenedencies. Unfortunately now these jar files are no longer there, they're somewhere in the repository but not inside my project directory and it's not trivial to find and add them to the classpath when I want to run my program. Is there a simple solution, how do I set the classpath in the shell to run the program? Or how do I make maven copy the jar files from the repository to somewhere I can use them? Thanks for your help, and best regards, ute - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/how-to-run-a-program-build-with-maven-tf3219341s177.html#a8940592 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: [m2] Getting SNAPSHOT information into a webapp
Hi Mark, I'm having the same requirement. I'm wondering if you have found a solution on how to access the snapshot timestamp value. Thanks, - Hans Mark Chaimungkalanont wrote: Guys, We're using Maven2 and wanted to know the best way to get version information (including the SNAPSHOT timestamp, e.g. 1-0-SNAPSHOT-20050622 or sth) into a webapp that was built with the mvn package? My guess is that there is a property ${maven.snapshot.version} or something that we can use to generate a properties file so that the app can read this information. Perhaps a filter copy plugin against one of the goals? Does anything know any references around this area? Have anyone got examples they can share? Thanks, Mark C - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/-m2--Getting-SNAPSHOT-information-into-a-webapp-tf184s177.html#a8940653 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: [m2] How to deploy a war which is not includes directory WEB-INF/lib?
Hi, I think you can make a simply project to test the plugin. And run mvn compile. The following scripts can be used, project modelVersion4.0.0/modelVersion groupIdtest/groupId artifactIdtest/artifactId packagingpom/packaging version1.0-SNAPSHOT/version build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasegenerate-resources/phase configuration tasks copy file=path_to_test_file todir=path_to_test_dir overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin /plugins /build /project Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: HI, Yes , I use maven 2.0.4 too,and the plugin is downloaded successfully,hehe,well,I 'd like resolve the trouble after the Spring Festival,and I begin my holiday tomorrow,see you! Happy Spring Festival! 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hi, I'm using Maven 2.0.4 + maven-antrun-plugin 1.1, all is OK. Do you use Maven 2.0.4? If can't resolve the trouble, you can download the plugin to local repo by manual, and then run mvn compile. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, I have searched the error via google,there is a discussion about the same error,you can have a look .http://jira.codehaus.org/browse/MANTRUN-37 My pom about build is here: build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasegenerate-resources/phase configuration tasks copy file=WEB-INF/lib/*.* todir=D:\jboss-4.0.4.GA\server\claim\lib overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId configuration warNameclaim/warName webXmlsrc/main/config/web/web.xml/webXml outputDirectory D:\jboss-4.0.4.GA\server\claim\deploy /outputDirectory warSourceExcludes WEB-INF/lib/*.jar, WEB-INF/classes/com/sinosafe/bom/, WEB-INF/classes/com/sinosafe/claim/autoclaim/biz/, WEB-INF/classes/com/sinosafe/claim/autoclaim/dto/, WEB-INF/classes/com/sinosafe/claim/autoclaim/flow/, WEB-INF/classes/com/sinosafe/claim/autoclaim/integration/, WEB-INF/classes/com/sinosafe/claim/autoclaim/util/, WEB-INF/classes/com/sinosafe/claim/common/biz/, WEB-INF/classes/com/sinosafe/claim/common/*.class, WEB-INF/classes/com/sinosafe/claim/common/dto/, WEB-INF/classes/com/sinosafe/claim/common/integration/, WEB-INF/classes/com/sinosafe/claim/life/biz/, WEB-INF/classes/com/sinosafe/claim/life/dto/, WEB-INF/classes/com/sinosafe/claim/life/flow/, WEB-INF/classes/com/sinosafe/claim/life/integration/, WEB-INF/classes/com/sinosafe/claim/property/biz/, WEB-INF/classes/com/sinosafe/claim/property/dto/, WEB-INF/classes/com/sinosafe/claim/property/flow/, WEB-INF/classes/com/sinosafe/claim/property/integration/, WEB-INF/classes/com/sinosafe/claim/setting/biz/, WEB-INF/classes/com/sinosafe/claim/setting/dto/, WEB-INF/classes/com/sinosafe/claim/setting/integration/, WEB-INF/classes/com/sinosafe/claim/test/, WEB-INF/classes/com/sinosafe/claim/util/ /warSourceExcludes webResources resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.xml/include /includes !-- there's no default value for this -- /resource resource !-- this is relative to the pom.xml directory --
Re: free test coverage plugin in maven
Cobertura. Raphaël 2007/2/13, [EMAIL PROTECTED] [EMAIL PROTECTED]: Dear all, Could you advice which test coverage plugin for maven is your favorite. Thanks! IMPORTANT NOTICE Email from OOCL is confidential and may be legally privileged. If it is not intended for you, please delete it immediately unread. The internet cannot guarantee that this communication is free of viruses, interception or interference and anyone who communicates with us by email is taken to accept the risks in doing so. Without limitation, OOCL and its affiliates accept no liability whatsoever and howsoever arising in connection with the use of this email. Under no circumstances shall this email constitute a binding agreement to carry or for provision of carriage services by OOCL, which is subject to the availability of carrier's equipment and vessels and the terms and conditions of OOCL's standard bill of lading which is also available at http://www.oocl.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[m2eclipse] m2 plugin for eclipse
Hi, after I installed the m2 plugin for eclipse from http://m2eclipse.codehaus.org/ http://m2eclipse.codehaus.org/ , eclipse is prompting me to enter username/password when starting the workbench. Asking several times: *Enter Network UserID and Password* --- Please login to see the content of the JSR 264 Expert Group pages Username: [] Password: [] [ OK ] [Cancel] There are two problems with this: If I don't close this window fast enough, or let eclipse startup in the background, my whole machine hangs. The window system is somehow messed up by this modal dialog. I cannot even reboot or shutdown, but have to switch off the PC, not nice... Second, I don't know for which site I should enter username and password. Of course the projects are related to JSR264, but I'm not stating JSR 264 Expert Group anywhere in my pom files! [EMAIL PROTECTED] /cygdrive/c/USERS/My Development/ossj/java.net/jsr264-private $ find . -type f -name '*.xml' -exec grep -H JSR 264 Expert Group {} \; Above command doesn't return anything. Any comments on that are welcome :) Andreas Ebbert-Karroum Senior Software Design Engineer - Nokia Networks Services / Middleware phone: +49-211-94123928, fax: +49-211-94123838 Heltorfer Straße 1, 40472 Düsseldorf, Germany This message is confidential. If you have received this message in error, please delete it from your system. You should not copy it for any purpose, or disclose its contents to any other person. Internet communications are not secure and therefore Nokia GmbH does not accept legal responsibility for the contents of this message as it has been transmitted over a public network. Thank you. Nokia GmbH, Nokia Networks is a German Company. Further information about the Company is available from its principal offices at Heltorferstrasse 1, D-40472, Düsseldorf, Germany and from the website at http://www.nokia.com/
Re: Can anyone explain this code
Make sure you take a look at the relevant Plexus code before assuming there's a problem with this bit of Maven code: http://svn.plexus.codehaus.org/browse/~raw,r=1756/plexus/trunk/plexus-utils/src/main/java/org/codehaus/plexus/util/introspection/ReflectionValueExtractor.java http://svn.plexus.codehaus.org/browse/~raw,r=1980/plexus/trunk/plexus-utils/src/main/java/org/codehaus/plexus/util/StringUtils.java There's more, you'll just need to follow the import statements. Wayne On 2/13/07, Jiaqi Guo [EMAIL PROTECTED] wrote: Hi there, I'm trying to find out the build-in variables for a maven2 plugin and found the following code in http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.4/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java line 217: ... else if ( expression.startsWith( plugin ) ) { try { int pathSeparator = expression.indexOf( / ); PluginDescriptor pluginDescriptor = mojoDescriptor.getPluginDescriptor(); if ( pathSeparator 0 ) { String pathExpression = expression.substring( 1, pathSeparator ); value = ReflectionValueExtractor.evaluate( pathExpression, pluginDescriptor ); value = value + expression.substring( pathSeparator ); } else { value = ReflectionValueExtractor.evaluate( expression.substring( 1 ), pluginDescriptor ); } } catch ( Exception e ) { // TODO: don't catch exception throw new ExpressionEvaluationException( Error evaluating plugin parameter expression: + expression, e ); } } ... If I didn't miss anything this code make the value of any parameter expression starting with plugin to be null for sure, which will cause PluginParameterException in org.apache.maven.plugin.DefaultPluginManager.checkRequiredParameters(DefaultPluginManager.java:809). Same thing happens to settings and project. Is this a bug of maven-2.0.4? Is there any way to get pluginDescriptor in Mojo? Regards -- Jiaqi Guo http://www.cyclopsgroup.org [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: Need to bounce OC4J during re-deployment
On 2/12/07, Erik Drolshammer [EMAIL PROTECTED] wrote: Chris Russell wrote: In order to redeploy my application I need to: 1. Undeploy app 2. Bounce OC4J instance 3. Deploy app Is there a way to accomplish this with Continuum? So far, my only thought is to write a Cron job to undeploy and restart oc4j, then let Continuum build, test and deploy. Have you looked at the cargo-maven plugin? It seems to have at least som support for OC4j. http://docs.codehaus.org/display/CARGO/Oc4J+9.x -- Regards Erik Drolshammer the cargo plugin does not support remote deployments to OC4J.I had to use the combination of the maven-antrun-plugin and the oc4j_remote_deploy.jar to do a remote deployment with my continuum builds. -- Jeff Mutonho Cape Town South Africa GoogleTalk : ejbengine Skype: ejbengine Registered Linux user number 366042
Re: Maven, SCM and release builds
On 2/13/07, Christian Sauer [EMAIL PROTECTED] wrote: Hi all, Is it possible to forbid the SCM plugin to generate the complete SCM connection in a project's POM once a release build was performed? Most of the SCM settings are specified as variables in the parent POM in order to allow various developers performing release builds using alternating user ids for SCM authentication. Currently the SCM section of a released projects' POM must be changed manually by changing the user id in the connection string before performing a realease build using an alternative user id. This has been already reported as an issue in JIRA, see http://jira.codehaus.org/browse/MRELEASE-128. So far I don't know a solution. Regards, Tomek - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Maven Wagon Provider File
Hello everybody, I try to install an internal repository. Before to go further, I'd like to test the repository I've created (on my local file system) I know that there is the Maven Wagon Provider File API but I have difficulties to use it. Is it possible to have tips to use this API ? Thanks in advance. Fred
Re: [m2] how to run a program build with maven
Good day, And as for finding the artifacts that you need, you may want to use Archiva. Cheers, Franz pkimber wrote: Hi Ute You can use the Maven 2 Exec plugin... http://mojo.codehaus.org/exec-maven-plugin/ Although there is a bug which will prevent you passing parameters to the application. Alternatively the dependency plugin will copy your jar files to a folder. Try running: mvn dependency:copy-dependencies Your dependencies will all be copied to: target\dependency\ Hope this solves your problem, Patrick On 13/02/07, Ute Platzer [EMAIL PROTECTED] wrote: Hi, I have a java program which I used to build with ant. Now I switched to maven because of the easier handling of jar file dpenedencies. Unfortunately now these jar files are no longer there, they're somewhere in the repository but not inside my project directory and it's not trivial to find and add them to the classpath when I want to run my program. Is there a simple solution, how do I set the classpath in the shell to run the program? Or how do I make maven copy the jar files from the repository to somewhere I can use them? Thanks for your help, and best regards, ute - 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] -- View this message in context: http://www.nabble.com/how-to-run-a-program-build-with-maven-tf3219341s177.html#a8941446 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: [m2] How to deploy a war which is not includes directory WEB-INF/lib?
Good day, Try something like mvn -cpu install ( -cpu will check for plugin updates ). Cheers, Franz jiangshachina wrote: Hi, I think you can make a simply project to test the plugin. And run mvn compile. The following scripts can be used, project modelVersion4.0.0/modelVersion groupIdtest/groupId artifactIdtest/artifactId packagingpom/packaging version1.0-SNAPSHOT/version build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasegenerate-resources/phase configuration tasks copy file=path_to_test_file todir=path_to_test_dir overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin /plugins /build /project Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: HI, Yes , I use maven 2.0.4 too,and the plugin is downloaded successfully,hehe,well,I 'd like resolve the trouble after the Spring Festival,and I begin my holiday tomorrow,see you! Happy Spring Festival! 2007/2/13, jiangshachina [EMAIL PROTECTED]: Hi, I'm using Maven 2.0.4 + maven-antrun-plugin 1.1, all is OK. Do you use Maven 2.0.4? If can't resolve the trouble, you can download the plugin to local repo by manual, and then run mvn compile. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang 秋秋 wrote: Hi, I have searched the error via google,there is a discussion about the same error,you can have a look .http://jira.codehaus.org/browse/MANTRUN-37 My pom about build is here: build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasegenerate-resources/phase configuration tasks copy file=WEB-INF/lib/*.* todir=D:\jboss-4.0.4.GA\server\claim\lib overwrite=true / /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId configuration warNameclaim/warName webXmlsrc/main/config/web/web.xml/webXml outputDirectory D:\jboss-4.0.4.GA\server\claim\deploy /outputDirectory warSourceExcludes WEB-INF/lib/*.jar, WEB-INF/classes/com/sinosafe/bom/, WEB-INF/classes/com/sinosafe/claim/autoclaim/biz/, WEB-INF/classes/com/sinosafe/claim/autoclaim/dto/, WEB-INF/classes/com/sinosafe/claim/autoclaim/flow/, WEB-INF/classes/com/sinosafe/claim/autoclaim/integration/, WEB-INF/classes/com/sinosafe/claim/autoclaim/util/, WEB-INF/classes/com/sinosafe/claim/common/biz/, WEB-INF/classes/com/sinosafe/claim/common/*.class, WEB-INF/classes/com/sinosafe/claim/common/dto/, WEB-INF/classes/com/sinosafe/claim/common/integration/, WEB-INF/classes/com/sinosafe/claim/life/biz/, WEB-INF/classes/com/sinosafe/claim/life/dto/, WEB-INF/classes/com/sinosafe/claim/life/flow/, WEB-INF/classes/com/sinosafe/claim/life/integration/, WEB-INF/classes/com/sinosafe/claim/property/biz/, WEB-INF/classes/com/sinosafe/claim/property/dto/, WEB-INF/classes/com/sinosafe/claim/property/flow/, WEB-INF/classes/com/sinosafe/claim/property/integration/, WEB-INF/classes/com/sinosafe/claim/setting/biz/, WEB-INF/classes/com/sinosafe/claim/setting/dto/, WEB-INF/classes/com/sinosafe/claim/setting/integration/, WEB-INF/classes/com/sinosafe/claim/test/, WEB-INF/classes/com/sinosafe/claim/util/ /warSourceExcludes webResources resource !-- this is relative to the pom.xml directory -- directorysrc/main/config/web//directory targetPathWEB-INF/targetPath filteringtrue/filtering !-- the list has a default value of ** -- includes include*.xml/include /includes !-- there's no default value for this --
Re: [m2] Dependency management by license (type)
Good day, There's none that I know of. Cheers, Franz Trevor Torrez wrote: Is there a way, or are there some features in planning, to manage dependencies based on the license? What I would like is a report of licenses used by all dependencies (transitives included) and perhaps a means to reject (or warn the user about) certain license types, or only allow a build with certain license types. There should also be a means to specify what to do if the license type is invalid or missing; both as a default specification and on a case by case basis. Thanks -- View this message in context: http://www.nabble.com/Dependency-management-by-license-%28type%29-tf3214896s177.html#a8941895 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: [m2] profiles / text substitution
Good day to you, los, Do something like this project ... build resources resource directorysrc/main/config/directory includes includehibernate.cfg.xml/include /includes filteringtrue/filtering /resource /resources /build profiles profile iddev/id activation property nameenv/name valuedev/value /property /activation build filters filtersrc/main/filters/connection-dev.properties/filter /filters /build /profile profile idprod/id activation property nameenv/name valueprod/value /property /activation build filters filtersrc/main/filters/connection-prod.properties/filter /filters /build /profile /profiles /project The filtering is done using filter files ( see [1] ), while the filter file to be used depends on which profile is activated. You can user property activation to specify which profile to use ( see [2] ). This is assuming that your directory structure is something like this... . `-- src `-- main |-- filters ||-- connection-dev.properties |`-- connection-prod.properties `-- config `-- hibernate.cfg.xml Cheers, Franz [1] http://maven.apache.org/plugins/maven-resources-plugin/examples/filter.html [2] http://docs.codehaus.org/display/MAVENUSER/Profiles moraleslos wrote: I would like to use maven profiles in the pom but would like someway to combine this with text substitution. Basically I would like to have one generic hibernate configuration file that has a ${connection} ready for runtime text substitution. Then I would have 2 external files that contains the appropriate connection properties, e.g. connection-dev.properties and connection-prod.properties. I would like to profile these directly in the pom, and then invoke maven in the command line specifying the appropriate profile. So, for example, when I do this-- mvn -Denv=dev package-- I would like maven to package my hibernate config file, substituting the ${connection} with that found in connection-dev.properties. Is there a way to do this with maven profiles? Thanks in advance! -los -- View this message in context: http://www.nabble.com/profiles---text-substitution-tf3217012s177.html#a8942185 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, SCM and release builds
Hi, thank you very much for the hint. cheers, chris -Original Message- From: Tomasz Pik [EMAIL PROTECTED] To: Maven Users List users@maven.apache.org Date: Tue, 13 Feb 2007 11:00:48 +0100 Subject: Re: Maven, SCM and release builds On 2/13/07, Christian Sauer [EMAIL PROTECTED] wrote: Hi all, Is it possible to forbid the SCM plugin to generate the complete SCM connection in a project's POM once a release build was performed? Most of the SCM settings are specified as variables in the parent POM in order to allow various developers performing release builds using alternating user ids for SCM authentication. Currently the SCM section of a released projects' POM must be changed manually by changing the user id in the connection string before performing a realease build using an alternative user id. This has been already reported as an issue in JIRA, see http://jira.codehaus.org/browse/MRELEASE-128. So far I don't know a solution. Regards, Tomek - 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: [m2] Can I get MavenProject instance of plugin itself within a Mojo?
Good day to you, Jiaqi, See the http://docs.codehaus.org/display/MAVENUSER/Mojo+Developer+Cookbook; section in [1]. Cheers, Franz [1] http://docs.codehaus.org/display/MAVENUSER/Mojo+Developer+Cookbook Jiaqi Guo wrote: I need some of the maven2 plugin's dependencies during execute() method of a Mojo. In maven1 there's ${plugin.get...} that I can use in jelly script, how can I do similar thing in maven2 Mojo class? Thanks in advance. I've tryed printing out getPluginContext() but it seems to return empty Map. Regards -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/Can-I-get-MavenProject-instance-of-plugin-itself-within-a-Mojo--tf3217048s177.html#a8942573 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: [m2] Error getting POM - Failed to resolve artifact
Good day, Try adding [1] ( or your proxy to it ) to your pluginRepository ( not just in your repostiroy ) in your settings.xml or in the poms using the snapshot plugins. From your stack trace, it seems to me that [2] is the only pluginRepository known to your builds. Cheers, Franz [1] http://people.apache.org/maven-snapshot-repository [2] http://repo1.maven.org/maven2 Siegmann Daniel, NY wrote: Several people at my location have suddenly begun having build failures whenever an Apache plugin snapshot needs to be downloaded to their local repository. This includes key plugins such as org.apache.maven.plugins:maven-resources-plugin. When I removed the plugin from my local repository I encountered the same error: Project ID: org.apache.maven.plugins:maven-resources-plugin Reason: Error getting POM for 'org.apache.maven.plugins:maven-resources-plugin' from the repository: Failed to resolve artifact, possibly due to a repository list that is not appropriately equipped for this artifact's metadata. org.apache.maven.plugins:maven-resources-plugin:pom:2.3-SNAPSHOT from the specified remote repositories: central (http://repo1.maven.org/maven2) We have an installation of maven-proxy set as a mirror of central, codehaus, and apache.snapshots. This has worked fine in the past, and the artifact was already present on the proxy (having been downloaded successfully in the past). I tried removing the artifact from the proxy. Maven attempted to fetch the artifact from the proxy, and the proxy logs show it was downloaded from people.apache.org and cached successfully. But Maven still complains. Any ideas what could be causing this? It's a rather serious problem, since it blocks all use of Maven when it crops up. :( We're using Sun JDK 1.4.2_05 and Maven 2.0.4 (and have been for some time). I have included a full trace below, though I didn't not see any information of use: + Error stacktraces are turned on. Maven version: 2.0.4 [DEBUG] Building Maven user-level plugin registry from: 'D:\Profiles\SIE01876\.m2\plugin-registry.xml' [DEBUG] Building Maven global-level plugin registry from: 'd:\projects\tools\maven\2.0.4\conf\plugin-registry.xml' [INFO] Scanning for projects... [DEBUG] com.fja.pm:productmachine:jar:4.00_059 (selected for null) [DEBUG] Retrieving parent-POM: org.apache.maven.wagon:wagon-providers::1.0-beta-2 for project: null:wagon-ftp:jar:1.0-beta-2 from the repository. [DEBUG] Retrieving parent-POM: org.apache.maven.wagon:wagon::1.0-beta-2 for project: null:wagon-providers:pom:null from the repository. [DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::4 for project: org.apache.maven.wagon:wagon:pom:1.0-beta-2 from the repository. [DEBUG] Retrieving parent-POM: org.apache:apache::3 for project: org.apache.maven:maven-parent:pom:4 from the repository. [DEBUG] org.apache.maven.wagon:wagon-ftp:jar:1.0-beta-2:runtime (selected for runtime) [DEBUG] commons-net:commons-net:jar:1.4.1:runtime (selected for runtime) [DEBUG] oro:oro:jar:2.0.8:runtime (selected for runtime) [DEBUG] Retrieving parent-POM: org.apache.maven.wagon:wagon::1.0-beta-2 for project: null:wagon-provider-api:jar:1.0-beta-2 from the repository. [DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::4 for project: org.apache.maven.wagon:wagon:pom:1.0-beta-2 from the repository. [DEBUG] Retrieving parent-POM: org.apache:apache::3 for project: org.apache.maven:maven-parent:pom:4 from the repository. [DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-beta-2:runtime (selected for runtime) [DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (selected for runtime) [INFO] [INFO] Building Product Machine [INFO]task-segment: [test] [INFO] [DEBUG] maven-resources-plugin: resolved to version 2.3-SNAPSHOT from repository central [DEBUG] Skipping disabled repository central [DEBUG] maven-resources-plugin: using locally installed snapshot [DEBUG] Skipping disabled repository central [INFO] [ERROR] BUILD ERROR [INFO] [INFO] Error building POM (may not be this project's POM). Project ID: org.apache.maven.plugins:maven-resources-plugin Reason: Error getting POM for 'org.apache.maven.plugins:maven-resources-plugin' from the repository: Failed to resolve artifact, possibly due to a repository li st that is not appropriately equipped for this artifact's metadata. org.apache.maven.plugins:maven-resources-plugin:pom:2.3-SNAPSHOT from the specified remote repositories: central (http://repo1.maven.org/maven2) [INFO]
Re: Maven, SCM and release builds
Hi! There is a workaround: Specify a parent pom which holds the SCM information. This way, the SCM info replacement will actually not be part of your pom. scm connection scm:cvs:pserver:${cvs.username}:[EMAIL PROTECTED]:/home/cvsroot:${project.groupId}/ /connection developerConnection/ /scm We used the project.groupId as CVS module name to unify the handling. LieGrü, strub --- Christian Sauer [EMAIL PROTECTED] schrieb: Hi, thank you very much for the hint. cheers, chris -Original Message- From: Tomasz Pik [EMAIL PROTECTED] To: Maven Users List users@maven.apache.org Date: Tue, 13 Feb 2007 11:00:48 +0100 Subject: Re: Maven, SCM and release builds On 2/13/07, Christian Sauer [EMAIL PROTECTED] wrote: Hi all, Is it possible to forbid the SCM plugin to generate the complete SCM connection in a project's POM once a release build was performed? Most of the SCM settings are specified as variables in the parent POM in order to allow various developers performing release builds using alternating user ids for SCM authentication. Currently the SCM section of a released projects' POM must be changed manually by changing the user id in the connection string before performing a realease build using an alternative user id. This has been already reported as an issue in JIRA, see http://jira.codehaus.org/browse/MRELEASE-128. So far I don't know a solution. Regards, Tomek - 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] ___ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Can anyone explain this code
Good day to you, Jiaqi, Why do you say that it will be evaluted to null? Cheers, Franz Jiaqi Guo wrote: Hi there, I'm trying to find out the build-in variables for a maven2 plugin and found the following code in http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.4/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java line 217: ... else if ( expression.startsWith( plugin ) ) { try { int pathSeparator = expression.indexOf( / ); PluginDescriptor pluginDescriptor = mojoDescriptor.getPluginDescriptor(); if ( pathSeparator 0 ) { String pathExpression = expression.substring( 1, pathSeparator ); value = ReflectionValueExtractor.evaluate( pathExpression, pluginDescriptor ); value = value + expression.substring( pathSeparator ); } else { value = ReflectionValueExtractor.evaluate( expression.substring( 1 ), pluginDescriptor ); } } catch ( Exception e ) { // TODO: don't catch exception throw new ExpressionEvaluationException( Error evaluating plugin parameter expression: + expression, e ); } } ... If I didn't miss anything this code make the value of any parameter expression starting with plugin to be null for sure, which will cause PluginParameterException in org.apache.maven.plugin.DefaultPluginManager.checkRequiredParameters(DefaultPluginManager.java:809). Same thing happens to settings and project. Is this a bug of maven-2.0.4? Is there any way to get pluginDescriptor in Mojo? Regards -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/Can-anyone-explain-this-code-tf3218981s177.html#a8942925 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, SCM and release builds
Hi Mark, Mark Struberg wrote on Tuesday, February 13, 2007 12:38 PM: Hi! There is a workaround: Specify a parent pom which holds the SCM information. This way, the SCM info replacement will actually not be part of your pom. scm connection scm:cvs:pserver:${cvs.username}:[EMAIL PROTECTED]:/ho me/cvsroot:${project.groupId}/ /connection developerConnection/ /scm We used the project.groupId as CVS module name to unify the handling. This does not help a lot, since the release plugin will modify the URLs with the the expanded values of the properties. - Jörg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
extended build version numbers
Hi all, I've noticed that artifacts deployed by continuum server do have extended version number... In the POM file the version specified is 1.0-SNAPSHOT but in the repository I'm getting artifacts like my-module-1.0-20070213.093006-5.jar. It causes that a module from repository handled by continuum is being loaded while a newer module (which is named 1.0-SNAPSHOT) is already deployed to my local repository by local mvn build... Could you suggest what would be a best practice to handle this? Thanks in advance, Wojtek -- Posluchaj plyty i wyjedz do Paryza! kliknij http://link.interia.pl/f1a10
RE: hibernate3-maven-plugin hbm2ddl always try to connect
Hello Miso Still after adding the export flag set to false, still tries to connect? Regards Johann Reyes -Original Message- From: Michal Hlavac [mailto:[EMAIL PROTECTED] Sent: Sunday, February 11, 2007 10:04 AM To: Maven Users List Subject: Re: hibernate3-maven-plugin hbm2ddl always try to connect Dňa Ne 11. Február 2007 Alejandro Scandroli napísal: Hi Michal Try adding this to your configuration: exportfalse/export I think it will still try to connect to the database (you always need a live connection) but i won't execute the generated statements against the database. hello Alejandro... Why does it need live connection?? thanks, miso - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Query in continuum
hi, i have a query regarding Continuum where the maven project is added and the application is built. Can we add individual projects into continuum and how to add those Can anyone please suggest steps to do the same.
RE: Maven 2.1 timeline?
Thanks Dennis, Is there a snapshot build available somewhere? Regards, Brian -Original Message- From: Dennis Lundberg [mailto:[EMAIL PROTECTED] Sent: Monday, February 12, 2007 6:09 PM To: Maven Users List Subject: Re: Maven 2.1 timeline? Brian, It is correct that there were discussions at the time *not* to fix this until Maven 2.1 was released. That has since changed. The current trunk of the site-plugin works fine with Maven 2.0.x. -- Dennis Lundberg [EMAIL PROTECTED] wrote: Thanks Stephane, I appreciate the response. It appears others that have experienced my problem find it time-consuming to rebuild the site plugin to due many dependancies also needing to be rebuilt. I'd much rather wait until the fix has been released offically, and the JIRA issue states that won't happen until Maven 2.1 is released due to some other dependancy. Does anyone know the answer to my original question, when 2.1 will be released? Regards, Brian -Original Message- From: Stephane Nicoll [mailto:[EMAIL PROTECTED] Sent: Saturday, February 10, 2007 4:52 AM To: Maven Users List Subject: Re: Maven 2.1 timeline? Hi, On 2/9/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Sorry if this has been asked, but any idea when Maven 2.1 will be release? I'm running into the site + jxr problem (http://jira.codehaus.org/browse/MSITE-138) which won't be fixed in the 2.0.x branch. I don't understand. It's a plugin issue and it's fixed (see MISTE-138). You can rebuild the site plugin from trunk, it has nothing to do with a Maven distribution release. Cheers, Stéphane Regards, Brian Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - 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] Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - 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] Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required
Maven 1.1 for aspectj project
Hi How to build aspectj project with maven 1.1? Can anyone suggest useful link and dependency files required?
RE: Maven, SCM and release builds
Hi Jörg! The key difference is that the SCM section is in the PARENT POM and not in the modules POM. And the parent pom will not be checked in automatically by the release plugin if you only make a release:prepare and release:perform on that single module. LieGrü, strub --- Jörg Schaible [EMAIL PROTECTED] schrieb: Hi Mark, Mark Struberg wrote on Tuesday, February 13, 2007 12:38 PM: Hi! There is a workaround: Specify a parent pom which holds the SCM information. This way, the SCM info replacement will actually not be part of your pom. scm connection scm:cvs:pserver:${cvs.username}:[EMAIL PROTECTED]:/ho me/cvsroot:${project.groupId}/ /connection developerConnection/ /scm We used the project.groupId as CVS module name to unify the handling. This does not help a lot, since the release plugin will modify the URLs with the the expanded values of the properties. - Jörg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ___ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Maven 1.1 for aspectj project
Did you look at the AspectJ plugin? -Original Message- From: Build Admin [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 8:26 AM To: Maven users list Subject: Maven 1.1 for aspectj project Hi How to build aspectj project with maven 1.1? Can anyone suggest useful link and dependency files required? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Maven 1.1 for aspectj project
hi, IF you have patience, i'll post a pom.xml as soon as i get home my app using aspectj for maven1.1...now i have converted it to maven2 it's a webap though hth marco On 2/13/07, Build Admin [EMAIL PROTECTED] wrote: Hi How to build aspectj project with maven 1.1? Can anyone suggest useful link and dependency files required?
I need help with cargo-maven2-plugin.
Hi All, I need help with cargo-maven2-plugin. I have jboss-4.0.5.GA installed on my testcip server. I am trying to deploy a war webapp to jboss with cargo-maven-plugin. Related part of the pom.xml is below: build plugin groupIdorg.codehaus.cargo/groupId artifactIdcargo-maven2-plugin/artifactId version0.2/version configuration container containerIdjboss4x/containerId typeremote/type /container configuration typeruntime/type properties cargo.hostnametestcip/cargo.hostname cargo.servlet.port8080/cargo.servlet.port cargo.rmi.port8009/cargo.rmi.port /properties /configuration deployer typeremote/type deployables deployable groupIdcom.aspone.baydonhill.customer/groupId artifactIdbaydonline/artifactId typewar/type /deployable /deployables /deployer /configuration /plugin /plugins /build The produced artifact is located under c:/baydonhill/customer/target/ directory. It seems plugin cannot see file:C%3A%5Cbaydonhill%5Ccustomer%5Ctarget%5Cbaydonline-1.0-SNAPSHOT.war. I am using windows XP and Maven version: 2.0.4. I am not sure what I am doing wrong? I am getting the following exception: Many thanks in advance. Maruf C:\baydonhill\customermvn -e cargo:deploy + Error stacktraces are turned on. [INFO] Scanning for projects... [INFO] Searching repository for plugin with prefix: 'cargo'. [INFO] - --- [INFO] Building Baydonline webapp [INFO]task-segment: [cargo:deploy] [INFO] - --- [INFO] [cargo:deploy] [INFO] [ERROR] FATAL ERROR [INFO] [INFO] Failed to deploy to [http://testcip:8080/jmx-console/HtmlAdaptor?action=i nvokeOpByNamename=jboss.system:service%3DMainDeployermethodName=deployargType =java.net.URLarg0=file:C%3A%5Cbaydonhill%5Ccustomer%5Ctarget%5Cbaydonline-1.0-S NAPSHOT.war] Server returned HTTP response code: 500 for URL: http://testcip:8080/jmx-console /HtmlAdaptor?action=invokeOpByNamename=jboss.system:service%3DMainDeployermeth odName=deployargType=java.net.URLarg0=file:C%3A%5Cbaydonhill%5Ccustomer%5Ctarg et%5Cbaydonline-1.0-SNAPSHOT.war [INFO] [INFO] Trace org.codehaus.cargo.container.ContainerException: Failed to deploy to [http://tes tcip:8080/jmx-console/HtmlAdaptor?action=invokeOpByNamename=jboss.system:servic e%3DMainDeployermethodName=deployargType=java.net.URLarg0=file:C%3A%5Cbaydonh ill%5Ccustomer%5Ctarget%5Cbaydonline-1.0-SNAPSHOT.war] at org.codehaus.cargo.container.jboss.internal.JdkHttpURLConnection.conn ect(JdkHttpURLConnection.java:57) at org.codehaus.cargo.container.jboss.JBossJMXDeployer.invokeURL(JBossJM XDeployer.java:154) at org.codehaus.cargo.container.jboss.JBossJMXDeployer.deploy(JBossJMXDe - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Getting SNAPSHOT information into a webapp
Here's the source for my homebrew plugin to add a version file to my artifacts. It's just writing a date and hostname, but you can easily change it to include other information such as version. package com.vms.maven; import java.io.File; import java.io.FileOutputStream; import java.io.PrintStream; import java.net.InetAddress; import java.text.SimpleDateFormat; import java.util.Date; import org.apache.maven.plugin.AbstractMojo; import org.apache.maven.plugin.MojoExecutionException; import org.apache.maven.project.MavenProject; /** * Goal which creates/updates a version file * * @goal versionPage * @phase generate-resources */ public class VersionMojo extends AbstractMojo { /** * @parameter default-value=version.html */ private String filename; /** * @parameter default-value=MM/dd/ HH:mm:ss */ private String dateFormat; /** * @parameter expression=${project} * @required @readonly */ protected MavenProject project; public void execute() throws MojoExecutionException { String outputDirectory; if (jar.equals(project.getPackaging())) { outputDirectory = project.getBuild().getDirectory() + /classes; } else { outputDirectory = project.getBuild().getDirectory() + / + project.getBuild().getFinalName(); } File directory = new File(outputDirectory); if (!directory.exists()) { directory.mkdirs(); } String fullFilename = outputDirectory + / + filename; File versionFile = new File(fullFilename); if (versionFile.exists()) { versionFile.delete(); } SimpleDateFormat formatter = new SimpleDateFormat(dateFormat); try { String versionString = built + formatter.format(new Date()) + on + InetAddress.getLocalHost().getHostName(); FileOutputStream output = new FileOutputStream(fullFilename); new PrintStream(output).println(versionString); output.close(); getLog().info(Wrote version \ + versionString + \ to file + fullFilename); } catch (Exception e) { throw new MojoExecutionException(FAILURE, e); } } } -Steve hdockter wrote: Hi Mark, I'm having the same requirement. I'm wondering if you have found a solution on how to access the snapshot timestamp value. Thanks, - Hans Mark Chaimungkalanont wrote: Guys, We're using Maven2 and wanted to know the best way to get version information (including the SNAPSHOT timestamp, e.g. 1-0-SNAPSHOT-20050622 or sth) into a webapp that was built with the mvn package? My guess is that there is a property ${maven.snapshot.version} or something that we can use to generate a properties file so that the app can read this information. Perhaps a filter copy plugin against one of the goals? Does anything know any references around this area? Have anyone got examples they can share? Thanks, Mark C - 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]
Maven2 replacement for maven.repo.remote?
Hi, I need to support the deployment of artifiacts to three separate repositories: development, staged, and certified. In maven1 I did this by overriding the variables maven.repo.remote and maven.repo.list in a script. How should I do this in maven2? Here's what I really want: When a developer does a deploy the artifiacts go to the development repo. When a developer does release:perform the artifiacts go the development and staged repos. When a cert person does deploy the artifacts go to the cert repo. Thanks, Christopher Helck Thank you for being part of it. The information contained in this e-mail is confidential. This e-mail is intended only for the stated addressee. If you are not an addressee, you must not disclose, copy, circulate or in any other way use or rely on the information contained in this e-mail. if you have received this e-mail in error, please inform us immediately and delete it and all copies from your system. EBS Dealing Resources International Limited. Registered address: 2 Broadgate, London EC2M 7UR, United Kingdom. Registered number 2669861. EBS Dealing Resources, Inc, registered in Delaware. Address: Harborside Financial Center, 1100 Plaza Five, 12th Floor Jersey City, New Jersey 07311-4996 and One upper Pond road, Building F - Floor 3, Parsippany, NJ 07054, USA. EBS Dealing Resources Japan Limited, a Japanese Corporation. Address: Asteer Kayabacho Bldg, 6th Floor, 1-6-1, Shinkawa, Chuo-Ku, Tokyo 104-0033, Japan.
[OT][ANN] REMINDER: JAVAWUG 24 Web Framework Smackdown :: Skills Matter :: 19/Feb/2007
Hi All The Java Web User Group (JAVAWUG, LONDON) is holding a web framework smackdown BOF 24 at Skills Matter's offices in London on 19 Feb 2007. At the moment we have representatives for RIFE, Spring MVC, and standard API. Hey! If someone wants to rock the house with Struts 2 or Wicket demos and ``represent'' their framework to the fullest then come on down. We always need more people! http://jroller.com/page/javawug?entry=javawug_24_web_framework_smackdown Have fun. Get ready to rumble! (Register directly here http://www.skillsmatter.com/javawug ) We also have some JavaPolis Bags to give away. http://jroller.com/comments/javawug?anchor=bof_24_javawug_free_javapolis COMING SOON (1) Grid Computing Talk / Tangasol (2) Flex / Adobe -- Peter Pilgrim, JUG Leader, JAVAWUG (The Java Web Users Group) [e] 2004, ``Java Champion'' :: http://jroller.com/page/javawug/ :: __ |__| ___ ___ __ _ __ | \__ \\ \/ /\__ \\ \/ \/ / | \/ ___\ | |/ __ \\ / / __ \\ /| | / /_/ /\__| ( /\_/ ( /\/\_/ |/\___ / \__|\/ \//_/ https://java-champions.dev.java.net/ Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. UBS Limited is a company registered in England Wales under company number 2035362, whose registered office is at 1 Finsbury Avenue, London, EC2M 2PP, United Kingdom. UBS AG (London Branch) is registered as a branch of a foreign company under number BR004507, whose registered office is at 1 Finsbury Avenue, London, EC2M 2PP, United Kingdom. UBS Clearing and Execution Services Limited is a company registered in England Wales under company number 03123037, whose registered office is at 1 Finsbury Avenue, London, EC2M 2PP, United Kingdom. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] maven embedder
Hi Franz, I'm looking at the 2.0.4 sources (that's what I'm using) and I see MavenEmbedder.readModel() declaring throws XmlPullParserException D. On 2/12/07, franz see [EMAIL PROTECTED] wrote: Good day, Odd. I just tried it and it works fine with me. Also, I have just checked the source code of MavenEmbedder() and it does not use XmlPullParserException, so I am not sure why it was looking for that. Are you sure your debugging the right line? Cheers, Franz Dmitry Beransky-3 wrote: Hi Franz, If I only add the embedder, i get a long list of NoClassDefFoundError, which goes away only when I counter balance by an equally long list of included jars. The very first error I get is this: Exception in thread main java.lang.NoClassDefFoundError: org/codehaus/plexus/util/xml/pull/XmlPullParserException at org.dembel.maven.MavenUtils.createEmbedder(MavenUtils.java:53) at Main.main(Main.java:14) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90) Where MavenUtils.createEmbedder() looks like this: public static MavenEmbedder createEmbedder() { MavenEmbedder embedder = new MavenEmbedder(); return embedder; } thanks Dmitry On 2/11/07, franz see [EMAIL PROTECTED] wrote: Good day to you, Dmitry, AFAIK, It should be enough to add the maven-embedder artifact to your pom's dependencies for it to run. Why, what error are you getting? Cheers, Franz Dmitry Beransky-3 wrote: Hi, I'm not sure if this message is more appropriate here or on the dev list. Please advise for future messages. What other maven run-time libraries do I need in order to use the embedder? Thanks Dmitry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/maven-embedder-tf3209782s177.html#a8917783 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] -- View this message in context: http://www.nabble.com/maven-embedder-tf3209782s177.html#a8938749 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: [m2] how to run a program build with maven
Use the newer version at apache: http://maven.apache.org/plugins/maven-dependency-plugin -Original Message- From: jiangshachina [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 3:55 AM To: users@maven.apache.org Subject: Re: [m2] how to run a program build with maven Hello, Or how do I make maven copy the jar files from the repository to somewhere I can use them? I used the approach. dependency-maven-plugin(http://mojo.codehaus.org/dependency-maven-plugin /) may help you. The plugin can copy all dependencies from the repository to a specific location. Happy Spring Festival :-) a cup of Java, cheers! Sha Jiang Ute Platzer-2 wrote: Hi, I have a java program which I used to build with ant. Now I switched to maven because of the easier handling of jar file dpenedencies. Unfortunately now these jar files are no longer there, they're somewhere in the repository but not inside my project directory and it's not trivial to find and add them to the classpath when I want to run my program. Is there a simple solution, how do I set the classpath in the shell to run the program? Or how do I make maven copy the jar files from the repository to somewhere I can use them? Thanks for your help, and best regards, ute - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/how-to-run-a-program-build-with-maven-tf3219341s17 7.html#a8940592 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: Can I get MavenProject instance of plugin itself within a Mojo?
Hi, Add this to your mojo: /** * @parameter expression=${project} * @readonly */ private MavenProject project; See guides about plugin development in http://maven.apache.org/guides/index.html Regards, Jan -Original Message- From: Jiaqi Guo [mailto:[EMAIL PROTECTED] Sent: Monday, February 12, 2007 11:22 PM To: users@maven.apache.org Subject: Can I get MavenProject instance of plugin itself within a Mojo? I need some of the maven2 plugin's dependencies during execute() method of a Mojo. In maven1 there's ${plugin.get...} that I can use in jelly script, how can I do similar thing in maven2 Mojo class? Thanks in advance. I've tryed printing out getPluginContext() but it seems to return empty Map. Regards -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Tento e-mail je urcen pouze pro jeho adresata/adresaty a muze obsahovat duverne informace, jejichz ochrana muze byt vyzadovana pravnimi predpisy. Jestlize jste zpravu obdrzel(a) omylem, neprodlene informujte jejiho odesilatele a tuto zpravu, jeji prilohy a pripadne kopie ihned vymazte. Jakakoli forma uziti, zverejneni, reprodukce, kopirovani, distribuce a sireni teto zpravy je v takovem pripade zakazana. Komercni banka, a.s., neodpovida za mozne skody zpusobene neuplnym prenosem, moznou modifikaci ci zpozdenim teto zpravy behem prenosu od odesilatele k adresatovi. This e-mail transmission is intended solely for the ordinary user of the e-mail address to which it was addressed. It may contain legally privileged and/or confidential information. If you have received this e-mail in error or are not an intended recipient please inform the sender with-out delay and delete this e-mail, attachments and possible copies immediately. The unauthorised use, disclosure, distribution and/or copying of this e-mail or any information it contains is prohibited. Komercni banka, a. s., does not accept liability for any damage caused by incomplete transmission, possible modification or delay of this e-mail during the transmission from the sender to the recipient. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to run a program build with maven
On 13/02/07, Ute Platzer [EMAIL PROTECTED] wrote: Hi, I have a java program which I used to build with ant. Now I switched to maven because of the easier handling of jar file dpenedencies. Unfortunately now these jar files are no longer there, they're somewhere in the repository but not inside my project directory and it's not trivial to find and add them to the classpath when I want to run my program. Is there a simple solution, how do I set the classpath in the shell to run the program? There are a least two good solutions (and most probably even more) : 1) use the exec-maven-plugin and use the java goal which will run your app in the maven vm, and is very useful during development (http://mojo.codehaus.org/exec-maven-plugin) 2) a somewhat better solution is to use the appassembler plugin which generates unix and windows scripts for you with all your classpaths and more (http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/) Or how do I make maven copy the jar files from the repository to somewhere I can use them? the appassembler i mentioned above will do this for you, copying them to your target directory for easy packaging with the assembler plugin later Thanks for your help, and best regards, ute - 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 1.1 for aspectj project
On 13/02/07, Marco Mistroni [EMAIL PROTECTED] wrote: hi, IF you have patience, i'll post a pom.xml as soon as i get home my app using aspectj for maven1.1...now i have converted it to maven2 for maven2 you could use this plugin : http://mojo.codehaus.org/aspectj-maven-plugin it's a webap though Would not matter. Just put the aspectj pluging configuration in your modules containing source and everything shoould work fine hth marco On 2/13/07, Build Admin [EMAIL PROTECTED] wrote: Hi How to build aspectj project with maven 1.1? Can anyone suggest useful link and dependency files required? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Maven2 replacement for maven.repo.remote?
Helck, Christopher [EMAIL PROTECTED] writes: Hi, I need to support the deployment of artifiacts to three separate repositories: development, staged, and certified. In maven1 I did this by overriding the variables maven.repo.remote and maven.repo.list in a script. How should I do this in maven2? Here's what I really want: When a developer does a deploy the artifiacts go to the development repo. When a developer does release:perform the artifiacts go the development and staged repos. When a cert person does deploy the artifacts go to the cert repo. Hello, Did you set up the distributionManagement part of your project's pom ? It is where you define what to do for artifact's deployment. You can then use profiles to define several deployment target according to your plans. HTH -- OQube software engineering \ génie logiciel Arnaud Bailly, Dr. \web http://www.oqube.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Maven vs source control
What's the difference between Maven and version control repositories when you're using both? Maven has its repository, but so does my version control. As I'm fairly new to this, could somebody explain the division of responsibility between Maven and version control specifically? e.g. Once you've organized your project in the Maven hierarchy, what do you do then? What to do about JARs which are in the Maven repository? Is it possible to version everything in Maven using source control, including the library repository? -- View this message in context: http://www.nabble.com/Maven-vs-source-control-tf3221731s177.html#a8947855 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 vs source control
On Tue, February 13, 2007 6:40 pm, lightbulb432 wrote: What's the difference between Maven and version control repositories when you're using both? Maven has its repository, but so does my version control. repository is the word used in both cases to describe the data store of record for each system, but a maven repository doesn't work anything like a version control repository, and vice versa. They aren't the same thing. In a version control system, a repository is the place where all the versions of the source being stored is kept. In maven, the repository is a big directory tree where jar files[1] are stored, in such a way that the jar files can be referenced quickly and easily by maven. Is it possible to version everything in Maven using source control, including the library repository? No[2], there is little point in doing this. [1] Or other files, maven repos can contain artifacts other than jar, but jar is most common. [2] Ok, theoretically yes, but only when you version control server can behave like a webserver. Regards, Graham -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Maven vs source control
Thanks for your answer. Could you expand on why there's little point in versioning things in Maven. I guess maybe I can understand why for the library repository (is it because it in itself is almost versioned?), but what about everything else in Maven? e.g. your project tree that you're developing with the source code, configuration files, etc... I'm not sure what you meant by there might be a point to versioning everything in Maven using source control only when you version control server can behave like a webserver Graham Leggett wrote: On Tue, February 13, 2007 6:40 pm, lightbulb432 wrote: What's the difference between Maven and version control repositories when you're using both? Maven has its repository, but so does my version control. repository is the word used in both cases to describe the data store of record for each system, but a maven repository doesn't work anything like a version control repository, and vice versa. They aren't the same thing. In a version control system, a repository is the place where all the versions of the source being stored is kept. In maven, the repository is a big directory tree where jar files[1] are stored, in such a way that the jar files can be referenced quickly and easily by maven. Is it possible to version everything in Maven using source control, including the library repository? No[2], there is little point in doing this. [1] Or other files, maven repos can contain artifacts other than jar, but jar is most common. [2] Ok, theoretically yes, but only when you version control server can behave like a webserver. Regards, Graham -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/Maven-vs-source-control-tf3221731s177.html#a8948205 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: [m2] Maven vs source control
They are completely different albeit related subjects... You have a code repository to manage versions of source files. You could perhaps attempt to use Maven without a code repository but virtually all modern development efforts will utilize some kind of code repo. You have a Maven repository to manage versions of compiled Java modules. Maven pulls code from your code repository to build the modules, which are then deployed to your Maven repository. Everything in the Maven repo is intrinsically versioned through the project object model. You can safely ignore his comment about versioning everything in Maven using source control until you fully understand these points. Then you can revisit this point, but understand that very few people in the world who are using Maven will bother to put their Maven repo under source control. Wayne On 2/13/07, lightbulb432 [EMAIL PROTECTED] wrote: Thanks for your answer. Could you expand on why there's little point in versioning things in Maven. I guess maybe I can understand why for the library repository (is it because it in itself is almost versioned?), but what about everything else in Maven? e.g. your project tree that you're developing with the source code, configuration files, etc... I'm not sure what you meant by there might be a point to versioning everything in Maven using source control only when you version control server can behave like a webserver Graham Leggett wrote: On Tue, February 13, 2007 6:40 pm, lightbulb432 wrote: What's the difference between Maven and version control repositories when you're using both? Maven has its repository, but so does my version control. repository is the word used in both cases to describe the data store of record for each system, but a maven repository doesn't work anything like a version control repository, and vice versa. They aren't the same thing. In a version control system, a repository is the place where all the versions of the source being stored is kept. In maven, the repository is a big directory tree where jar files[1] are stored, in such a way that the jar files can be referenced quickly and easily by maven. Is it possible to version everything in Maven using source control, including the library repository? No[2], there is little point in doing this. [1] Or other files, maven repos can contain artifacts other than jar, but jar is most common. [2] Ok, theoretically yes, but only when you version control server can behave like a webserver. Regards, Graham -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/Maven-vs-source-control-tf3221731s177.html#a8948205 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]
[m2] artifacts are not resolved when mirror is not available
Hi all, I am trying to setup an internal Maven mirror for our company using Proximity. Proximity seems to work for the predefined repositories. I still having trouble with defining additional repositories (Proximity fails to start when those additional repositories are added...). Went home and tried to do a build. The mirror on my company's internal network is not available and Maven cannot download its artifacts :-( Any suggestion? Adrian. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Access dependency properties inside pom.
Good day to you, franz I really don't know how is the best way to do it, but I need to try something to solve my problem. How I must do it? What is the right way? Thanks... On 2/13/07, franz see [EMAIL PROTECTED] wrote: Good day to you, Marcos, I do not know if this is the best way to to do it, but you may want to take a look at the Storing Properties section of [1]. Cheers, Franz [1] http://docs.codehaus.org/display/MAVENUSER/Mojo+Developer+Cookbook Marcos Silva Pereira wrote: Hello, I figured out what is wrong with my configuration: I was trying to use properties in a different life cycle (clean). So, I have try to change somethings in my Mojo and in pom.xml. Now I have the following combo: /** * @goal properties * @phase initialize * @requiresDependencyResolution * @requiresProject * */ public class EnableProjectPropertiesMojo extends AbstractMojo { ... I other words, I have added @phase tag. And my pom.xml: plugin groupIdcom.provider.maven.plugins/groupId artifactIdmaven-properties-plugin/artifactId version1.0/version executions execution phaseinitialize/phase goals goalproperties/goal /goals /execution /executions /plugin I put some logs and so I can see that the mojo was executed correctly, but I still can't access properties setted by it. So, my question is, how can a mojo set properties to maven in a way that they are disposable in pom.xml? I am using System.setProperty. Kind Regards -- Marcos Silva Pereira recife - pe [EMAIL PROTECTED] skype: marcos.silva.pereira http://blastemica.blogspot.com -- View this message in context: http://www.nabble.com/Access-dependency-properties-inside-pom.-tf3189482s177.html#a8939044 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Marcos Silva Pereira recife - pe [EMAIL PROTECTED] skype: marcos.silva.pereira http://blastemica.blogspot.com
Re: [m2] Maven vs source control
Oh, now I see the difference, being between the mgmt of source files and of compiled modules. So if you are making minor revisions of your source repository all the time, does that mean your module repository is going to get enormous (because everytime you make a tiny change in your source, that classifies as a new module altogether, and the entire project gets put in its packaged form into the Maven repo?) What's the best practice regarding what people generally do? Do they only put their source code into the Maven repo as a module when its a release, rather than just another change as part of the development process? It's slowly coming together now, thanks... Wayne Fay wrote: They are completely different albeit related subjects... You have a code repository to manage versions of source files. You could perhaps attempt to use Maven without a code repository but virtually all modern development efforts will utilize some kind of code repo. You have a Maven repository to manage versions of compiled Java modules. Maven pulls code from your code repository to build the modules, which are then deployed to your Maven repository. Everything in the Maven repo is intrinsically versioned through the project object model. You can safely ignore his comment about versioning everything in Maven using source control until you fully understand these points. Then you can revisit this point, but understand that very few people in the world who are using Maven will bother to put their Maven repo under source control. Wayne On 2/13/07, lightbulb432 [EMAIL PROTECTED] wrote: Thanks for your answer. Could you expand on why there's little point in versioning things in Maven. I guess maybe I can understand why for the library repository (is it because it in itself is almost versioned?), but what about everything else in Maven? e.g. your project tree that you're developing with the source code, configuration files, etc... I'm not sure what you meant by there might be a point to versioning everything in Maven using source control only when you version control server can behave like a webserver Graham Leggett wrote: On Tue, February 13, 2007 6:40 pm, lightbulb432 wrote: What's the difference between Maven and version control repositories when you're using both? Maven has its repository, but so does my version control. repository is the word used in both cases to describe the data store of record for each system, but a maven repository doesn't work anything like a version control repository, and vice versa. They aren't the same thing. In a version control system, a repository is the place where all the versions of the source being stored is kept. In maven, the repository is a big directory tree where jar files[1] are stored, in such a way that the jar files can be referenced quickly and easily by maven. Is it possible to version everything in Maven using source control, including the library repository? No[2], there is little point in doing this. [1] Or other files, maven repos can contain artifacts other than jar, but jar is most common. [2] Ok, theoretically yes, but only when you version control server can behave like a webserver. Regards, Graham -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/Maven-vs-source-control-tf3221731s177.html#a8948205 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] -- View this message in context: http://www.nabble.com/Maven-vs-source-control-tf3221731s177.html#a8948818 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How do you tell Maven 2 to use local jars instead of trying to download them?
We are just starting to use Maven2. One or two things puzzle us, and we would be grateful for any answers. We've searched the web, looked in the mailing lists, etc. without finding an answer. We are trying to install INDIVO (indivohealth.org) by running 'MVN INSTALL' from the top level where the top POM.xml is. It downloads a lot of third party jars, then says *'Missing: -- 1) org.indivo:indivo-client-java:jar:3.0-SNAPSHOT' * regarding indivo-client-java-3.0-SNAPSHOT.jar which is in ./client/java/target/, where it should be, so Maven doesn't need to download it. How do we tell it to use the jars which are right there, rather than looking all around the world for them? Thanks for any feedback. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Maven vs source control
Generally people use the SNAPSHOT feature of Maven during development (with typically only 1 version per artifact, which is frequently updated but always uses the version SNAPSHOT), and then periodically deploy versions of modules to the Maven repo when the development team has decided to cut a new release. You can run the entire Maven compile, test, package process without actually deploying code to your repo, so we usually only deploy code when we are pushing our a new version of a module/project. Wayne On 2/13/07, lightbulb432 [EMAIL PROTECTED] wrote: Oh, now I see the difference, being between the mgmt of source files and of compiled modules. So if you are making minor revisions of your source repository all the time, does that mean your module repository is going to get enormous (because everytime you make a tiny change in your source, that classifies as a new module altogether, and the entire project gets put in its packaged form into the Maven repo?) What's the best practice regarding what people generally do? Do they only put their source code into the Maven repo as a module when its a release, rather than just another change as part of the development process? It's slowly coming together now, thanks... Wayne Fay wrote: They are completely different albeit related subjects... You have a code repository to manage versions of source files. You could perhaps attempt to use Maven without a code repository but virtually all modern development efforts will utilize some kind of code repo. You have a Maven repository to manage versions of compiled Java modules. Maven pulls code from your code repository to build the modules, which are then deployed to your Maven repository. Everything in the Maven repo is intrinsically versioned through the project object model. You can safely ignore his comment about versioning everything in Maven using source control until you fully understand these points. Then you can revisit this point, but understand that very few people in the world who are using Maven will bother to put their Maven repo under source control. Wayne On 2/13/07, lightbulb432 [EMAIL PROTECTED] wrote: Thanks for your answer. Could you expand on why there's little point in versioning things in Maven. I guess maybe I can understand why for the library repository (is it because it in itself is almost versioned?), but what about everything else in Maven? e.g. your project tree that you're developing with the source code, configuration files, etc... I'm not sure what you meant by there might be a point to versioning everything in Maven using source control only when you version control server can behave like a webserver Graham Leggett wrote: On Tue, February 13, 2007 6:40 pm, lightbulb432 wrote: What's the difference between Maven and version control repositories when you're using both? Maven has its repository, but so does my version control. repository is the word used in both cases to describe the data store of record for each system, but a maven repository doesn't work anything like a version control repository, and vice versa. They aren't the same thing. In a version control system, a repository is the place where all the versions of the source being stored is kept. In maven, the repository is a big directory tree where jar files[1] are stored, in such a way that the jar files can be referenced quickly and easily by maven. Is it possible to version everything in Maven using source control, including the library repository? No[2], there is little point in doing this. [1] Or other files, maven repos can contain artifacts other than jar, but jar is most common. [2] Ok, theoretically yes, but only when you version control server can behave like a webserver. Regards, Graham -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/Maven-vs-source-control-tf3221731s177.html#a8948205 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] -- View this message in context: http://www.nabble.com/Maven-vs-source-control-tf3221731s177.html#a8948818 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,
Re: [m2] artifacts are not resolved when mirror is not available
You need a profile for home and profile for work: mvn ... -phome mvn ... -pwork (or set work profile to active by default) As for your Proximity problems, you should probably email the Proximity Users list and get help for those issues there. Wayne On 2/13/07, Adrian Herscu [EMAIL PROTECTED] wrote: Hi all, I am trying to setup an internal Maven mirror for our company using Proximity. Proximity seems to work for the predefined repositories. I still having trouble with defining additional repositories (Proximity fails to start when those additional repositories are added...). Went home and tried to do a build. The mirror on my company's internal network is not available and Maven cannot download its artifacts :-( Any suggestion? Adrian. - 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 2.1 timeline?
Yes there is. You can find instructions for how to use SNAPSHOTs of plugins here: http://maven.apache.org/guides/development/guide-testing-development-plugins.html The most recent version is 2.0-SNAPSHOT. -- Dennis Lundberg [EMAIL PROTECTED] wrote: Thanks Dennis, Is there a snapshot build available somewhere? Regards, Brian -Original Message- From: Dennis Lundberg [mailto:[EMAIL PROTECTED] Sent: Monday, February 12, 2007 6:09 PM To: Maven Users List Subject: Re: Maven 2.1 timeline? Brian, It is correct that there were discussions at the time *not* to fix this until Maven 2.1 was released. That has since changed. The current trunk of the site-plugin works fine with Maven 2.0.x. -- Dennis Lundberg [EMAIL PROTECTED] wrote: Thanks Stephane, I appreciate the response. It appears others that have experienced my problem find it time-consuming to rebuild the site plugin to due many dependancies also needing to be rebuilt. I'd much rather wait until the fix has been released offically, and the JIRA issue states that won't happen until Maven 2.1 is released due to some other dependancy. Does anyone know the answer to my original question, when 2.1 will be released? Regards, Brian -Original Message- From: Stephane Nicoll [mailto:[EMAIL PROTECTED] Sent: Saturday, February 10, 2007 4:52 AM To: Maven Users List Subject: Re: Maven 2.1 timeline? Hi, On 2/9/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Sorry if this has been asked, but any idea when Maven 2.1 will be release? I'm running into the site + jxr problem (http://jira.codehaus.org/browse/MSITE-138) which won't be fixed in the 2.0.x branch. I don't understand. It's a plugin issue and it's fixed (see MISTE-138). You can rebuild the site plugin from trunk, it has nothing to do with a Maven distribution release. Cheers, Stéphane Regards, Brian Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - 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] Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - 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] Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses.
Re: How do you tell Maven 2 to use local jars instead of trying to download them?
If indivo-client-java is in the modules list of the top level POM (it's in the list of projects to be built when the build fires up), then it should find those libraries when the build runs at or past the 'package' phase. If it's not in the modules list, then you'll need to go into the indivo-client-java project (wherever that is), and run `mvn install` on it before proceeding with the rest of the build. -john On 2/13/07, Rod Mclaughlin [EMAIL PROTECTED] wrote: We are just starting to use Maven2. One or two things puzzle us, and we would be grateful for any answers. We've searched the web, looked in the mailing lists, etc. without finding an answer. We are trying to install INDIVO (indivohealth.org) by running 'MVN INSTALL' from the top level where the top POM.xml is. It downloads a lot of third party jars, then says *'Missing: -- 1) org.indivo:indivo-client-java:jar:3.0-SNAPSHOT' * regarding indivo-client-java-3.0-SNAPSHOT.jar which is in ./client/java/target/, where it should be, so Maven doesn't need to download it. How do we tell it to use the jars which are right there, rather than looking all around the world for them? Thanks for any feedback. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How do you tell Maven 2 to use local jars instead of trying to download them?
Got it! Thanks John Casey wrote: If indivo-client-java is in the modules list of the top level POM (it's in the list of projects to be built when the build fires up), then it should find those libraries when the build runs at or past the 'package' phase. If it's not in the modules list, then you'll need to go into the indivo-client-java project (wherever that is), and run `mvn install` on it before proceeding with the rest of the build. -john On 2/13/07, Rod Mclaughlin [EMAIL PROTECTED] wrote: We are just starting to use Maven2. One or two things puzzle us, and we would be grateful for any answers. We've searched the web, looked in the mailing lists, etc. without finding an answer. We are trying to install INDIVO (indivohealth.org) by running 'MVN INSTALL' from the top level where the top POM.xml is. It downloads a lot of third party jars, then says *'Missing: -- 1) org.indivo:indivo-client-java:jar:3.0-SNAPSHOT' * regarding indivo-client-java-3.0-SNAPSHOT.jar which is in ./client/java/target/, where it should be, so Maven doesn't need to download it. How do we tell it to use the jars which are right there, rather than looking all around the world for them? Thanks for any feedback. - 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]
Deploy to repository | Windows network file url
So I'm trying to setup a repository on a Windows shared drive. I configured my POM as: distributionManagement repository idtasna/id urlfile://host/path/to/my/Shared%20Drive/Maven/repository/url /repository /distributionManagement I run mvn deploy and get the following output: [INFO] Scanning for projects... [INFO] [INFO] Building Trade and Asset Services [INFO]task-segment: [deploy] [INFO] [INFO] [site:attach-descriptor] [INFO] [install:install] [INFO] Installing C:\Projects\Commons\tasna\pom.xml to C:\Documents and Settings\jacksoba.UBSW\.m2\repository\com\ubs\eq\tas\na\tasna\1.0-SNAPSH OT\tasna-1.0-SNAPSHOT.pom [INFO] [deploy:deploy] altDeploymentRepository = null [INFO] Retrieving previous build number from tasna Uploading: file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na /tasna/1.0-SNAPSHOT/tasna-1.0-20070213.192326-10.pom 4/6K 6/6K 6K uploaded [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'snapshot com.ubs.eq.tas.na:tasna:1.0-SNAPSHOT' [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'artifact com.ubs.eq.tas.na:tasna' [INFO] [INFO] BUILD SUCCESSFUL [INFO] [INFO] Total time: 3 seconds [INFO] Finished at: Tue Feb 13 14:23:26 EST 2007 [INFO] Final Memory: 5M/10M [INFO] But when I check my repository, the POM hasn't been updated. Any idea what is going on? I know the URL is right because I can hit file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na /tasna/1.0-SNAPSHOT/ in the Windows Explorer without issue. Thanks, Brian Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Maven 1.1 for aspectj project
Hello, as promised here's the maven.xml (in mvn 1.1 there's no pom, but you have a project.xml and a maven.xml) ?xml version=1.0? project xmlns:m=jelly:maven xmlns:ant=jelly:ant preGoal name=jsf-dist attainGoal name=clean/ ant:copy file=../properties/web-context.xml toDir=../spring overwrite=true/ attainGoal name=xdoclet:webdoclet/ attainGoal name=aspectj:compile/ /preGoal goal name=jsf-dist attainGoal name=jar:install/ /goal postGoal name=jar:install ant:property name=substitution.file location=../properties/project.properties/ ant:property file=${substitution.file} prefix=s/ ant:copy file=target/xdoclet/webdoclet/WEB-INF/web.xml toDir=${jsfapp.webdir} overwrite=true ant:filterchain ant:replacetokens ant:token key=DB_URL value=${s.db.url}/ ant:token key=DATASOURCE_POPULATOR value=${s.datasource.populator}/ ant:token key=DB_DRIVER value=${s.db.driver}/ ant:token key=DB_USER value=${s.db.user}/ ant:token key=DB_PASSWORD value=${s.db.password}/ ant:token key=DB_STOCK_URL value=${s.db.stock.url}/ ant:token key=DB_PRODUCTION value=${s.datasource.populator.production}/ ant:token key=QUARTZ_CONTEXT value=${s.quartz.context}/ /ant:replacetokens /ant:filterchain /ant:copy /postGoal /project as Kaare and other were saying, you want to have a look at aspectj plugin for maven 1.1 hth marco On 2/13/07, Kaare Nilsen [EMAIL PROTECTED] wrote: On 13/02/07, Marco Mistroni [EMAIL PROTECTED] wrote: hi, IF you have patience, i'll post a pom.xml as soon as i get home my app using aspectj for maven1.1...now i have converted it to maven2 for maven2 you could use this plugin : http://mojo.codehaus.org/aspectj-maven-plugin it's a webap though Would not matter. Just put the aspectj pluging configuration in your modules containing source and everything shoould work fine hth marco On 2/13/07, Build Admin [EMAIL PROTECTED] wrote: Hi How to build aspectj project with maven 1.1? Can anyone suggest useful link and dependency files required? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What is the default value for resource?
Can anyone tell me why I can't seem to get excludes to work for a webResource? I have the following in my pom: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId version2.0.1/version configuration warName${project.build.finalName}/warName warSourceExcludesWEB-INF/lib/log4j*.jar/warSourceExcludes webResources resource directorysrc/main/webapp/directory excludes exclude**/*.gif/exclude /excludes /resource /webResources /configuration /plugin and a directory structure like: pom.xml src main webapp images x.gif y.gif But the gifs still get get packaged in the war in the images directory. How come? Thanks, Michael On 2/9/07, sam [EMAIL PROTECTED] wrote: HI, YES! I got it clearly! thanks very much! 2007/2/9, franz see [EMAIL PROTECTED]: Good day to you, ??, The default includes means *all*. Inlcuding the cvs and .whatever files :) That is unless you specify an include, which would override the default. Meaning, if you only have configuration webResources resource !-- this is relative to the pom.xml directory -- directoryresource2//directory /resource /webResources /configuration Then all of resource2's content would be included. But if you have configuration webResources resource !-- this is relative to the pom.xml directory -- directoryresource2//directory !-- the list has a default value of ** -- includes includeimage2/*.jpg/include includes /resource /webResources /configuration Then only the jpg files under resource2/image2 would be included. So if you have something like resource2/my.txt and resource2/whatever-folder/some-other-folder/another.txt, those would not be included. But if you have something like configuration webResources resource !-- this is relative to the pom.xml directory -- directoryresource2//directory !-- the list has a default value of ** -- includes includeimage2/*.jpg/include includes !-- there's no default value for this -- excludes exclude**/*.jpg/exlude /excludes /resource /webResources /configuration Then *none* from resource2 would be included. Why? Because it's like saying get all resource2/image2/*.jpg and from those, remove the resource2/**/*.jpg :) ( note: even if you declare the excludes first, followed by the includes, the evalution of what resources to be included would still be the same ) ...That is why it is said there that exclude has a higher priority. Regarding the comments, this is relative to the pom.xml directory merely says that the directory is relative to the base directory ( the directory containing the pom.xml ). Thus, declaring directoryresource2/directory is like saying ${basedir}/resource2 ( where ${basedir} is the directory containing your pom.xml ). the list has a default value of ** on the other hand is saying that the default is includes include**/include /includes And by default, meaning, that is what it will use if you don't specify one. And as for there's no default value for this, it's saying that the exclude tag has no default value. Meaning, if you don't specify any exclude, it will not remove anything from what you included in the directory :) Umm..did I answer your question or is there some parts that are still confusing? :) Cheers, Franz 秋秋 wrote: HI, Unfortunately, I am none the wiser for default value,have a look this below: configuration webResources resource !-- this is relative to the pom.xml directory -- directoryresource2//directory !-- the list has a default value of ** -- includes includeimage2/*.jpg/include includes !-- there's no default value for this -- excludes exclude**/*.jpg/exlude /excludes /resource /webResources /configuration http://maven.apache.org/plugins/maven-war-plugin/examples/adding-filtering-webresources.html , 2007/2/9, Stephane Nicoll [EMAIL PROTECTED]: Hi, On 2/9/07, sam [EMAIL PROTECTED] wrote: Hi, I am reading http://maven.apache.org/plugins/maven-war-plugin/examples/adding-filtering-webresources.html , There are some configuration like below: configuration webResources resource !-- this is relative to the pom.xml directory -- directoryresource2/directory * !-- the list has a default value of ** -- *includes
Re: [m2] Maven vs source control
lightbulb432 wrote: Could you expand on why there's little point in versioning things in Maven. I guess maybe I can understand why for the library repository (is it because it in itself is almost versioned?), but what about everything else in Maven? e.g. your project tree that you're developing with the source code, configuration files, etc... One of the core concepts within maven is its version number scheme. Maven makes a strong distinction between released artifacts, and snapshot artifacts. Your project while you are working on it, your dev branch, is an example of a snapshot artifact - despite the fact that it probably has a version number already, every time you rebuild your code, you have replaced your previous snapshot build with your new one. Snapshot artifacts have the suffix -SNAPSHOT after the version number. Once you have released a particular tag of your project, you publish it as a released artifact, probably into a publically accessible (or publically accessible within your company) maven repository. Many many other projects have also deployed their released artifacts into public maven repositories like http://repo1.maven.org, and this code is automatically available to you as well. The key point is this: Once an artifact is published with a released version number, that artifact never changes again. Should the artifact get updated, a new release is made with a new version number, and the newer released artifact sits beside the older released artifact. This is why it's largely pointless to place jars in version control, as the jars as released and published don't change and mustn't change. Of course you could try and subvert the system and upload a replacement jar that replaces an existing released version - the trouble is, maven by design knows that released jar files don't change, and if maven has a local copy of the older jar, it will never try and download the new jar. This is why protecting write access to your maven repository in a corporate environment is generally a good idea, as you don't want a developer changing the goalposts on already released code. This same issue exists even if you do try store jars in version control, because you don't want a developer messing around there for the same reasons. I'm not sure what you meant by there might be a point to versioning everything in Maven using source control only when you version control server can behave like a webserver maven (to my knowledge) expects a maven repository to be either a directory local on the machine, or published on a webserver. In order to host a maven repository inside a version control server, the version control server must behave like a webserver, and the only version control server capable of this to my knowledge is subversion. Don't worry too much about this point - it was an aside. Regards, Graham -- smime.p7s Description: S/MIME Cryptographic Signature
Re: [m2] Maven vs source control
lightbulb432 wrote: So if you are making minor revisions of your source repository all the time, does that mean your module repository is going to get enormous (because everytime you make a tiny change in your source, that classifies as a new module altogether, and the entire project gets put in its packaged form into the Maven repo?) Yes, meaning that at some point you might want to remove very old artifacts and archive them away somewhere, when you are sure they will never be needed again. Practically speaking though, it is unlikely in most cases you would ever need to do this, as compared to typical disk partition sizes, and typical jar sizes, it takes an awful lot of versions before this becomes a problem. What's the best practice regarding what people generally do? Do they only put their source code into the Maven repo as a module when its a release, rather than just another change as part of the development process? All our source code goes into version control, and source releases are tagged in version control. We have a company-private maven repository in the form of a webserver that contains all our jar releases over time. This serves as a record of all artifacts that ever went into uat or production. This repository doesn't contain any snapshots, although it is possible to host snapshots in a repository if you want to (just watch the disk space). This means that we have at any time, both the source code, as well as the resultant binaries as released, for all modules we maintain. Source under version control, binaries in a maven repository. Maintaining all of this sounds frightening, however maven plugins exist that automate many of the tasks associated with making releases and deploying them places. This helps you avoid many of the pitfalls involved in managing releases properly, the chief pitfall being developers who bypass your rules for releases and do their own thing. Regards, Graham -- smime.p7s Description: S/MIME Cryptographic Signature
Re: Deploy to repository | Windows network file url
I've had the same problem. If you check your local disc you'll probably have a catalog named host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na/tasna/1.0-SNAPSHOT/ You need to add more slashes so that maven understand that the tagert directory is on another machine. If I remeber correctly file:/host/path will do the trick... Gaute On 2/13/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: So I'm trying to setup a repository on a Windows shared drive. I configured my POM as: distributionManagement repository idtasna/id urlfile://host/path/to/my/Shared%20Drive/Maven/repository /url /repository /distributionManagement I run mvn deploy and get the following output: [INFO] Scanning for projects... [INFO] [INFO] Building Trade and Asset Services [INFO]task-segment: [deploy] [INFO] [INFO] [site:attach-descriptor] [INFO] [install:install] [INFO] Installing C:\Projects\Commons\tasna\pom.xml to C:\Documents and Settings\jacksoba.UBSW\.m2\repository\com\ubs\eq\tas\na\tasna\1.0-SNAPSHOT\tasna- 1.0-SNAPSHOT.pom [INFO] [deploy:deploy] altDeploymentRepository = null [INFO] Retrieving previous build number from tasna Uploading: * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na/tasna/1.0-SNAPSHOT/tasna-1.0-20070213.192326-10.pom * 4/6K 6/6K 6K uploaded [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'snapshot com.ubs.eq.tas.na:tasna:1.0-SNAPSHOT' [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'artifact com.ubs.eq.tas.na:tasna' [INFO] [INFO] BUILD SUCCESSFUL [INFO] [INFO] Total time: 3 seconds [INFO] Finished at: Tue Feb 13 14:23:26 EST 2007 [INFO] Final Memory: 5M/10M [INFO] But when I check my repository, the POM hasn't been updated. Any idea what is going on? I know the URL is right because I can hit * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na/tasna/1.0-SNAPSHOT/ * in the Windows Explorer without issue. Thanks, Brian Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Deploy to repository | Windows network file url
Thanks Gaute, I tried the following combinations with no luck: file:///\\host/path file:/host/path As well as mapping \\host\path\to\my\Shared%20Drive to drive letter B: and using the following URL file:///B:/Maven/... None of which worked. Any other ideas? -Original Message- From: Gaute Lote [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 3:31 PM To: Maven Users List Subject: Re: Deploy to repository | Windows network file url I've had the same problem. If you check your local disc you'll probably have a catalog named host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na/tasna/ 1.0-SNAPSHOT/ You need to add more slashes so that maven understand that the tagert directory is on another machine. If I remeber correctly file:/host/path will do the trick... Gaute On 2/13/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: So I'm trying to setup a repository on a Windows shared drive. I configured my POM as: distributionManagement repository idtasna/id urlfile://host/path/to/my/Shared%20Drive/Maven/repository /url /repository /distributionManagement I run mvn deploy and get the following output: [INFO] Scanning for projects... [INFO] -- -- [INFO] Building Trade and Asset Services [INFO]task-segment: [deploy] [INFO] -- -- [INFO] [site:attach-descriptor] [INFO] [install:install] [INFO] Installing C:\Projects\Commons\tasna\pom.xml to C:\Documents and Settings\jacksoba.UBSW\.m2\repository\com\ubs\eq\tas\na\tasna\1.0-SNAP SHOT\tasna- 1.0-SNAPSHOT.pom [INFO] [deploy:deploy] altDeploymentRepository = null [INFO] Retrieving previous build number from tasna Uploading: * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/ na/tasna/1.0-SNAPSHOT/tasna-1.0-20070213.192326-10.pom * 4/6K 6/6K 6K uploaded [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'snapshot com.ubs.eq.tas.na:tasna:1.0-SNAPSHOT' [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'artifact com.ubs.eq.tas.na:tasna' [INFO] -- -- [INFO] BUILD SUCCESSFUL [INFO] -- -- [INFO] Total time: 3 seconds [INFO] Finished at: Tue Feb 13 14:23:26 EST 2007 [INFO] Final Memory: 5M/10M [INFO] -- -- But when I check my repository, the POM hasn't been updated. Any idea what is going on? I know the URL is right because I can hit * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/ na/tasna/1.0-SNAPSHOT/ * in the Windows Explorer without issue. Thanks, Brian Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell
Re: [m2] merging jars
for me, as an eclipse user, I do not use command line maven, so I (and other eclipse users) need to have the plugin work from the pom. Because of that, I was hoping for a pom based example in the usage page. Cheers, Andy Torsten Curdt wrote: On 30.01.2007, at 01:03, adingfelder wrote: I like the looks of minijar's createUeberJarbut their documentation is lacking. What information do you need beside this? http://mojo.codehaus.org/minijar-maven-plugin/usage.html Do you know what I need to put in my pom to make it work? You could specify that plugin via POM but you might want to just install it as you just call it on the project. maven -DartifactId=ARTIFACTID -DgroupId=GROUPID -Dversion=VERSION plugin:download http://svn.codehaus.org/mojo/tags/minijar-maven-plugin-1.0-alpha-1/ pom.xml ...will add this to the docs, thanks! cheers -- Torsten - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/merging-jars-tf3138947s177.html#a8954231 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Question on Ant Plugins
I wrote an ant plugin for Maven. As per documentation I have two files: deebee.build.xml deebee.mojos.xml I have two questions. 1. I would like to have all of my mojos in different files, importing them into the main deebee.build.xml file, something like this: project import file=afile.xml/ import file=anotherfile.xml/ /project This syntax doesn't work. Everything builds and installs but at runtime I get an error saying that afile.xml and anotherfile.xml cannot be found. 2. I can't get antcall to work. If I have this: target name=entry-point antcall target=subroutine/ /target target name=subroutine echo message=Hello!/ /target Then again everything installs correctly but I get a file not found error when execution hits the antcalll line. Any ideas? Thanks, Kevan. Kevan Dunsmore Senior Software Engineer SABRIX Inc t: 503.924.4908 f: 503.620.5756 This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information that is protected from disclosure. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message and any attachments.
Re: [m2] Access dependency properties inside pom.
Good day to you, Marcos, From [1], it says there that you can do something like public void MyMojo extends ... /** parameter expression=${project} */ private org.apache.maven.project.MavenProject mavenProject; ... public void execute() { ... mavenProject.getProperties().put( my.mojo.property, my mojo value ) ... } ... } Have you tried that already? Cheers, Franz [1] http://docs.codehaus.org/display/MAVENUSER/Mojo+Developer+Cookbook Marcos Silva Pereira wrote: Good day to you, franz I really don't know how is the best way to do it, but I need to try something to solve my problem. How I must do it? What is the right way? Thanks... On 2/13/07, franz see [EMAIL PROTECTED] wrote: Good day to you, Marcos, I do not know if this is the best way to to do it, but you may want to take a look at the Storing Properties section of [1]. Cheers, Franz [1] http://docs.codehaus.org/display/MAVENUSER/Mojo+Developer+Cookbook Marcos Silva Pereira wrote: Hello, I figured out what is wrong with my configuration: I was trying to use properties in a different life cycle (clean). So, I have try to change somethings in my Mojo and in pom.xml. Now I have the following combo: /** * @goal properties * @phase initialize * @requiresDependencyResolution * @requiresProject * */ public class EnableProjectPropertiesMojo extends AbstractMojo { ... I other words, I have added @phase tag. And my pom.xml: plugin groupIdcom.provider.maven.plugins/groupId artifactIdmaven-properties-plugin/artifactId version1.0/version executions execution phaseinitialize/phase goals goalproperties/goal /goals /execution /executions /plugin I put some logs and so I can see that the mojo was executed correctly, but I still can't access properties setted by it. So, my question is, how can a mojo set properties to maven in a way that they are disposable in pom.xml? I am using System.setProperty. Kind Regards -- Marcos Silva Pereira recife - pe [EMAIL PROTECTED] skype: marcos.silva.pereira http://blastemica.blogspot.com -- View this message in context: http://www.nabble.com/Access-dependency-properties-inside-pom.-tf3189482s177.html#a8939044 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Marcos Silva Pereira recife - pe [EMAIL PROTECTED] skype: marcos.silva.pereira http://blastemica.blogspot.com -- View this message in context: http://www.nabble.com/Access-dependency-properties-inside-pom.-tf3189482s177.html#a8955849 Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Integration-test target runs integration tests twice...
I'm having a problem binding our integration tests to the integration-test lifecycle goal. Can anyone explain why this would happen twice? Here's my pom: ?xml version=1.0 encoding=ISO-8859-1? project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion parent groupIdlty/groupId artifactIdapp/artifactId version1.0-SNAPSHOT/version /parent artifactIdrewardEngine/artifactId packagingjar/packaging version1.0-SNAPSHOT/version descriptionModule to calculate rewards/description nameReward Engine/name urlhttp://www.upromise.com/url build resources resource directorysrc/main/resources/directory filteringtrue/filtering /resource /resources plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId configuration reportsDirectory../reportsdirectory/reportsDirectory systemProperties property namecommon.properties/name value${work.dir}/common.properties/value /property property namejava.util.logging.config.file/name value ${work.dir}/utils/src/main/conf/logging.properties/value /property property namerewardEngineITest.testData.file/name value ${work.dir}/rewardEngine/src/test/resources/xml/RewardEngineITestData.xm l/value /property property namerewardEngine.config.file/name value ${work.dir}/rewardEngine/src/main/resources/xml/EngineConfiguration.xml /value /property /systemProperties includes include**/*UTest.java/include /includes /configuration /plugin /plugins /build dependencies dependency groupIdlty/groupId artifactIdlty-model/artifactId version1.0-SNAPSHOT/version /dependency dependency groupIdlty/groupId artifactIdlty-utils/artifactId version1.0-SNAPSHOT/version /dependency /dependencies profiles profile iditest-blah/id activation property namerewardEngine.iTest/name /property /activation build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId executions execution idsurefire-iTest/id phaseintegration-test/phase goals goaltest/goal /goals configuration forkModepertest/forkMode includes include**/*ITest.java/include /includes /configuration /execution /executions /plugin /plugins /build /profile /profiles /project
Maven 2 can't find plugins
I have an even more basic issue. Whenever I have a plugin in a POM.xml file, and try to use it, eg. *$ mvn xfire:wsdlgen * Maven 2 says* 'Scanning for projects... Searching repository for plugin with prefix: 'xfire'. org.apache.maven.plugins: checking for updates org.codehaus.mojo: checking for updates from central artifact org.apache.maven.plugins:maven-xfire-plugin: checking for updates from central [ERROR] BUILD ERROR The plugin 'org.apache.maven.plugins:maven-xfire-plugin' does not exist or no valid version could be found'* This is true whatever the plugin. It's not a proxy issue: it can download ordinary jars from the repository, just not plugins. For example, here is a simple bit of a POM referring to xfire-maven-plugin: build pluginManagement plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdxfire-maven-plugin/artifactId executions execution phasetest-compile/phase goals goalwsdlgen/goal /goals /execution /executions !-- this shows the default -- configuration outputDirectory${project.build.directory}/generated-sources/xfire/wsdlgen/outputDirectory configs wsdl${basedir}/src/main/resources/META-INF/xfire/services.xml/wsdl /configs /configuration /plugin /plugins /pluginManagement /build Again, I've searched the web, the mailing lists etc.. Thanks for any advice... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Maven 2 can't find plugins
Without knowing anything more about your project or seeing your pom.xml files, I assume you've declared repositories but not pluginRepositories to match. Wayne On 2/13/07, Rod Mclaughlin [EMAIL PROTECTED] wrote: I have an even more basic issue. Whenever I have a plugin in a POM.xml file, and try to use it, eg. *$ mvn xfire:wsdlgen * Maven 2 says* 'Scanning for projects... Searching repository for plugin with prefix: 'xfire'. org.apache.maven.plugins: checking for updates org.codehaus.mojo: checking for updates from central artifact org.apache.maven.plugins:maven-xfire-plugin: checking for updates from central [ERROR] BUILD ERROR The plugin 'org.apache.maven.plugins:maven-xfire-plugin' does not exist or no valid version could be found'* This is true whatever the plugin. It's not a proxy issue: it can download ordinary jars from the repository, just not plugins. For example, here is a simple bit of a POM referring to xfire-maven-plugin: build pluginManagement plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdxfire-maven-plugin/artifactId executions execution phasetest-compile/phase goals goalwsdlgen/goal /goals /execution /executions !-- this shows the default -- configuration outputDirectory${project.build.directory}/generated-sources/xfire/wsdlgen/outputDirectory configs wsdl${basedir}/src/main/resources/META-INF/xfire/services.xml/wsdl /configs /configuration /plugin /plugins /pluginManagement /build Again, I've searched the web, the mailing lists etc.. Thanks for any advice... - 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 2 can't find plugins
On Feb 13, 2007, at 17:54, Rod Mclaughlin wrote: I have an even more basic issue. Whenever I have a plugin in a POM.xml file, and try to use it, eg. *$ mvn xfire:wsdlgen * Maven 2 says* 'Scanning for projects... Searching repository for plugin with prefix: 'xfire'. org.apache.maven.plugins: checking for updates org.codehaus.mojo: checking for updates from central artifact org.apache.maven.plugins:maven-xfire-plugin: checking for updates from central [ERROR] BUILD ERROR The plugin 'org.apache.maven.plugins:maven-xfire-plugin' does not exist or no valid version could be found'* Here it says it's looking for maven-xfire-plugin, but... This is true whatever the plugin. It's not a proxy issue: it can download ordinary jars from the repository, just not plugins. For example, here is a simple bit of a POM referring to xfire-maven- plugin: build pluginManagement plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdxfire-maven-plugin/artifactId ...here you declare xfire-maven-plugin. Was that a typo (transcribe- o?), or could this be part of the problem you're seeing? -- Craig S. Cottingham [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] merging jars
On 13.02.2007, at 22:56, adingfelder wrote: for me, as an eclipse user, I do not use command line maven, so I (and other eclipse users) need to have the plugin work from the pom. No command line ...interesting. Did not think such programmers really exist ;) Well, maybe we could attach it to the packaging phase. Because of that, I was hoping for a pom based example in the usage page. I see ...well, as of now you would have to call it from the command line - but patches are welcome ;) cheers -- Torsten - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Maven 2 can't find plugins
Wayne Fay wrote: *Without knowing anything more about your project or seeing your pom.xml files, I assume you've declared repositories but not pluginRepositories to match. * Wayne Thanks. Even if I do pluginRepositories pluginRepository idcentral/id nameMaven Plugin Repository/name urlhttp://repo1.maven.org/maven2/url layoutdefault/layout snapshots enabledfalse/enabled /snapshots /pluginRepository /pluginRepositories it still says *The plugin 'org.apache.maven.plugins:maven-xfire-plugin' does not exist or no valid version could be found* *Craig S. Cottingham: Here it says it's looking for maven-xfire-plugin, but... ...here you declare xfire-maven-plugin. Was that a typo (transcribe-o?), or could this be part of the problem you're seeing? * It makes no difference whether it says artifactIdPLUGINNAME-maven-plugin or maven-PLUGINNAME-plugin in the plugin section of the POM, it always says org.apache.maven.plugins:maven-PLUGINNAME-plugin not found for any plugin. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Maven 2 can't find plugins
I've had a similar problem. It appears that Maven is able to download the pom for a plugin but not the plugin itself if you don't have pluginRepositories defined but do have repositories. If you clear everything from your local repo then attempt to download the plugin as a side-effect of your build you'll see the repo directory created and the correct pom pulled down to that directory. Maven will then fail saying that it can't find the jar. You'll see a message saying that Maven is trying to load the jar from a different repository from the one in which it found the pom (usually central). I found this problem with plugins I had written myself. It might also be something you'll see with external plugins Kevan. -Original Message- From: Wayne Fay [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 4:02 PM To: Maven Users List Subject: Re: Maven 2 can't find plugins Without knowing anything more about your project or seeing your pom.xml files, I assume you've declared repositories but not pluginRepositories to match. Wayne On 2/13/07, Rod Mclaughlin [EMAIL PROTECTED] wrote: I have an even more basic issue. Whenever I have a plugin in a POM.xml file, and try to use it, eg. *$ mvn xfire:wsdlgen * Maven 2 says* 'Scanning for projects... Searching repository for plugin with prefix: 'xfire'. org.apache.maven.plugins: checking for updates org.codehaus.mojo: checking for updates from central artifact org.apache.maven.plugins:maven-xfire-plugin: checking for updates from central [ERROR] BUILD ERROR The plugin 'org.apache.maven.plugins:maven-xfire-plugin' does not exist or no valid version could be found'* This is true whatever the plugin. It's not a proxy issue: it can download ordinary jars from the repository, just not plugins. For example, here is a simple bit of a POM referring to xfire-maven-plugin: build pluginManagement plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdxfire-maven-plugin/artifactId executions execution phasetest-compile/phase goals goalwsdlgen/goal /goals /execution /executions !-- this shows the default -- configuration outputDirectory${project.build.directory}/generated-sources/xfire/wsdl gen/outputDirectory configs wsdl${basedir}/src/main/resources/META-INF/xfire/services.xml/wsdl /configs /configuration /plugin /plugins /pluginManagement /build Again, I've searched the web, the mailing lists etc.. Thanks for any advice... - 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] This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information that is protected from disclosure. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message and any attachments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Deploy to repository | Windows network file url
Brian, This works for me: file:host/share/path Kevan. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 1:10 PM To: users@maven.apache.org Subject: RE: Deploy to repository | Windows network file url Thanks Gaute, I tried the following combinations with no luck: file:///\\host/path file:/host/path As well as mapping \\host\path\to\my\Shared%20Drive to drive letter B: and using the following URL file:///B:/Maven/... None of which worked. Any other ideas? -Original Message- From: Gaute Lote [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 3:31 PM To: Maven Users List Subject: Re: Deploy to repository | Windows network file url I've had the same problem. If you check your local disc you'll probably have a catalog named host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na/tasna/ 1.0-SNAPSHOT/ You need to add more slashes so that maven understand that the tagert directory is on another machine. If I remeber correctly file:/host/path will do the trick... Gaute On 2/13/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: So I'm trying to setup a repository on a Windows shared drive. I configured my POM as: distributionManagement repository idtasna/id urlfile://host/path/to/my/Shared%20Drive/Maven/repository /url /repository /distributionManagement I run mvn deploy and get the following output: [INFO] Scanning for projects... [INFO] -- -- [INFO] Building Trade and Asset Services [INFO]task-segment: [deploy] [INFO] -- -- [INFO] [site:attach-descriptor] [INFO] [install:install] [INFO] Installing C:\Projects\Commons\tasna\pom.xml to C:\Documents and Settings\jacksoba.UBSW\.m2\repository\com\ubs\eq\tas\na\tasna\1.0-SNAP SHOT\tasna- 1.0-SNAPSHOT.pom [INFO] [deploy:deploy] altDeploymentRepository = null [INFO] Retrieving previous build number from tasna Uploading: * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/ na/tasna/1.0-SNAPSHOT/tasna-1.0-20070213.192326-10.pom * 4/6K 6/6K 6K uploaded [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'snapshot com.ubs.eq.tas.na:tasna:1.0-SNAPSHOT' [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'artifact com.ubs.eq.tas.na:tasna' [INFO] -- -- [INFO] BUILD SUCCESSFUL [INFO] -- -- [INFO] Total time: 3 seconds [INFO] Finished at: Tue Feb 13 14:23:26 EST 2007 [INFO] Final Memory: 5M/10M [INFO] -- -- But when I check my repository, the POM hasn't been updated. Any idea what is going on? I know the URL is right because I can hit * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/ na/tasna/1.0-SNAPSHOT/ * in the Windows Explorer without issue. Thanks, Brian Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or
Re: [m2] maven embedder
On 13 Feb 07, at 10:32 AM 13 Feb 07, Dmitry Beransky wrote: Hi Franz, I'm looking at the 2.0.4 sources (that's what I'm using) and I see MavenEmbedder.readModel() declaring throws XmlPullParserException The folks I'm directly supporting for the embedder are the IDE folks. They are using the embedder from trunk. I will attempt to merge the trunk into the 2.0.6 release of Maven. If you want something then use these: http://idisk.maven.org/jvanzyl/Public/embedder/ Use the first version, that's what was used in the last release of the Maven Eclipse Integration. We're just about to release 2.0.5 and I don't have time to merge it into 2.0.5. Jason. D. On 2/12/07, franz see [EMAIL PROTECTED] wrote: Good day, Odd. I just tried it and it works fine with me. Also, I have just checked the source code of MavenEmbedder() and it does not use XmlPullParserException, so I am not sure why it was looking for that. Are you sure your debugging the right line? Cheers, Franz Dmitry Beransky-3 wrote: Hi Franz, If I only add the embedder, i get a long list of NoClassDefFoundError, which goes away only when I counter balance by an equally long list of included jars. The very first error I get is this: Exception in thread main java.lang.NoClassDefFoundError: org/codehaus/plexus/util/xml/pull/XmlPullParserException at org.dembel.maven.MavenUtils.createEmbedder (MavenUtils.java:53) at Main.main(Main.java:14) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.intellij.rt.execution.application.AppMain.main (AppMain.java:90) Where MavenUtils.createEmbedder() looks like this: public static MavenEmbedder createEmbedder() { MavenEmbedder embedder = new MavenEmbedder(); return embedder; } thanks Dmitry On 2/11/07, franz see [EMAIL PROTECTED] wrote: Good day to you, Dmitry, AFAIK, It should be enough to add the maven-embedder artifact to your pom's dependencies for it to run. Why, what error are you getting? Cheers, Franz Dmitry Beransky-3 wrote: Hi, I'm not sure if this message is more appropriate here or on the dev list. Please advise for future messages. What other maven run-time libraries do I need in order to use the embedder? Thanks Dmitry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/maven-embedder-tf3209782s177.html#a8917783 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] -- View this message in context: http://www.nabble.com/maven-embedder- tf3209782s177.html#a8938749 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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] maven embedder
Good day to you, Dmitry, You may want to take a look at your dependency tree ( do mvn project-info-reports:dependencies then go to target\site\dependencies.html ) and search for what version of plexus-utils your project is using. I checked the dependency tree of org.apache.maven:maven-embedder:2.0.4 ( see [1] ), and it's using org.codehaus.plexus:plexus-utils:1.1. If according to your dependency tree, you are not using that plexus version, you may want to declare org.codehaus.plexus:plexus-utils:1.1 as a direct dependency of your maven project ( ensuring that maven will get that version of plexus-utils instead of relying on the version it will from its transitive dependencies ). Cheers, Franz [1] http://maven.apache.org/ref/2.0.4/maven-embedder/dependencies.html Dmitry Beransky-3 wrote: Hi Franz, I'm looking at the 2.0.4 sources (that's what I'm using) and I see MavenEmbedder.readModel() declaring throws XmlPullParserException D. On 2/12/07, franz see [EMAIL PROTECTED] wrote: Good day, Odd. I just tried it and it works fine with me. Also, I have just checked the source code of MavenEmbedder() and it does not use XmlPullParserException, so I am not sure why it was looking for that. Are you sure your debugging the right line? Cheers, Franz Dmitry Beransky-3 wrote: Hi Franz, If I only add the embedder, i get a long list of NoClassDefFoundError, which goes away only when I counter balance by an equally long list of included jars. The very first error I get is this: Exception in thread main java.lang.NoClassDefFoundError: org/codehaus/plexus/util/xml/pull/XmlPullParserException at org.dembel.maven.MavenUtils.createEmbedder(MavenUtils.java:53) at Main.main(Main.java:14) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90) Where MavenUtils.createEmbedder() looks like this: public static MavenEmbedder createEmbedder() { MavenEmbedder embedder = new MavenEmbedder(); return embedder; } thanks Dmitry On 2/11/07, franz see [EMAIL PROTECTED] wrote: Good day to you, Dmitry, AFAIK, It should be enough to add the maven-embedder artifact to your pom's dependencies for it to run. Why, what error are you getting? Cheers, Franz Dmitry Beransky-3 wrote: Hi, I'm not sure if this message is more appropriate here or on the dev list. Please advise for future messages. What other maven run-time libraries do I need in order to use the embedder? Thanks Dmitry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/maven-embedder-tf3209782s177.html#a8917783 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] -- View this message in context: http://www.nabble.com/maven-embedder-tf3209782s177.html#a8938749 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] -- View this message in context: http://www.nabble.com/maven-embedder-tf3209782s177.html#a8957702 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: Deploy to repository | Windows network file url
Good day, You may want to try first with file:, then file:/, then file://, till you get to file:/ :) Not really sure what the problem is, but I've experienced that before as well. Cheers, Franz Kevan Dunsmore wrote: Brian, This works for me: file:host/share/path Kevan. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 1:10 PM To: users@maven.apache.org Subject: RE: Deploy to repository | Windows network file url Thanks Gaute, I tried the following combinations with no luck: file:///\\host/path file:/host/path As well as mapping \\host\path\to\my\Shared%20Drive to drive letter B: and using the following URL file:///B:/Maven/... None of which worked. Any other ideas? -Original Message- From: Gaute Lote [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 13, 2007 3:31 PM To: Maven Users List Subject: Re: Deploy to repository | Windows network file url I've had the same problem. If you check your local disc you'll probably have a catalog named host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/na/tasna/ 1.0-SNAPSHOT/ You need to add more slashes so that maven understand that the tagert directory is on another machine. If I remeber correctly file:/host/path will do the trick... Gaute On 2/13/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: So I'm trying to setup a repository on a Windows shared drive. I configured my POM as: distributionManagement repository idtasna/id urlfile://host/path/to/my/Shared%20Drive/Maven/repository /url /repository /distributionManagement I run mvn deploy and get the following output: [INFO] Scanning for projects... [INFO] -- -- [INFO] Building Trade and Asset Services [INFO]task-segment: [deploy] [INFO] -- -- [INFO] [site:attach-descriptor] [INFO] [install:install] [INFO] Installing C:\Projects\Commons\tasna\pom.xml to C:\Documents and Settings\jacksoba.UBSW\.m2\repository\com\ubs\eq\tas\na\tasna\1.0-SNAP SHOT\tasna- 1.0-SNAPSHOT.pom [INFO] [deploy:deploy] altDeploymentRepository = null [INFO] Retrieving previous build number from tasna Uploading: * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/ na/tasna/1.0-SNAPSHOT/tasna-1.0-20070213.192326-10.pom * 4/6K 6/6K 6K uploaded [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'snapshot com.ubs.eq.tas.na:tasna:1.0-SNAPSHOT' [INFO] Retrieving previous metadata from tasna [INFO] Uploading repository metadata for: 'artifact com.ubs.eq.tas.na:tasna' [INFO] -- -- [INFO] BUILD SUCCESSFUL [INFO] -- -- [INFO] Total time: 3 seconds [INFO] Finished at: Tue Feb 13 14:23:26 EST 2007 [INFO] Final Memory: 5M/10M [INFO] -- -- But when I check my repository, the POM hasn't been updated. Any idea what is going on? I know the URL is right because I can hit * file://host/path/to/my/Shared%20Drive/Maven/repository/com/ubs/eq/tas/ na/tasna/1.0-SNAPSHOT/ * in the Windows Explorer without issue. Thanks, Brian Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Visit our website at http://www.ubs.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and
Re: Maven 2.0.5 release plans?
On 6 Feb 07, at 11:23 AM 6 Feb 07, Thierry Lach wrote: Any idea when Maven 2.0.5 will be released? Tomorrow. Jason. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tools for automated deployment of repository artifacts?
On 9 Feb 07, at 2:31 AM 9 Feb 07, Franz Garsombke wrote: Maven is working beautifully for us...we are building code, packaging, and deploying to our proximity repository server. Does the Maven team know of any tools that are built around getting artifacts from an HTTP URL and then SCPing the file to a remote machine and running some command lines? http://svn.codehaus.org/mojo/trunk/mojo/mojo-sandbox/repositorytools- maven-plugin/ It's in the sandbox, but I've been using it for moving staged releases to production repositories. It may change, there isn't much documentation but there is a usage guide. I use it like the following: mvn repositorytools:copy-repository \ -Dsource=dain::default::file:///x1/home/dain/public_html/stage\ -Dtarget=jvanzyl::default::file:///x1/www/people.apache.org/repo/m2- ibiblio-rsync-repository -Ddeploy=true Though an http url should work fine for the source. It's not released so you'll have to build it from source. Don't ask when we're releasing it because we don't know. Jason. I would like to automate our deployments from our remote repository and was just wondering if you had come across any tools? I built an enterpise version of such a tool at my last company and it was deploying over 100 applications. Unfortunately I do not have it at my new job. Thanks in advance, Franz - Sucker-punch spam with award-winning protection. Try the free Yahoo! Mail Beta. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Maven 2 can't find plugins
Good day to you, Rod, The xfire-maven-plugin is in codehaus mojo-sandbox. So you either checkout the source and build it, or use the snapshot version deployed pluginRepository idCodehaus Snapshots/id urlhttp://snapshots.repository.codehaus.org//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository See [1]. Cheers, Franz [1] http://mojo.codehaus.org/using-sandbox-plugins.html Rod Mclaughlin-2 wrote: Wayne Fay wrote: *Without knowing anything more about your project or seeing your pom.xml files, I assume you've declared repositories but not pluginRepositories to match. * Wayne Thanks. Even if I do pluginRepositories pluginRepository idcentral/id nameMaven Plugin Repository/name urlhttp://repo1.maven.org/maven2/url layoutdefault/layout snapshots enabledfalse/enabled /snapshots /pluginRepository /pluginRepositories it still says *The plugin 'org.apache.maven.plugins:maven-xfire-plugin' does not exist or no valid version could be found* *Craig S. Cottingham: Here it says it's looking for maven-xfire-plugin, but... ...here you declare xfire-maven-plugin. Was that a typo (transcribe-o?), or could this be part of the problem you're seeing? * It makes no difference whether it says artifactIdPLUGINNAME-maven-plugin or maven-PLUGINNAME-plugin in the plugin section of the POM, it always says org.apache.maven.plugins:maven-PLUGINNAME-plugin not found for any plugin. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/Access-dependency-properties-inside-pom.-tf3189482s177.html#a8957848 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: [m2] Integration-test target runs integration tests twice...
Good day to you, EJ, What happens twice? ...May I ask for the build logs in your console? Cheers, Franz EJ Ciramella-2 wrote: I'm having a problem binding our integration tests to the integration-test lifecycle goal. Can anyone explain why this would happen twice? Here's my pom: ?xml version=1.0 encoding=ISO-8859-1? project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion parent groupIdlty/groupId artifactIdapp/artifactId version1.0-SNAPSHOT/version /parent artifactIdrewardEngine/artifactId packagingjar/packaging version1.0-SNAPSHOT/version descriptionModule to calculate rewards/description nameReward Engine/name urlhttp://www.upromise.com/url build resources resource directorysrc/main/resources/directory filteringtrue/filtering /resource /resources plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId configuration reportsDirectory../reportsdirectory/reportsDirectory systemProperties property namecommon.properties/name value${work.dir}/common.properties/value /property property namejava.util.logging.config.file/name value ${work.dir}/utils/src/main/conf/logging.properties/value /property property namerewardEngineITest.testData.file/name value ${work.dir}/rewardEngine/src/test/resources/xml/RewardEngineITestData.xm l/value /property property namerewardEngine.config.file/name value ${work.dir}/rewardEngine/src/main/resources/xml/EngineConfiguration.xml /value /property /systemProperties includes include**/*UTest.java/include /includes /configuration /plugin /plugins /build dependencies dependency groupIdlty/groupId artifactIdlty-model/artifactId version1.0-SNAPSHOT/version /dependency dependency groupIdlty/groupId artifactIdlty-utils/artifactId version1.0-SNAPSHOT/version /dependency /dependencies profiles profile iditest-blah/id activation property namerewardEngine.iTest/name /property /activation build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId executions execution idsurefire-iTest/id phaseintegration-test/phase goals goaltest/goal /goals configuration forkModepertest/forkMode includes include**/*ITest.java/include /includes /configuration /execution /executions /plugin /plugins /build /profile /profiles /project -- View this message in context: http://www.nabble.com/Integration-test-target-runs-integration-tests-twice...-tf3224387s177.html#a8958006 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: [m2] Can anyone explain this code
Hi Franz, I tried to get PluginDescriptor within a mojo and got PluginParameterException, then I started looking at this code. Assume expression is string plugin, pathSeparator is -1, the expression.substring(1) becomes lugin. Did I miss anything here? And then looking at ReflectionValueExtractor.java today, I just realized ReflectionValueExtractor.evaluate(lugin, pluginDescriptor) may work since the first argument is irrelevant if string doesn't contain '.'. But I'm more confused by the substring part of what .indexOf(/) is for. And still, in my Mojo, the parameter with expression ${plugin} is causing PluginParameterException which indicates the value of it is null. Regards -Jiaqi franz see wrote: Good day to you, Jiaqi, Why do you say that it will be evaluted to null? Cheers, Franz Jiaqi Guo wrote: Hi there, I'm trying to find out the build-in variables for a maven2 plugin and found the following code in http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.4/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java line 217: ... else if ( expression.startsWith( plugin ) ) { try { int pathSeparator = expression.indexOf( / ); PluginDescriptor pluginDescriptor = mojoDescriptor.getPluginDescriptor(); if ( pathSeparator 0 ) { String pathExpression = expression.substring( 1, pathSeparator ); value = ReflectionValueExtractor.evaluate( pathExpression, pluginDescriptor ); value = value + expression.substring( pathSeparator ); } else { value = ReflectionValueExtractor.evaluate( expression.substring( 1 ), pluginDescriptor ); } } catch ( Exception e ) { // TODO: don't catch exception throw new ExpressionEvaluationException( Error evaluating plugin parameter expression: + expression, e ); } } ... If I didn't miss anything this code make the value of any parameter expression starting with plugin to be null for sure, which will cause PluginParameterException in org.apache.maven.plugin.DefaultPluginManager.checkRequiredParameters(DefaultPluginManager.java:809). Same thing happens to settings and project. Is this a bug of maven-2.0.4? Is there any way to get pluginDescriptor in Mojo? Regards -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Can anyone explain this code
In fact, the ReflectionValueExtractor.evaluate(lugin, pluginDescriptor) does return null. The first token in while loop is lugin, which calls getLugin() of root object and returns null. I guess this is where the problem is. Maybe there should be another 'else if ( plugin.equals( expression ) )' before 'else if ( expression.startsWith( plugin ) )' . And I think I begin to understand the indexOf( / ) now. Is it to allow user to specify things like ${project.build.sourceDirectory}/some/sub/directory? Thanks -Jiaqi Jiaqi Guo wrote: Hi Franz, I tried to get PluginDescriptor within a mojo and got PluginParameterException, then I started looking at this code. Assume expression is string plugin, pathSeparator is -1, the expression.substring(1) becomes lugin. Did I miss anything here? And then looking at ReflectionValueExtractor.java today, I just realized ReflectionValueExtractor.evaluate(lugin, pluginDescriptor) may work since the first argument is irrelevant if string doesn't contain '.'. But I'm more confused by the substring part of what .indexOf(/) is for. And still, in my Mojo, the parameter with expression ${plugin} is causing PluginParameterException which indicates the value of it is null. Regards -Jiaqi franz see wrote: Good day to you, Jiaqi, Why do you say that it will be evaluted to null? Cheers, Franz Jiaqi Guo wrote: Hi there, I'm trying to find out the build-in variables for a maven2 plugin and found the following code in http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.4/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java line 217: ... else if ( expression.startsWith( plugin ) ) { try { int pathSeparator = expression.indexOf( / ); PluginDescriptor pluginDescriptor = mojoDescriptor.getPluginDescriptor(); if ( pathSeparator 0 ) { String pathExpression = expression.substring( 1, pathSeparator ); value = ReflectionValueExtractor.evaluate( pathExpression, pluginDescriptor ); value = value + expression.substring( pathSeparator ); } else { value = ReflectionValueExtractor.evaluate( expression.substring( 1 ), pluginDescriptor ); } } catch ( Exception e ) { // TODO: don't catch exception throw new ExpressionEvaluationException( Error evaluating plugin parameter expression: + expression, e ); } } ... If I didn't miss anything this code make the value of any parameter expression starting with plugin to be null for sure, which will cause PluginParameterException in org.apache.maven.plugin.DefaultPluginManager.checkRequiredParameters(DefaultPluginManager.java:809). Same thing happens to settings and project. Is this a bug of maven-2.0.4? Is there any way to get pluginDescriptor in Mojo? Regards -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Query in continuum
Hi! You can follow these steps: In your Continuum application: 1) Click the Maven 2.0x Project link on the left menu (if you're going to add a Maven 2.0 project). 2) You may specify a POM Url (e.g. http://mirrors.ibiblio.org/pub/mirrors/maven2/org/apache/maven/maven-model/2.0.4/maven-model-2.0.4.pom) or you may opt to upload a pom.xml file from your local directory, then click Add. The next page that appears will show you the project you've just added. Hope this helps. Dawn vishwanath ramaprasad wrote: hi, i have a query regarding Continuum where the maven project is added and the application is built. Can we add individual projects into continuum and how to add those Can anyone please suggest steps to do the same. -- View this message in context: http://www.nabble.com/Query-in-continuum-tf3220704s177.html#a8958323 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: [m2] maven embedder
Jason, Thanks. That worked great, however I ran into another problem. I'm using embedder to write an IntelliJ IDEA plugin and IDEA insists on using it's own JDOM library. See this discussion for reference: http://intellij.net/forums/thread.jspa?messageID=3441989 I was able to work around the problem temporarily by removing all JDOM classes from the embedder jar. I'm hoping for a more permanent solution, though. Is that possible? Thanks Dmitry The folks I'm directly supporting for the embedder are the IDE folks. They are using the embedder from trunk. I will attempt to merge the trunk into the 2.0.6 release of Maven. If you want something then use these: http://idisk.maven.org/jvanzyl/Public/embedder/ Use the first version, that's what was used in the last release of the Maven Eclipse Integration. We're just about to release 2.0.5 and I don't have time to merge it into 2.0.5. Jason. D. On 2/12/07, franz see [EMAIL PROTECTED] wrote: Good day, Odd. I just tried it and it works fine with me. Also, I have just checked the source code of MavenEmbedder() and it does not use XmlPullParserException, so I am not sure why it was looking for that. Are you sure your debugging the right line? Cheers, Franz Dmitry Beransky-3 wrote: Hi Franz, If I only add the embedder, i get a long list of NoClassDefFoundError, which goes away only when I counter balance by an equally long list of included jars. The very first error I get is this: Exception in thread main java.lang.NoClassDefFoundError: org/codehaus/plexus/util/xml/pull/XmlPullParserException at org.dembel.maven.MavenUtils.createEmbedder (MavenUtils.java:53) at Main.main(Main.java:14) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.intellij.rt.execution.application.AppMain.main (AppMain.java:90) Where MavenUtils.createEmbedder() looks like this: public static MavenEmbedder createEmbedder() { MavenEmbedder embedder = new MavenEmbedder(); return embedder; } thanks Dmitry On 2/11/07, franz see [EMAIL PROTECTED] wrote: Good day to you, Dmitry, AFAIK, It should be enough to add the maven-embedder artifact to your pom's dependencies for it to run. Why, what error are you getting? Cheers, Franz Dmitry Beransky-3 wrote: Hi, I'm not sure if this message is more appropriate here or on the dev list. Please advise for future messages. What other maven run-time libraries do I need in order to use the embedder? Thanks Dmitry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/maven-embedder-tf3209782s177.html#a8917783 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] -- View this message in context: http://www.nabble.com/maven-embedder- tf3209782s177.html#a8938749 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] - 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: [m2] Can anyone explain this code
Without getting too far into the code myself, you seem to make some very good arguments about possible problems in this code. ;-) I have no idea if this PluginParameterExpressionEvaluator class (and the referenced code in Plexus) have proper unit tests etc, but it seems like you could make a great contribution in this area if you were interested. Thanks for the comments -- keep it up! Wayne On 2/13/07, Jiaqi Guo [EMAIL PROTECTED] wrote: Hi Franz, I tried to get PluginDescriptor within a mojo and got PluginParameterException, then I started looking at this code. Assume expression is string plugin, pathSeparator is -1, the expression.substring(1) becomes lugin. Did I miss anything here? And then looking at ReflectionValueExtractor.java today, I just realized ReflectionValueExtractor.evaluate(lugin, pluginDescriptor) may work since the first argument is irrelevant if string doesn't contain '.'. But I'm more confused by the substring part of what .indexOf(/) is for. And still, in my Mojo, the parameter with expression ${plugin} is causing PluginParameterException which indicates the value of it is null. Regards -Jiaqi franz see wrote: Good day to you, Jiaqi, Why do you say that it will be evaluted to null? Cheers, Franz Jiaqi Guo wrote: Hi there, I'm trying to find out the build-in variables for a maven2 plugin and found the following code in http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.4/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java line 217: ... else if ( expression.startsWith( plugin ) ) { try { int pathSeparator = expression.indexOf( / ); PluginDescriptor pluginDescriptor = mojoDescriptor.getPluginDescriptor(); if ( pathSeparator 0 ) { String pathExpression = expression.substring( 1, pathSeparator ); value = ReflectionValueExtractor.evaluate( pathExpression, pluginDescriptor ); value = value + expression.substring( pathSeparator ); } else { value = ReflectionValueExtractor.evaluate( expression.substring( 1 ), pluginDescriptor ); } } catch ( Exception e ) { // TODO: don't catch exception throw new ExpressionEvaluationException( Error evaluating plugin parameter expression: + expression, e ); } } ... If I didn't miss anything this code make the value of any parameter expression starting with plugin to be null for sure, which will cause PluginParameterException in org.apache.maven.plugin.DefaultPluginManager.checkRequiredParameters(DefaultPluginManager.java:809). Same thing happens to settings and project. Is this a bug of maven-2.0.4? Is there any way to get pluginDescriptor in Mojo? Regards -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jiaqi Guo http://www.cyclopsgroup.org [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: [m2] Can anyone explain this code
Thanks Wayne, Although I found workaround for the tool that I'm working on, the patch for PluginParameterExpression could be really simple: sh-3.1$ svn diff Index: maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java === --- maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java (revision 507376) +++ maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java (working copy) @@ -193,6 +193,10 @@ { value = project.getExecutionProject(); } +else if ( plugin.equals( expression ) ) +{ +value = mojoDescriptor.getPluginDescriptor(); +} else if ( expression.startsWith( project ) ) { try So I'll go ahead and create Jira issue with patch. Maven is always one of my favorite open source projects since it was under Turbine. I'm very pleased to continue to make contribution. Regards -Jiaqi Wayne Fay wrote: Without getting too far into the code myself, you seem to make some very good arguments about possible problems in this code. ;-) I have no idea if this PluginParameterExpressionEvaluator class (and the referenced code in Plexus) have proper unit tests etc, but it seems like you could make a great contribution in this area if you were interested. Thanks for the comments -- keep it up! Wayne On 2/13/07, Jiaqi Guo [EMAIL PROTECTED] wrote: Hi Franz, I tried to get PluginDescriptor within a mojo and got PluginParameterException, then I started looking at this code. Assume expression is string plugin, pathSeparator is -1, the expression.substring(1) becomes lugin. Did I miss anything here? And then looking at ReflectionValueExtractor.java today, I just realized ReflectionValueExtractor.evaluate(lugin, pluginDescriptor) may work since the first argument is irrelevant if string doesn't contain '.'. But I'm more confused by the substring part of what .indexOf(/) is for. And still, in my Mojo, the parameter with expression ${plugin} is causing PluginParameterException which indicates the value of it is null. Regards -Jiaqi franz see wrote: Good day to you, Jiaqi, Why do you say that it will be evaluted to null? Cheers, Franz Jiaqi Guo wrote: Hi there, I'm trying to find out the build-in variables for a maven2 plugin and found the following code in http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.4/maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java line 217: ... else if ( expression.startsWith( plugin ) ) { try { int pathSeparator = expression.indexOf( / ); PluginDescriptor pluginDescriptor = mojoDescriptor.getPluginDescriptor(); if ( pathSeparator 0 ) { String pathExpression = expression.substring( 1, pathSeparator ); value = ReflectionValueExtractor.evaluate( pathExpression, pluginDescriptor ); value = value + expression.substring( pathSeparator ); } else { value = ReflectionValueExtractor.evaluate( expression.substring( 1 ), pluginDescriptor ); } } catch ( Exception e ) { // TODO: don't catch exception throw new ExpressionEvaluationException( Error evaluating plugin parameter expression: + expression, e ); } } ... If I didn't miss anything this code make the value of any parameter expression starting with plugin to be null for sure, which will cause PluginParameterException in org.apache.maven.plugin.DefaultPluginManager.checkRequiredParameters(DefaultPluginManager.java:809). Same thing happens to settings and project. Is this a bug of maven-2.0.4? Is there any way to get pluginDescriptor in Mojo? Regards -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jiaqi Guo http://www.cyclopsgroup.org [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] -- Jiaqi Guo http://www.cyclopsgroup.org [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For
Re: [m2] Can anyone explain this code
Thanks for your contribution, Jiaqi! Wayne On 2/13/07, Jiaqi Guo [EMAIL PROTECTED] wrote: Thanks Wayne, Although I found workaround for the tool that I'm working on, the patch for PluginParameterExpression could be really simple: sh-3.1$ svn diff Index: maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java === --- maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java (revision 507376) +++ maven-core/src/main/java/org/apache/maven/plugin/PluginParameterExpressionEvaluator.java (working copy) @@ -193,6 +193,10 @@ { value = project.getExecutionProject(); } +else if ( plugin.equals( expression ) ) +{ +value = mojoDescriptor.getPluginDescriptor(); +} else if ( expression.startsWith( project ) ) { try So I'll go ahead and create Jira issue with patch. Maven is always one of my favorite open source projects since it was under Turbine. I'm very pleased to continue to make contribution. Regards -Jiaqi Wayne Fay wrote: Without getting too far into the code myself, you seem to make some very good arguments about possible problems in this code. ;-) I have no idea if this PluginParameterExpressionEvaluator class (and the referenced code in Plexus) have proper unit tests etc, but it seems like you could make a great contribution in this area if you were interested. Thanks for the comments -- keep it up! Wayne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
JUnit 4.1 Surefire - Does Not Execute @Before @After methods
I am using mvn 2.0.4. I have JUnit 4.1 test cases in my project. The methods I have marked with @After and @Before annotations do not get called during test execution. Is this a known bug, or am I doing something wrong? -- Regards, Subhash Chandran S http://wizcrypt.wiztools.org/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Maven from command-line only?
I understand there are Eclipse IDE plugins, but from downloading and trying one of them it seems like there's very little it actually does (at least from what I can tell), and they're quite poorly documented for total beginners like me. Based on your experience, do you mostly use Maven from the command-line? What types of things do you do within Eclipse with Maven to simplify your development process? Could you recommend what a good Eclipse plugin would be? I've seen a couple, and I really can't tell which is comparatively the best...some suggestions would be appreciated. -- View this message in context: http://www.nabble.com/Maven-from-command-line-only--tf3225422s177.html#a8959368 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, SCM and release builds
Mark Struberg wrote on Tuesday, February 13, 2007 3:26 PM: Hi Jörg! The key difference is that the SCM section is in the PARENT POM and not in the modules POM. And the parent pom will not be checked in automatically by the release plugin if you only make a release:prepare and release:perform on that single module. and this implies, that you name your directories exactly after your artifactIds ... - Jörg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Maven, SCM and release builds
and this implies, that you name your directories exactly after your artifactIds ... You are right for our current configuration. But this is not necessarily stringent. In our parent pom, we did set the SCM module with the ${project.groupId}. scm:cvs:pserver:${cvs.username}:[EMAIL PROTECTED]:/home/cvsroot:${project.groupId}/ But this trick also works with other maven properties. So you may try to have your parent pom like: scm:cvs:pserver:${cvs.username}:[EMAIL PROTECTED]:/home/cvsroot:${prjScmModule.Name}/ and specify this property in your modules pom: properties prjScmModule.NamedifferentScmModuleName/prjScmModule.Name /properties LieGrü, strub --- Jörg Schaible [EMAIL PROTECTED] schrieb: Mark Struberg wrote on Tuesday, February 13, 2007 3:26 PM: Hi Jörg! The key difference is that the SCM section is in the PARENT POM and not in the modules POM. And the parent pom will not be checked in automatically by the release plugin if you only make a release:prepare and release:perform on that single module. and this implies, that you name your directories exactly after your artifactIds ... - Jörg ___ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]