Trivial Query
Hi, I have 2 goals defined in maven.xml. Goal1 : abc Goal2 : xyz Thease goals need to be run in sequential order i.e. Goal1 first and then Goal2. Requirement is, in automated build setup, Goal2 should not be invoked if Goal1 has failed. One crude way is to check the logs for goal1 and determine if its good to start goal2. However, I am sure there must be much much better way to handle this in maven. Can I use to fix this? How? Thanks and Regards, Kamlesh. -- Faith waiting in the heart of a seed promises a miracle of life which it can not prove! -Ravindranath Tagore
Re: Starting a jetty server
I am using the plug in to load an embedded server, so it will use the jars supplied by the repository. I have set jetty to start on port , which is not in use... The puzzling this is that the line "[INFO] [jetty:run {execution: start-jetty}]" does not appear in the hudson console - its as if the process-test-classes phase is not been run! On Tue, Jan 20, 2009 at 12:27 PM, Martin Gainty wrote: > > check for port conflict > netstat -a | grep WhateverPortIsUsedToStartJetty > in that case quiesce the server > > did you install Jetty (make sure org.mortbay.jetty classes are on the > CLASSPATH?) > > ? > Martin > __ > Disclaimer and confidentiality note > Everything in this e-mail and any attachments relates to the official > business of Sender. This transmission is of a confidential nature and Sender > does not endorse distribution to any party other than intended recipient. > Sender does not necessarily endorse content contained within this > transmission. > > > > > > Date: Tue, 20 Jan 2009 10:33:35 +1300 > > From: hangst...@gmail.com > > To: users@maven.apache.org > > Subject: Starting a jetty server > > > > Hi > > As part of my unit tests I use the maven-jetty-plugin to start up a web > > server. > > > > If I run maven from my pc it all works correctly and I get a console like > > > > [INFO] [jetty:run {execution: start-jetty}] > > [INFO] Configuring Jetty for project: ICECream > > [INFO] Webapp source directory = C:\Workspace_svn_maven\ICECream > > (Trunk)\src\main\webapp > > [INFO] Reload Mechanic: automatic > > [INFO] web.xml file = C:\Workspace_svn_maven\ICECream > > (Trunk)\src\main\webapp\WEB-INF\web.xml > > [INFO] Classes = C:\Workspace_svn_maven\ICECream (Trunk)\target\classes > > 2009-01-20 10:28:17.138::INFO: Logging to STDERR via > > org.mortbay.log.StdErrLog > > [INFO] Context path = /ICECream > > [INFO] Tmp directory = determined at runtime > > [INFO] Web defaults = org/mortbay/jetty/webapp/webdefault.xml > > [INFO] Web overrides = none > > [INFO] Webapp directory = C:\Workspace_svn_maven\ICECream > > (Trunk)\src\main\webapp > > [INFO] Starting jetty 6.1H.14.1 ... > > 2009-01-20 10:28:17.310::INFO: jetty-6.1H.14.1 > > 2009-01-20 10:28:17.591::INFO: No Transaction manager found - if your > > webapp requires one, please configure one. > > log4j:WARN No appenders could be found for logger > > (org.springframework.web.servlet.DispatcherServlet). > > log4j:WARN Please initialize the log4j system properly. > > 2009-01-20 10:28:18.935:/ICECream:INFO: Loading WebApplicationContext > for > > Spring FrameworkServlet 'icecream' > > 2009-01-20 10:28:19.622::INFO: Started > selectchannelconnec...@0.0.0.0: > > [INFO] Started Jetty Server > > > > When I try and use Hudson the jetty web server is not started and nothing > is > > displayed in the console. I.e there appears to be no attempt at starting > the > > jetty > > > > I have no idea what is causing this > > > > > > My plugin is configured as follows > > > > > > org.mortbay.jetty > > maven-jetty-plugin > > > > 9966 > > stop > > > > > > > > start-jetty > > process-test-classes > > > > run > > > > > > 0 > > true > > > > > > > > stop-jetty > > prepare-package > > > > stop > > > > > > > > > > _ > Windows Live™ Hotmail(R): Chat. Store. Share. Do more with mail. > > http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t1_hm_justgotbetter_explore_012009 >
Hierarchical multi-module projects in a source code repository
Hi, I have a multi-module project that is stored in a flat directory structure in our source code repository (Subversion). For example: repo parent trunk tags branches child1 trunk tags branches child2 trunk tags branches Note that parent, child1, and child2 are all on the same level. I would like to change this organization so that child1 and child2 are children of the parent. This is the usual way of organizing multi- module projects, since it makes their relationship clear. But what about the problem of repository branches? For example, if I make child1 and child2 children of the parent, it will look like this: repo parent trunk child1 trunk tags branches child2 trunk tags branches tags branches This is clearly an invalid directory structure (from a repository perspective) because the parent's trunk includes the children's branches. So, will I simply have to give up child branches if I want to use this kind of hierarchy? I am loathe to do this, since it would force the children to have the same version as the parent. Perhaps my current organization -- that is, flattening the module directories so that they're all siblings -- is the only way to do it... Any thoughts? Thanks, Trevor - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
RE: Starting a jetty server
check for port conflict netstat -a | grep WhateverPortIsUsedToStartJetty in that case quiesce the server did you install Jetty (make sure org.mortbay.jetty classes are on the CLASSPATH?) ? Martin __ Disclaimer and confidentiality note Everything in this e-mail and any attachments relates to the official business of Sender. This transmission is of a confidential nature and Sender does not endorse distribution to any party other than intended recipient. Sender does not necessarily endorse content contained within this transmission. > Date: Tue, 20 Jan 2009 10:33:35 +1300 > From: hangst...@gmail.com > To: users@maven.apache.org > Subject: Starting a jetty server > > Hi > As part of my unit tests I use the maven-jetty-plugin to start up a web > server. > > If I run maven from my pc it all works correctly and I get a console like > > [INFO] [jetty:run {execution: start-jetty}] > [INFO] Configuring Jetty for project: ICECream > [INFO] Webapp source directory = C:\Workspace_svn_maven\ICECream > (Trunk)\src\main\webapp > [INFO] Reload Mechanic: automatic > [INFO] web.xml file = C:\Workspace_svn_maven\ICECream > (Trunk)\src\main\webapp\WEB-INF\web.xml > [INFO] Classes = C:\Workspace_svn_maven\ICECream (Trunk)\target\classes > 2009-01-20 10:28:17.138::INFO: Logging to STDERR via > org.mortbay.log.StdErrLog > [INFO] Context path = /ICECream > [INFO] Tmp directory = determined at runtime > [INFO] Web defaults = org/mortbay/jetty/webapp/webdefault.xml > [INFO] Web overrides = none > [INFO] Webapp directory = C:\Workspace_svn_maven\ICECream > (Trunk)\src\main\webapp > [INFO] Starting jetty 6.1H.14.1 ... > 2009-01-20 10:28:17.310::INFO: jetty-6.1H.14.1 > 2009-01-20 10:28:17.591::INFO: No Transaction manager found - if your > webapp requires one, please configure one. > log4j:WARN No appenders could be found for logger > (org.springframework.web.servlet.DispatcherServlet). > log4j:WARN Please initialize the log4j system properly. > 2009-01-20 10:28:18.935:/ICECream:INFO: Loading WebApplicationContext for > Spring FrameworkServlet 'icecream' > 2009-01-20 10:28:19.622::INFO: Started selectchannelconnec...@0.0.0.0: > [INFO] Started Jetty Server > > When I try and use Hudson the jetty web server is not started and nothing is > displayed in the console. I.e there appears to be no attempt at starting the > jetty > > I have no idea what is causing this > > > My plugin is configured as follows > > > org.mortbay.jetty > maven-jetty-plugin > > 9966 > stop > > > > start-jetty > process-test-classes > > run > > > 0 > true > > > > stop-jetty > prepare-package > > stop > > > > _ Windows Live™ Hotmail®: Chat. Store. Share. Do more with mail. http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t1_hm_justgotbetter_explore_012009
Re: Mvn eclipse:eclipse - strange M2_REPO settings
baerrach wrote: > > I've re-opened it. > > I haven't had the chance to look in detail at the problem. > > If there are enough steps to reproduce the problem then there is a > better chance of it getting fixed. > I've resolved my issue, and commented on the jira as follows: OK, I have fixed my configuration ... This is a windows problem only. The problem was in my C:\Documents and Settings\uid\.m2\settings.xml where I had defined a value for localRepository as follows: /Documents and Settings/uid/.m2/repository This value happens to be similar to the default, although the default on windows uses a C:\ prefix. The C:\ prefix turned out to be rather important, as this is one of the ways that java.io.Win32FileSystem determines whether the path is absolute or not, the other way that is accepted as absolute is if the path startsWith a double slash \\. A single slash [how I had entered it] is not an absolute path, and this caused IdeUtils.toRelativeAndFixSeparator() to duplicate the basedir on the fileToAdd. Further on in this method, the duplicated basedir is removed, and the result is returned as a relative path, however due to the initial duplication, the path that was returned was still absolute (even if Win32FileSystem doesn't think so due to lack of C:\ or \\). So the quick answer of how I fixed this was to comment out my localRepository in my settings.xml and use the default generated value. Cheers, Neil. -- View this message in context: http://www.nabble.com/Mvn-eclipse%3Aeclipse---strange-M2_REPO-settings-tp20541566p21553641.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Exclude directory from src directory while packaging
> So when I do mvn package, it packages both my-project and > dir_dont_wanna_include directories in the package. Is it possible to not > include dir_dont_wanna_include directory? Or should I move it out of the > src directory all together. I don't wanna move this directory from src > is because it is java source but it actually is not the main project but > some java scripts that run periodically calling the main my-project code I would probably move this code to its own Maven project with its own pom.xml file etc. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Starting a jetty server
Hi As part of my unit tests I use the maven-jetty-plugin to start up a web server. If I run maven from my pc it all works correctly and I get a console like [INFO] [jetty:run {execution: start-jetty}] [INFO] Configuring Jetty for project: ICECream [INFO] Webapp source directory = C:\Workspace_svn_maven\ICECream (Trunk)\src\main\webapp [INFO] Reload Mechanic: automatic [INFO] web.xml file = C:\Workspace_svn_maven\ICECream (Trunk)\src\main\webapp\WEB-INF\web.xml [INFO] Classes = C:\Workspace_svn_maven\ICECream (Trunk)\target\classes 2009-01-20 10:28:17.138::INFO: Logging to STDERR via org.mortbay.log.StdErrLog [INFO] Context path = /ICECream [INFO] Tmp directory = determined at runtime [INFO] Web defaults = org/mortbay/jetty/webapp/webdefault.xml [INFO] Web overrides = none [INFO] Webapp directory = C:\Workspace_svn_maven\ICECream (Trunk)\src\main\webapp [INFO] Starting jetty 6.1H.14.1 ... 2009-01-20 10:28:17.310::INFO: jetty-6.1H.14.1 2009-01-20 10:28:17.591::INFO: No Transaction manager found - if your webapp requires one, please configure one. log4j:WARN No appenders could be found for logger (org.springframework.web.servlet.DispatcherServlet). log4j:WARN Please initialize the log4j system properly. 2009-01-20 10:28:18.935:/ICECream:INFO: Loading WebApplicationContext for Spring FrameworkServlet 'icecream' 2009-01-20 10:28:19.622::INFO: Started selectchannelconnec...@0.0.0.0: [INFO] Started Jetty Server When I try and use Hudson the jetty web server is not started and nothing is displayed in the console. I.e there appears to be no attempt at starting the jetty I have no idea what is causing this My plugin is configured as follows org.mortbay.jetty maven-jetty-plugin 9966 stop start-jetty process-test-classes run 0 true stop-jetty prepare-package stop
Re: Maven 2.0.9 - internal repository - archetype plugin version
Hi Michael, Many thanks for your reply - You were correct about the metadata. I've since managed to convince my organisation to give me an environment that has internet access and which can support a repository manager (Nexus). I'm now using the cached version of the repository created by Nexus and then using it again to serve this cache in the corporate network as a hosted repository and it seems to work great. Thanks for your assistance and my apologies to the list for the double post. Kind Regards, Ross. >I may be talking out a hole but check this out...>>The release version along >with version range information comes from metadata... if you created>your >internal repository in a way other than using the deploy plugin then you won't >have metadata.>If you are copying your local repository aka the artifact cache >then you don't have 'maven-metadata.xml'>in the correct place. you have cache >copies of the metadata named central-maven-metadata.xml...>if you only used >central to build your local cache then you could just rename >centra-maven-metadata...>or you could just use a repository manager given you >seem to have the requirement for it.>hope that helps.. _ Cut through the jargon: find a PC for your needs. http://clk.atdmt.com/UKM/go/130777504/direct/01/
Maven plugin for creating a patch for the source files managed using subversion
Hi, Is there a maven plugin for creating a patch for the source files that are linked to subversion scm? I do see a plugin for applying the patch: http://maven.apache.org/plugins/maven-patch-plugin/index.html But can't find the one for creating one. Thanks, -Rakesh
RE: Maven + POM + version + webapp context parameter
Julien, You should be able to achieve this by taking advantage of maven resource filtering feature. Including it in the pom is a bit more tricky though, you can replace a ${variable_placeholder} in the POM by providing the version on the commandline likeso: -Dmyversion=. However this doesnt meet your requirement to use a properties file. Thanks, -Guillaume From: Julien Martin [mailto:bal...@gmail.com] Sent: Mon 19/01/2009 6:18 AM To: Maven Users List Subject: Maven + POM + version + webapp context parameter Hello, I would like to achieve the following: -retrieve the from a properties file so that I can include it in both the POM and my web.xml (context parameter). Does that make sense? How can I achieve this? Thanks, Julien. This electronic mail (including any attachments) may contain information that is privileged, confidential, and/or otherwise protected from disclosure to anyone other than its intended recipient(s). Any dissemination or use of this electronic email or its contents (including any attachments) by persons other than the intended recipient(s) is strictly prohibited. If you have received this message in error, please notify us immediately by reply email so that we may correct our internal records. Please then delete the original message (including any attachments) in its entirety. Thank you.
Exclude directory from src directory while packaging
Hi there, I was wondering if its possible to exclude a directory from the src directory so that it is not packaged. Following is the directory layout Src |---main |---java |---com |---abc |---my-project |---dir_dont_wanna_include So when I do mvn package, it packages both my-project and dir_dont_wanna_include directories in the package. Is it possible to not include dir_dont_wanna_include directory? Or should I move it out of the src directory all together. I don't wanna move this directory from src is because it is java source but it actually is not the main project but some java scripts that run periodically calling the main my-project code I tried the following in my pom with no effect maven-compiler-plugin 2.0.2 1.5 1.5 src/main/java/com/abc/my-project/ Thanks Shahzad Qureshi Systems Analyst/Programmer Applications Directorate, CIOB Environment Canada shahzad.qure...@ec.gc.ca
Re: Plugin not picking up dependencies when executed from parent pom?
> It's working perfectly, as long as I build the project directly. If I try > to built the project as a module from a parent pom, the plugin fails with > the error: > "Exception in thread "main" java.lang.NoClassDefFoundError: > org/apache/derby/tools/ij" In M2.0, the "first" declaration of a plugin "wins". So add the derby and derbytools dependencies to the other places where you declare maven-antrun-plugin, probably in the parent somewhere I'd imagine. This is a bug that is being worked on but won't be resolved for the 2.0 line, as I understand it. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: [Beginner needs help] Populating a web.xml context-param from a maven variable?
Easy: I added the following plugin: org.apache.maven.plugins maven-war-plugin ${basedir}/src/main/webapp/WEB-INF web.xml WEB-INF true and then the following context-param: com.mycompany.version ${pom.version} That did the trick! Thanks maven, Julien.
Re: Perform release without updating pom to new SNAPSHOT version
On Mon, Jan 19, 2009 at 7:01 AM, Wim Deblauwe wrote: > No, we don't have an extra version. The branch is called "int_module_1.0" > and we use 1.0-SNAPSHOT on that branch. When we release, this becomes > version 1.0 and no further work should be done on that branch. We will then > create a new branch "int_module_1.1" and use version 1.1-SNAPSHOT there. You can certainly have the release plugin return all the POMs to 1.0-SNAPSHOT. We use this when releasing a Release Candidate - take the release preparation branch, release as 1.0.RC1, have it return the POMs to 1.0-SNAPSHOT. Continue this process releasing additional RCs until we are ready to release 1.0 proper. You could also have it update them to 1.0.1-SNAPSHOT which is what others seem to be suggesting. This is usually the case with my team when we do a final release - this causes our release preparation branch to turn into a maintenance/patches branch. I'm not sure how to attach a branch lock to the release process but you certainly could do so afterwards with something like 'mvn release:prepare someplugin:lockbranch' (obviously how you do it depends on how you lock branches in your environment). - John - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
[Beginner needs help] Populating a web.xml context-param from a maven variable?
Hello, I would like to achieve the following: -retrieve the from a properties file so that I can include it in both the POM and my web.xml (context parameter). Is that possible? How can I achieve this? Thanks, Julien.
Re: Maven EAR Plugin ContextRoot
On Sun, Jan 18, 2009 at 5:30 AM, Stephane Nicoll wrote: > On Wed, Jan 14, 2009 at 11:39 PM, Stephen Duncan Jr > > It is working with both 2.3.1 and the trunk. I've just tried on a > stupid project that I have for testing and it worked. Can you maybe > post your pom.xml file? > > > maven-ear-plugin > 2.3.1 > > > >root.project.servlets >servlet >/foobar > > > > > > > > > -- > > Stephen Duncan Jr > > www.stephenduncanjr.com > > > > > > -- > Large Systems Suck: This rule is 100% transitive. If you build one, > you suck" -- S.Yegge > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > Somehow I'd gone all this time without noticing that I was missing the level of the configuration. Thanks for verifying that it did work so that I re-examined my pom more closely. Apologies for the mistake. -- Stephen Duncan Jr www.stephenduncanjr.com
How to construct the "pom.xml" ti build an EAR file?
I want to build an EAR file which looks as follow: http://www.nabble.com/file/p21545349/maven-ear.jpg My "pom.xml" looks as follow but I can't get the structure as shown above. Has someone idea? * 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";> 4.0.0 com.wei.chen.jboss.seam.ear jboss-seam-ear 1.0.0-1-SNAPSHOT ${project.version} ${artifactId} A web interface for ... com.wei.chen.jboss.seam jboss-seam-multi 1.0.0-1-SNAPSHOT ear org.apache.maven.plugins maven-ear-plugin 2.2 lib/ ${artifactId} org.jboss.seam jboss-seam ${seam-version} / com.wei.chen.jboss.seam.jar jboss-seam-jar / org.apache.maven.plugins maven-compiler-plugin 1.5 1.5 com.wei.chen.jboss.seam.jar jboss-seam-jar ${project.version} jar org.richfaces.framework richfaces-impl org.richfaces.ui richfaces-ui com.wei.chen.jboss.seam.war jboss-seam-war ${project.version} war -- View this message in context: http://www.nabble.com/How-to-construct-the-%22pom.xml%22-ti-build-an-EAR-file--tp21545349p21545349.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Can the maven-upload-plugin be used in a open source project?
atlassian has moved this plugin to codehaus and become wagon-maven-plugin which can do both download and upload -D On Mon, Jan 19, 2009 at 5:58 AM, Tim Kettler wrote: > Jaikiran schrieb: >> >> I was working on a Maven project and was looking for a plugin which could >> upload some documentation to some remote location. While searching this >> mailing list i came across the maven-upload-plugin which is hosted at >> http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ >> >> http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ >> Its exactly what i was looking for. But is that plugin meant to be used in >> a >> open source project? I am curious since the plugin is hosted at a *.com >> domain. Any inputs? > > As the plugin inherits [1] from the Atlassian public parent pom [2] that > defines the license as BSD you should be ok. > > -Tim > > [1] > http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/maven-upload-plugin-1.1.pom > [2] > http://repository.atlassian.com/maven2/com/atlassian/pom/atlassian-public-pom/18/atlassian-public-pom-18.pom > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Plugin not picking up dependencies when executed from parent pom?
Hi, I'm trying to use the ant-run plugin to execute a sql script as part of my build. It's working perfectly, as long as I build the project directly. If I try to built the project as a module from a parent pom, the plugin fails with the error: "Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/derby/tools/ij" Does anyone know what's wrong? Any help would be greatly appreciated. The parent pom doesn't contain anything other than module definitions and some surefire configuration. Here's the relevant part of the project's pom though: maven-antrun-plugin create-demo-database package run org.apache.derby derbytools 10.4.2.0 org.apache.derby derby 10.4.2.0 Thanks, Dave.
Re: Perform release without updating pom to new SNAPSHOT version
But what will you do if there is a bugfixing needed on that branch? Please don't tell me that you simply override the already published artifact :( If you don't intend to do some work on this very branch, why don't you simply use a tag instead (which maven-release-plugin already handles for you anyway)? LieGrue, strub --- Wim Deblauwe schrieb am Mo, 19.1.2009: > Von: Wim Deblauwe > Betreff: Re: Perform release without updating pom to new SNAPSHOT version > An: "Maven Users List" > Datum: Montag, 19. Januar 2009, 13:01 > No, we don't have an extra version. The branch is called > "int_module_1.0" > and we use 1.0-SNAPSHOT on that branch. When we release, > this becomes > version 1.0 and no further work should be done on that > branch. We will then > create a new branch "int_module_1.1" and use > version 1.1-SNAPSHOT there. > > regards, > > Wim > > 2009/1/19 Mark Struberg > > > but you haven an internal build version _inside_ this > brunch, don't you? > > > > how should maven otherwise distinguish between > different builds of that > > branch? > > > > I suggest using: > > int_module_1.0-1-SNAPSHOT > > > > so a release will create and tag a int_module_1.0-1 > and your pom finally > > will state int_module_1.0-2-SNAPSHOT > > > > LieGrue, > > strub > > > > --- Wim Deblauwe > schrieb am Mo, 19.1.2009: > > > > > Von: Wim Deblauwe > > > Betreff: Perform release without updating pom to > new SNAPSHOT version > > > An: "Maven Users List" > > > > Datum: Montag, 19. Januar 2009, 12:16 > > > Hi, > > > > > > is it possible to do release:perfom which does > everything > > > like normal, > > > except updating the pom.xml to a new SNAPSHOT > version? > > > > > > We use branches per version, so if I release on > my branch > > > "int_module_1.0", > > > I don't want the pom.xml to change to > 1.1-SNAPSHOT. In > > > fact, I want the > > > branch to be locked. > > > > > > Is this supported by the release plugin? > > > > > > regards, > > > > > > Wim > > > > > > > > > > > - > > To unsubscribe, e-mail: > users-unsubscr...@maven.apache.org > > For additional commands, e-mail: > users-h...@maven.apache.org > > > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Use of profiles
On Jan 16, 2009, at 1:55 PM, Eric Rotick wrote: My requirement was simply to allow for common sections to be collected together to enhance the maintainability of the pom. Currently the verbose nature of the pom makes it far too easy to have subtle differences that ruin the test. We're having a similar problem with our install4j code, which is basically 30 lines of Ant that gets copied and pasted to each new project that needs to build an installer. Of course, this can introduce bugs, especially when one of the 30 lines needs to change, and that change has to propagate to all the projects. To solve this problem, I'm writing a plugin that factors out the common code into a single place. The projects can then reference the plugin and specify just enough information that's unique to their setup. Perhaps a similar solution would work in your case. Trevor - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Can the maven-upload-plugin be used in a open source project?
Jaikiran schrieb: I was working on a Maven project and was looking for a plugin which could upload some documentation to some remote location. While searching this mailing list i came across the maven-upload-plugin which is hosted at http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ Its exactly what i was looking for. But is that plugin meant to be used in a open source project? I am curious since the plugin is hosted at a *.com domain. Any inputs? As the plugin inherits [1] from the Atlassian public parent pom [2] that defines the license as BSD you should be ok. -Tim [1] http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/maven-upload-plugin-1.1.pom [2] http://repository.atlassian.com/maven2/com/atlassian/pom/atlassian-public-pom/18/atlassian-public-pom-18.pom - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: how to exclude classes from package in target/classes to be copied to WAR in packaging
If Eclipse is automatically generating classes in target/classes from your classes in src/test/java, I think there is a problem, since src/test/java classes should end up in target/test-classes. I would recommend (1) running eclipse:eclipse on your project (to update your Eclipse .classpath) and then (2) perform a clean (to clean out the old files in target/classes). As an example, if I execute 'mvn eclipse:eclipse' on a web project of mine, my Eclipse project .classpath file ends up with the following: ... ... Notice that src/test/java classes go to target/test-classes. After performing eclipse:eclipse and refreshing your project, your .classpath should be similar to the above. After this, you should perform a 'mvn clean' and refresh your project. You should end up with target/classes (empty folder) target/test-classes (empty folder) Now, if you perform a 'mvn clean package', you should see that your regular classes end up in target/classes and your test classes end up in target/test-classes. If you inspect your war file that is created, you should see that it does not contain your test classes. By the way, it's a good idea to run clean before running lifecycle commands like 'package' since this ensures that old stuff is cleaned out when you build your new artifact. Deron Eriksson
Re: Can the maven-upload-plugin be used in a open source project?
En l'instant précis du 19/01/2009 14:43, Jaikiran s'exprimait en ces termes: > I was working on a Maven project and was looking for a plugin which could > upload some documentation to some remote location. While searching this > mailing list i came across the maven-upload-plugin which is hosted at > http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ > http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ > > > Its exactly what i was looking for. But is that plugin meant to be used in a > open source project? I am curious since the plugin is hosted at a *.com > domain. Any inputs? > > > You should ask atlassian what are de licensing terms for this artifacts. Anyway, it's not because a plugin is commercial or closed source that it's use is incompatible with an open source project. What you can't do without atlassian authorisation is distribute their plugin, but as long as it's them distributing it, you are not impacted by licensing. What could be a problem to you is if atlassian stop distributing it :) The opensource nature of a project related to the distribution licences and execution of this project, not to it's build process. If you want to create an open source project that request an expensive development suite to be build, you can do it, you will just have more trouble finding developper in te open source communities :) -- David Delbecq ICT Institut Royal Météorologique Ext:557 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Can the maven-upload-plugin be used in a open source project?
I was working on a Maven project and was looking for a plugin which could upload some documentation to some remote location. While searching this mailing list i came across the maven-upload-plugin which is hosted at http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ Its exactly what i was looking for. But is that plugin meant to be used in a open source project? I am curious since the plugin is hosted at a *.com domain. Any inputs? -- View this message in context: http://www.nabble.com/Can-the-maven-upload-plugin-be-used-in-a-open-source-project--tp21543256p21543256.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
AW: how to exclude classes from package in target/classes to be copied to WAR in packaging
This may be out of scope for this question, but why not use m2eclipse? It separates main and test classes nicely and IMHO relieves you from all of these problems. Best regards, Eric > -Ursprüngliche Nachricht- > Von: Deron Eriksson [mailto:jonde...@codestrategies.com] > Gesendet: Montag, 19. Januar 2009 14:18 > An: users@maven.apache.org > Betreff: Re: how to exclude classes from package in > target/classes to be copied to WAR in packaging > > > If Eclipse is automatically generating classes in > target/classes from your > classes in src/test/java, I think there is a problem, since > src/test/java > classes should end up in target/test-classes. I would recommend > > (1) running eclipse:eclipse on your project (to update your Eclipse > .classpath) and then > (2) perform a clean (to clean out the old files in target/classes). > > As an example, if I execute 'mvn eclipse:eclipse' on a web > project of mine, > my Eclipse project .classpath file ends up with the following: > ... > >output="target/test-classes"/> > > ... > > Notice that src/test/java classes go to target/test-classes. > > After performing eclipse:eclipse and refreshing your project, your > .classpath should be similar to the above. > > After this, you should perform a 'mvn clean' and refresh your > project. You > should end up with > target/classes (empty folder) > target/test-classes (empty folder) > > Now, if you perform a 'mvn clean package', you should see > that your regular > classes end up in target/classes and your test classes end up in > target/test-classes. If you inspect your war file that is created, you > should see that it does not contain your test classes. > > Deron Eriksson > > -- > View this message in context: > http://www.nabble.com/how-to-exclude-classes-from-package-in-t > arget-classes-to-be-copied-to-WAR-in-packaging-tp21540465p2154 > 2863.html > Sent from the Maven - Users mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: how to exclude classes from package in target/classes to be copied to WAR in packaging
If Eclipse is automatically generating classes in target/classes from your classes in src/test/java, I think there is a problem, since src/test/java classes should end up in target/test-classes. I would recommend (1) running eclipse:eclipse on your project (to update your Eclipse .classpath) and then (2) perform a clean (to clean out the old files in target/classes). As an example, if I execute 'mvn eclipse:eclipse' on a web project of mine, my Eclipse project .classpath file ends up with the following: ... ... Notice that src/test/java classes go to target/test-classes. After performing eclipse:eclipse and refreshing your project, your .classpath should be similar to the above. After this, you should perform a 'mvn clean' and refresh your project. You should end up with target/classes (empty folder) target/test-classes (empty folder) Now, if you perform a 'mvn clean package', you should see that your regular classes end up in target/classes and your test classes end up in target/test-classes. If you inspect your war file that is created, you should see that it does not contain your test classes. Deron Eriksson -- View this message in context: http://www.nabble.com/how-to-exclude-classes-from-package-in-target-classes-to-be-copied-to-WAR-in-packaging-tp21540465p21542863.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: AW: how to avoid build error if remote repository is nto available?
Strub Thanks for that, Im still learning Maven commands etc.. Maven does report that its only using local artifacts when I run with switch but annoyingly I keep getting build errors because it cant seem to find plgunis etc that are actually there!! something wrong with my config. I know. Jon struberg wrote: > > mvn -o > don't work? > > LieGrue, > strub > > --- jonathan14 schrieb am Mo, 19.1.2009: > >> Von: jonathan14 >> Betreff: Re: AW: how to avoid build error if remote repository is nto >> available? >> An: users@maven.apache.org >> Datum: Montag, 19. Januar 2009, 12:20 >> Hi strub, >> >> >> Thanks for your reply. >> >> Apologies I forgot to clarify that my 'remote >> repository' is indeed an >> instance of Artifactory but running in a managed service >> machine - I dont >> have a server available on my local/corporate network to >> install an instance >> of Artifactory unfortunately. >> >> Whats annoying is that Maven wont build my war since it >> complains it cant >> get the war plugin from my remote artifactory - since this >> network >> connection is down at present - but I have the plugin in my >> local machine >> $M2_HOME. So, my POM is missing some configuration I feel. >> Maven can >> definately access my local $M2_HOME since it installs my >> project artifacts >> there after a successful build. >> >> Thanks >> Jon >> >> >> >> >> >> struberg wrote: >> > >> >> Occassionally our remote - "central" - >> repository is unavailable >> > >> > Do you already use some kind of caching proxy like >> e.g. Archiva, >> > Artifactory, maven-proxy or Nexus? >> > >> > >> > If you are in a company I would _highly_ recommend >> setting up such a >> > proxy! >> > 1.) no complaining about public repos being offline >> anymore >> > 2.) you can backup the whole proxy cache and so your >> builds are also safe >> > in the future. >> > 3.) It will increase build times for your colleagues >> greatly. >> > 4.) helps to relieve the central repo if not everyone >> is stressing the >> > servers! >> > >> > LieGrue, >> > strub >> > >> > --- jonathan14 >> schrieb am Mo, 19.1.2009: >> >> Von: jonathan14 >> >> Betreff: how to avoid build error if remote >> repository is nto available? >> >> An: users@maven.apache.org >> >> Datum: Montag, 19. Januar 2009, 11:38 >> >> Hello >> >> >> >> >> >> Occassionally our remote - "central" - >> repository >> >> is unavailable, and when >> >> this occurs a local build fails because my local >> Maven >> >> cannot get the remote >> >> artifacts - whether they be plugins or my project >> >> components >> >> >> >> ie. >> >> [WARNING] repository metadata for: 'artifact >> >> org.apache.maven.plugins:maven-war-plugin' >> could not be >> >> retrieved from >> >> repository: central due to an error: Error >> transferring >> >> file >> >> >> >> >> >> Ive had a look at the onlnie documentation and a >> coupld of >> >> guides but cant >> >> figure out how to configure my project POM so that >> Maven >> >> can still build if >> >> it can find all the artifacts it needs in the >> local >> >> repository. I know the >> >> maven-war-plugin exists locally since I can see it >> in the >> >> file system. >> >> >> >> Further to this, can anyone tell me how in >> instruct Maven >> >> not to check >> >> remote repositories if it can find the artifact in >> the >> >> local one? >> >> >> >> Do I just make my local repository my default one? >> >> >> >> >> >> Thanks >> >> Jon >> >> >> >> >> >> -- >> >> View this message in context: >> >> >> http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21540454.html >> >> Sent from the Maven - Users mailing list archive >> at >> >> Nabble.com. >> >> >> >> >> >> >> - >> >> To unsubscribe, e-mail: >> users-unsubscr...@maven.apache.org >> >> For additional commands, e-mail: >> >> users-h...@maven.apache.org >> > >> > >> > >> > >> > >> - >> > To unsubscribe, e-mail: >> users-unsubscr...@maven.apache.org >> > For additional commands, e-mail: >> users-h...@maven.apache.org >> > >> > >> > >> >> -- >> View this message in context: >> http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21541153.html >> Sent from the Maven - Users mailing list archive at >> Nabble.com. >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org >> For additional commands, e-mail: >> users-h...@maven.apache.org > > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > > -- View this message in context: http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp2154
Maven2 Inheritence configuration file path
hi i have a parent pom which contains plugins which have configuration files. For example i use PMD with my own rule sets. So i do specifie in my parent project the location where this file is. For example in my parent projects resources folder the rule sets for PMD can be found. However when my child inherits my parent pom it inherits this path too and will look in its own (child) resource folder for the PMD configuration file. How do i handle such a use case ? I want that the child uses the parents configuration file as well for the plugin. thanks in advance kukudas
Re: Perform release without updating pom to new SNAPSHOT version
No, we don't have an extra version. The branch is called "int_module_1.0" and we use 1.0-SNAPSHOT on that branch. When we release, this becomes version 1.0 and no further work should be done on that branch. We will then create a new branch "int_module_1.1" and use version 1.1-SNAPSHOT there. regards, Wim 2009/1/19 Mark Struberg > but you haven an internal build version _inside_ this brunch, don't you? > > how should maven otherwise distinguish between different builds of that > branch? > > I suggest using: > int_module_1.0-1-SNAPSHOT > > so a release will create and tag a int_module_1.0-1 and your pom finally > will state int_module_1.0-2-SNAPSHOT > > LieGrue, > strub > > --- Wim Deblauwe schrieb am Mo, 19.1.2009: > > > Von: Wim Deblauwe > > Betreff: Perform release without updating pom to new SNAPSHOT version > > An: "Maven Users List" > > Datum: Montag, 19. Januar 2009, 12:16 > > Hi, > > > > is it possible to do release:perfom which does everything > > like normal, > > except updating the pom.xml to a new SNAPSHOT version? > > > > We use branches per version, so if I release on my branch > > "int_module_1.0", > > I don't want the pom.xml to change to 1.1-SNAPSHOT. In > > fact, I want the > > branch to be locked. > > > > Is this supported by the release plugin? > > > > regards, > > > > Wim > > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
AW: Perform release without updating pom to new SNAPSHOT version
but you haven an internal build version _inside_ this brunch, don't you? how should maven otherwise distinguish between different builds of that branch? I suggest using: int_module_1.0-1-SNAPSHOT so a release will create and tag a int_module_1.0-1 and your pom finally will state int_module_1.0-2-SNAPSHOT LieGrue, strub --- Wim Deblauwe schrieb am Mo, 19.1.2009: > Von: Wim Deblauwe > Betreff: Perform release without updating pom to new SNAPSHOT version > An: "Maven Users List" > Datum: Montag, 19. Januar 2009, 12:16 > Hi, > > is it possible to do release:perfom which does everything > like normal, > except updating the pom.xml to a new SNAPSHOT version? > > We use branches per version, so if I release on my branch > "int_module_1.0", > I don't want the pom.xml to change to 1.1-SNAPSHOT. In > fact, I want the > branch to be locked. > > Is this supported by the release plugin? > > regards, > > Wim - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: AW: how to avoid build error if remote repository is nto available?
mvn -o don't work? LieGrue, strub --- jonathan14 schrieb am Mo, 19.1.2009: > Von: jonathan14 > Betreff: Re: AW: how to avoid build error if remote repository is nto > available? > An: users@maven.apache.org > Datum: Montag, 19. Januar 2009, 12:20 > Hi strub, > > > Thanks for your reply. > > Apologies I forgot to clarify that my 'remote > repository' is indeed an > instance of Artifactory but running in a managed service > machine - I dont > have a server available on my local/corporate network to > install an instance > of Artifactory unfortunately. > > Whats annoying is that Maven wont build my war since it > complains it cant > get the war plugin from my remote artifactory - since this > network > connection is down at present - but I have the plugin in my > local machine > $M2_HOME. So, my POM is missing some configuration I feel. > Maven can > definately access my local $M2_HOME since it installs my > project artifacts > there after a successful build. > > Thanks > Jon > > > > > > struberg wrote: > > > >> Occassionally our remote - "central" - > repository is unavailable > > > > Do you already use some kind of caching proxy like > e.g. Archiva, > > Artifactory, maven-proxy or Nexus? > > > > > > If you are in a company I would _highly_ recommend > setting up such a > > proxy! > > 1.) no complaining about public repos being offline > anymore > > 2.) you can backup the whole proxy cache and so your > builds are also safe > > in the future. > > 3.) It will increase build times for your colleagues > greatly. > > 4.) helps to relieve the central repo if not everyone > is stressing the > > servers! > > > > LieGrue, > > strub > > > > --- jonathan14 > schrieb am Mo, 19.1.2009: > >> Von: jonathan14 > >> Betreff: how to avoid build error if remote > repository is nto available? > >> An: users@maven.apache.org > >> Datum: Montag, 19. Januar 2009, 11:38 > >> Hello > >> > >> > >> Occassionally our remote - "central" - > repository > >> is unavailable, and when > >> this occurs a local build fails because my local > Maven > >> cannot get the remote > >> artifacts - whether they be plugins or my project > >> components > >> > >> ie. > >> [WARNING] repository metadata for: 'artifact > >> org.apache.maven.plugins:maven-war-plugin' > could not be > >> retrieved from > >> repository: central due to an error: Error > transferring > >> file > >> > >> > >> Ive had a look at the onlnie documentation and a > coupld of > >> guides but cant > >> figure out how to configure my project POM so that > Maven > >> can still build if > >> it can find all the artifacts it needs in the > local > >> repository. I know the > >> maven-war-plugin exists locally since I can see it > in the > >> file system. > >> > >> Further to this, can anyone tell me how in > instruct Maven > >> not to check > >> remote repositories if it can find the artifact in > the > >> local one? > >> > >> Do I just make my local repository my default one? > >> > >> > >> Thanks > >> Jon > >> > >> > >> -- > >> View this message in context: > >> > http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21540454.html > >> Sent from the Maven - Users mailing list archive > at > >> Nabble.com. > >> > >> > >> > - > >> To unsubscribe, e-mail: > users-unsubscr...@maven.apache.org > >> For additional commands, e-mail: > >> users-h...@maven.apache.org > > > > > > > > > > > - > > To unsubscribe, e-mail: > users-unsubscr...@maven.apache.org > > For additional commands, e-mail: > users-h...@maven.apache.org > > > > > > > > -- > View this message in context: > http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21541153.html > Sent from the Maven - Users mailing list archive at > Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: > users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: how to exclude classes from package in target/classes to be copied to WAR in packaging
Hello, I've found with thiis link : http://www.nabble.com/Excluding-certain-file-types-using-the-maven-war-plugin-td19947937.html#a19947937 http://www.nabble.com/Excluding-certain-file-types-using-the-maven-war-plugin-td19947937.html#a19947937 . should take a pattern, not a series of elements... :) So, I've put that : org.apache.maven.plugins maven-war-plugin 2.0.2 **/test/*.class and it works :-) Thierry B wrote: > > Hello, > > I've created a maven project with eclipse. > My maven project has 3 source folders : > > - src/main/resources > - src/main/java > - src/test/java > > When I use maven compile, it compiles all except the classes in > src/test/java, but as I use eclipse, when I modify something in > src/test/java, it compiles it also in target/classes as maven. > > The problem is that during war packaging, it includes all in > target/classes in my war so it includes test classes. > > I'd like to use maven plugin war, to tell him to exlude all classes java > in src/test/java. > > I read other threads that talking about not compile classes that we don't > want to have to packaging, but it's not pratical for me because eclipse > will compile all... > > I try that in my pom.xml : > > > org.apache.maven.plugins > maven-war-plugin > 2.0.2 > > > **/Exemple*.class > > > > > and I also try that : > > > org.apache.maven.plugins > maven-war-plugin > 2.0.2 > > > > target/classes/com/pv/rules/test/*.* > > > > > but it doesn't work. > > To be more precise on my structure, on my source folder stc/test/java, > I've created a package com.pv.rules.test where I put a test java classe. > > Do you have an idea? > > Thanks :-) > > > > > > > -- View this message in context: http://www.nabble.com/how-to-exclude-classes-from-package-in-target-classes-to-be-copied-to-WAR-in-packaging-tp21540465p21541182.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: AW: how to avoid build error if remote repository is nto available?
Hi strub, Thanks for your reply. Apologies I forgot to clarify that my 'remote repository' is indeed an instance of Artifactory but running in a managed service machine - I dont have a server available on my local/corporate network to install an instance of Artifactory unfortunately. Whats annoying is that Maven wont build my war since it complains it cant get the war plugin from my remote artifactory - since this network connection is down at present - but I have the plugin in my local machine $M2_HOME. So, my POM is missing some configuration I feel. Maven can definately access my local $M2_HOME since it installs my project artifacts there after a successful build. Thanks Jon struberg wrote: > >> Occassionally our remote - "central" - repository is unavailable > > Do you already use some kind of caching proxy like e.g. Archiva, > Artifactory, maven-proxy or Nexus? > > > If you are in a company I would _highly_ recommend setting up such a > proxy! > 1.) no complaining about public repos being offline anymore > 2.) you can backup the whole proxy cache and so your builds are also safe > in the future. > 3.) It will increase build times for your colleagues greatly. > 4.) helps to relieve the central repo if not everyone is stressing the > servers! > > LieGrue, > strub > > --- jonathan14 schrieb am Mo, 19.1.2009: >> Von: jonathan14 >> Betreff: how to avoid build error if remote repository is nto available? >> An: users@maven.apache.org >> Datum: Montag, 19. Januar 2009, 11:38 >> Hello >> >> >> Occassionally our remote - "central" - repository >> is unavailable, and when >> this occurs a local build fails because my local Maven >> cannot get the remote >> artifacts - whether they be plugins or my project >> components >> >> ie. >> [WARNING] repository metadata for: 'artifact >> org.apache.maven.plugins:maven-war-plugin' could not be >> retrieved from >> repository: central due to an error: Error transferring >> file >> >> >> Ive had a look at the onlnie documentation and a coupld of >> guides but cant >> figure out how to configure my project POM so that Maven >> can still build if >> it can find all the artifacts it needs in the local >> repository. I know the >> maven-war-plugin exists locally since I can see it in the >> file system. >> >> Further to this, can anyone tell me how in instruct Maven >> not to check >> remote repositories if it can find the artifact in the >> local one? >> >> Do I just make my local repository my default one? >> >> >> Thanks >> Jon >> >> >> -- >> View this message in context: >> http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21540454.html >> Sent from the Maven - Users mailing list archive at >> Nabble.com. >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org >> For additional commands, e-mail: >> users-h...@maven.apache.org > > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > > -- View this message in context: http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21541153.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Maven + POM + version + webapp context parameter
Hello, I would like to achieve the following: -retrieve the from a properties file so that I can include it in both the POM and my web.xml (context parameter). Does that make sense? How can I achieve this? Thanks, Julien.
Perform release without updating pom to new SNAPSHOT version
Hi, is it possible to do release:perfom which does everything like normal, except updating the pom.xml to a new SNAPSHOT version? We use branches per version, so if I release on my branch "int_module_1.0", I don't want the pom.xml to change to 1.1-SNAPSHOT. In fact, I want the branch to be locked. Is this supported by the release plugin? regards, Wim
Maven + POM + version + webapp context parameter
Hello, I would like to achieve the following: -retrieve the from a properties file so that I can include it in both the POM and my web.xml (context parameter). Does that make sense? How can I achieve this? Thanks, Julien.
AW: how to avoid build error if remote repository is nto available?
> Occassionally our remote - "central" - repository is unavailable Do you already use some kind of caching proxy like e.g. Archiva, Artifactory, maven-proxy or Nexus? If you are in a company I would _highly_ recommend setting up such a proxy! 1.) no complaining about public repos being offline anymore 2.) you can backup the whole proxy cache and so your builds are also safe in the future. 3.) It will increase build times for your colleagues greatly. 4.) helps to relieve the central repo if not everyone is stressing the servers! LieGrue, strub --- jonathan14 schrieb am Mo, 19.1.2009: > Von: jonathan14 > Betreff: how to avoid build error if remote repository is nto available? > An: users@maven.apache.org > Datum: Montag, 19. Januar 2009, 11:38 > Hello > > > Occassionally our remote - "central" - repository > is unavailable, and when > this occurs a local build fails because my local Maven > cannot get the remote > artifacts - whether they be plugins or my project > components > > ie. > [WARNING] repository metadata for: 'artifact > org.apache.maven.plugins:maven-war-plugin' could not be > retrieved from > repository: central due to an error: Error transferring > file > > > Ive had a look at the onlnie documentation and a coupld of > guides but cant > figure out how to configure my project POM so that Maven > can still build if > it can find all the artifacts it needs in the local > repository. I know the > maven-war-plugin exists locally since I can see it in the > file system. > > Further to this, can anyone tell me how in instruct Maven > not to check > remote repositories if it can find the artifact in the > local one? > > Do I just make my local repository my default one? > > > Thanks > Jon > > > -- > View this message in context: > http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21540454.html > Sent from the Maven - Users mailing list archive at > Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: > users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
SOLVED: How to exclude a package from compile
Thanks Justin, your answer was just what I needed! Actually - you have to configure the war plugin, but it uses the same syntax as the jar plugin. I now got: maven-war-plugin 2.1-alpha-2 false true true ${project.version} ${build.number} Thanks also for the hint of how to exclude classes - I wasn't even sure if I had to configure the compiler, jar or war plugin. With your hint, it now works! Thanks! Peter
how to exclude classes from package in target/classes to be copied to WAR in packaging
Hello, I've created a maven project with eclipse. My maven project has 3 source folders : - src/main/resources - src/main/java - src/test/java When I use maven compile, it compiles all except the classes in src/test/java, but as I use eclipse, when I modify something in src/test/java, it compiles it also in target/classes as maven. The problem is that during war packaging, it includes all in target/classes in my war so it includes test classes. I'd like to use maven plugin war, to tell him to exlude all classes java in src/test/java. I read other threads that talking about not compile classes that we don't want to have to packaging, but it's not pratical for me because eclipse will compile all... I try that in my pom.xml : org.apache.maven.plugins maven-war-plugin 2.0.2 **/Exemple*.class and I also try that : org.apache.maven.plugins maven-war-plugin 2.0.2 target/classes/com/pv/rules/test/*.* but it doesn't work. To be more precise on my structure, on my source folder stc/test/java, I've created a package com.pv.rules.test where I put a test java classe. Do you have an idea? Thanks :-) -- View this message in context: http://www.nabble.com/how-to-exclude-classes-from-package-in-target-classes-to-be-copied-to-WAR-in-packaging-tp21540465p21540465.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
how to avoid build error if remote repository is nto available?
Hello Occassionally our remote - "central" - repository is unavailable, and when this occurs a local build fails because my local Maven cannot get the remote artifacts - whether they be plugins or my project components ie. [WARNING] repository metadata for: 'artifact org.apache.maven.plugins:maven-war-plugin' could not be retrieved from repository: central due to an error: Error transferring file Ive had a look at the onlnie documentation and a coupld of guides but cant figure out how to configure my project POM so that Maven can still build if it can find all the artifacts it needs in the local repository. I know the maven-war-plugin exists locally since I can see it in the file system. Further to this, can anyone tell me how in instruct Maven not to check remote repositories if it can find the artifact in the local one? Do I just make my local repository my default one? Thanks Jon -- View this message in context: http://www.nabble.com/how-to-avoid-build-error-if-remote-repository-is-nto-available--tp21540454p21540454.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Uploading files created by assembly to server
Hi, I build some runable distribution files (zip, tar.gz etc.). I didn't solved it by attaching wagin-maven-plugin to a lifecycle. I tried deploy and install, but nothing happens, it seamed that wagin-maven-plugin didn't start. So I've solved it "hardcoded": --- SNIP --- ... org.codehaus.mojo wagon-maven-plugin 1.0-beta-1 target *.zip,*.jar,*.tar.gz,*.tar.bz2 sftp://${sfUsername}:${sfpasswo...@frs.sourceforge.net/ ${sfFrsPath} ... maven-release-plugin https://.../tags true assembly:assembly site-deploy wagon:upload ${sfUsername} ${sfPassword} ... --- SNAP --- I would prefere to use attaching to lifecycles and get different executions, so I've the option to use different wagon-maven-plugin actions. If you have some idea, I would like to test them. On Monday 19 January 2009 06:55:21 Dan Tran wrote: > Use build-helper-maven-plugin to attached your specific files to > maven, so that they can be deploy with the rest of other built > artifacts > > However, if you want to upload your files to somewhere else rather > maven repo, then use wagin-maven-plugin at deploy phase > > > -D > > On Sat, Jan 17, 2009 at 6:56 AM, Michael Decker wrote: > >Hi, > > > > I want to modify my "release:perform" goal, so it will automatically > > upload my assemblies to sourceforge, so I can easily provide them on the > > sourceforge download page. > > > > Yet I can build the assemblies and upload the site on using > > "release:perform" by using this: > >--- SNIP --- > > > > maven-release-plugin > > > >https: > >true > >assembly:assembly site-deploy > > > > > > > > > >--- SNAP --- > > > > So I wonder, how I can perform uploading of four files. > > > > There is Maven Wagon without any documentation: > > http://maven.apache.org/wagon/index.html > > > > And I found Maven Upload Plugin, that can upload a whole directory, but I > > want only four files saved in target directory: > > http://docs.atlassian.com/maven-upload-plugin/1.1/usage.html > > > > Perhaps someone can me help me on this. > > > > Thanks a lot. > > > > With regards signature.asc Description: This is a digitally signed message part.
how to increase performance of a multimodule (site) build?
Hi, I have a multi-module build with the following build times: [INFO] Total time: 11 minutes 56 seconds-> mvn clean install -B -U [INFO] Total time: 24 minutes 24 seconds-> site -B [INFO] Total time: 33 seconds -> javancss-maven-plugin:report -B [INFO] Total time: 25 seconds -> dashboard-maven-plugin:persist -B [INFO] Total time: 1 minute 1 second-> dashboard-maven-plugin:dashboard -B [INFO] Total time: 19 minutes 25 seconds-> mvn site:deploy -B Within the multi-module build I have some modules with JAXB code generation, WSDL code generation and so on, bound to the generate-sources phase. It seems, that this code generation is executed each time of the lifecycle phases, and that´s one reason why mvn site tooks so much time. So my first question is: Is there a way to prevent Maven from this behaviour ? My second question: website file:/W:/website/main tooks nearly 20min to deploy all files to a local directory on a WindowsXP build machine - how can I easily increase the performance of this step? Is there a significant difference to the other file protocols, lets say scp ? Thanx, Torsten
Re: What does this mean?
Holger Hoffstaette schrieb: On Sun, 18 Jan 2009 22:05:34 -0800, David Jencks wrote: Results : Tests run: 1837, Failures: 0, Errors: 0, Skipped: 0 [INFO] [ERROR] BUILD FAILURE [INFO] [INFO] There are test failures. Probably a subprocess that exited with return code != 0, which is interpreted as test failure. I think I've seen the same behaviour in the past but don't remember the details. I'm building activemq trunk. That's likely the problem :-> +1 for me... last time I tried activemq trunk I had to -Dmaven.test.skip=true ... cheers, tom -h - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: What does this mean?
On Sun, 18 Jan 2009 22:05:34 -0800, David Jencks wrote: > Results : > Tests run: 1837, Failures: 0, Errors: 0, Skipped: 0 > > [INFO] > > [ERROR] BUILD FAILURE > [INFO] > > [INFO] There are test failures. Probably a subprocess that exited with return code != 0, which is interpreted as test failure. I think I've seen the same behaviour in the past but don't remember the details. > I'm building activemq trunk. That's likely the problem :-> -h - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org