Re: Upgrading maven-embedder from 2.0.4 to 3.0.2

2011-03-29 Thread mraible

olamy wrote:
 
 Hello Matt.
 This doesn't exists anymore in 3.0.x.
 
 So for the maven3 integration in Hudson/Jenkins, I have build a
 quot;kindquot;
 of embedder which you can use at least for read projects.
 It should work to read projects and resolve dependencies.
 
 You can have a look at the unit tests here [1]
 
 [1]
 https://github.com/jenkinsci/lib-jenkins-maven-embedder/blob/master/src/test/java/hudson/maven/TestMavenEmbedderSimpleProject.java
 

I copied your MavenEmbedder into my project and got most of the dependencies
resolved. However, when I run it, I get the error below. I suspect this has
something to do with me trying to use the artifact-common dependency to test
artifacts.

You can see a patch of what I tried changing on the following JIRA issue.

http://issues.appfuse.org/browse/APF-1220

Any advice is greatly appreciated.

Running org.appfuse.mojo.installer.InstallArtifactsMojoTest
22:34:21,055  WARN org.sonatype.guice.bean.reflect.NamedClass - Error
injecting: org.apache.maven.profiles.DefaultMavenProfilesBuilder
java.lang.NoClassDefFoundError:
org/codehaus/plexus/util/interpolation/ValueSource
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getDeclaredConstructors(Class.java:1836)
at
com.google.inject.spi.InjectionPoint.forConstructorOf(InjectionPoint.java:243)
at
com.google.inject.internal.ConstructorBindingImpl.create(ConstructorBindingImpl.java:96)
at
com.google.inject.internal.InjectorImpl.createUninitializedBinding(InjectorImpl.java:628)
at
com.google.inject.internal.InjectorImpl.createJustInTimeBinding(InjectorImpl.java:835)
at
com.google.inject.internal.InjectorImpl.createJustInTimeBindingRecursive(InjectorImpl.java:769)
at
com.google.inject.internal.InjectorImpl.getJustInTimeBinding(InjectorImpl.java:254)
at
com.google.inject.internal.InjectorImpl.getBindingOrThrow(InjectorImpl.java:205)
at
com.google.inject.internal.InjectorImpl.getInternalFactory(InjectorImpl.java:843)
at
com.google.inject.internal.InjectorImpl.getProviderOrThrow(InjectorImpl.java:957)
at
com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:990)
at
com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:951)
at
com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1003)
at
org.sonatype.guice.bean.reflect.AbstractDeferredClass.get(AbstractDeferredClass.java:47)
at
com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:40)
at
com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)
at
com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1021)
at
com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at com.google.inject.Scopes$1$1.get(Scopes.java:59)
at
com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:40)
at
com.google.inject.internal.InjectorImpl$4$1.call(InjectorImpl.java:968)
at
com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1021)
at
com.google.inject.internal.InjectorImpl$4.get(InjectorImpl.java:964)
at
org.sonatype.guice.bean.locators.LazyBeanEntry.getValue(LazyBeanEntry.java:79)
at
org.sonatype.guice.plexus.locators.LazyPlexusBean.getValue(LazyPlexusBean.java:53)
at
org.sonatype.guice.plexus.binders.PlexusRequirements$RequirementProvider.get(PlexusRequirements.java:221)
at
org.sonatype.guice.plexus.binders.ProvidedPropertyBinding.injectProperty(ProvidedPropertyBinding.java:49)
at
org.sonatype.guice.bean.inject.BeanInjector.doInjection(BeanInjector.java:105)
at
org.sonatype.guice.bean.inject.BeanInjector.injectMembers(BeanInjector.java:76)
at
com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:120)
at
com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:94)
at
com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:254)
at
com.google.inject.internal.InjectorImpl$4$1.call(InjectorImpl.java:968)
at
com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1021)
at
com.google.inject.internal.InjectorImpl$4.get(InjectorImpl.java:964)
at
com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1003)
at
org.sonatype.guice.bean.reflect.AbstractDeferredClass.get(AbstractDeferredClass.java:47)
at
com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:40)
at

Re: Upgrading maven-embedder from 2.0.4 to 3.0.2

2011-03-07 Thread mraible
Any recommendations for developing an embedded Maven that will work for
both 2.x and 3.x users? My current setup works for 2.x users, but if I
upgrade to a new way for 3.x, I'm afraid it'll break 2.x support.

--
View this message in context: 
http://maven.40175.n5.nabble.com/Upgrading-maven-embedder-from-2-0-4-to-3-0-2-tp3379984p3413200.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: Upgrading maven-embedder from 2.0.4 to 3.0.2

2011-03-03 Thread mraible
This seems somewhat complicated - isn't there an easier way? Of the top 10
reasons to use Maven, #4 is it's easier to embed.

http://www.sonatype.com/people/2011/02/top-ten-reasons-to-move-to-maven-3/

--
View this message in context: 
http://maven.40175.n5.nabble.com/Upgrading-maven-embedder-from-2-0-4-to-3-0-2-tp3379984p3408943.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



Upgrading maven-embedder from 2.0.4 to 3.0.2

2011-02-10 Thread mraible

I'm trying to upgrade the dependencies of the appfuse-maven-plugin to use the
latest Maven dependencies to solve an issue with using Maven 3.

http://issues.appfuse.org/browse/APF-1220

However, when I upgrade to maven-embedder 3.0.2, there's a couple classes
missing: MavenEmbedder and MavenEmbedderConsoleLogger. I'm using these as
indicated below.

private MavenProject createProjectFromPom(File pom) {
MavenEmbedder maven = new MavenEmbedder();
maven.setOffline(true);
   
maven.setClassLoader(Thread.currentThread().getContextClassLoader());
maven.setLogger(new MavenEmbedderConsoleLogger());

MavenProject p = null;

try {
maven.setAlignWithUserInstallation(true);
maven.start();
p = maven.readProjectWithDependencies(pom);
maven.stop();
} catch (Exception e) {
e.printStackTrace();
}

return p;
}

Is it possible to do something like this with 3.0.2 and will it help me
solve this error?

A required class was missing while executing
org.appfuse.plugins:appfuse-maven-plugin:2.1.0-SNAPSHOT:full-source:
org/codehaus/plexus/embed/Embedder 
-- 
View this message in context: 
http://maven.40175.n5.nabble.com/Upgrading-maven-embedder-from-2-0-4-to-3-0-2-tp3379984p3379984.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



Running Tests in Parallel doesn't generate surefire-reports

2010-04-16 Thread mraible

When I add the parallelclasses/parallel element to my surefire-plugin
configuration, JUnit reports aren't generated in target/surefire-reports.
Any idea how to fix?

I've modeled my setup after the following blog post, without the fine print
or Spring changes.

http://incodewetrustinc.blogspot.com/2010/01/run-your-junit-tests-concurrently-with.html

dependency
groupIdjunit/groupId
artifactIdjunit/artifactId
version4.8.1/version
scopetest/scope
/dependency

plugin
artifactIdmaven-surefire-plugin/artifactId
version2.5/version
executions
execution
iddefault-test/id
configuration
parallelclasses/parallel
excludes
exclude**/*SeleniumTest.java/exclude
/excludes
/configuration
/execution
/executions
/plugin
-- 
View this message in context: 
http://old.nabble.com/Running-Tests-in-Parallel-doesn%27t-generate-surefire-reports-tp28270044p28270044.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



archetype:create-from-project works locally, but not in Bamboo

2009-04-30 Thread mraible

Any idea why Bamboo would be spitting out the following message?

Apr-2009 09:58:27   install-core:
29-Apr-2009 09:58:27[mkdir] Created dir: /opt/​j2ee/​domains/
appfuse.org/​builds/​webapps/​atlassian-bamboo/​ data/​data-1.2/​xml-data/
build-dir/​APF-TRUNK/​archetypes/​ appfuse-core/​target/​core-archetype
29-Apr-2009 09:58:27 [copy] Copying 27 files to /opt/​j2ee/​domains/
appfuse.org/​builds/​webapps/​atlassian-bamboo/​ data/​data-1.2/​xml-data/
build-dir/​APF-TRUNK/​archetypes/​ appfuse-core/​target/​core-archetype
29-Apr-2009 09:58:34 [exec] [INFO] Scanning for projects...
29-Apr-2009 09:58:38 [exec] [INFO] Searching repository for plugin
with prefix: 'archetype'.
29-Apr-2009 09:58:40 [exec] [INFO]

29-Apr-2009 09:58:40 [exec] [INFO] Building AppFuse Core Application
29-Apr-2009 09:58:40 [exec] [INFO]task-segment:
[archetype:create-from-project]
29-Apr-2009 09:58:40 [exec] [INFO]

29-Apr-2009 09:58:41 [exec] [INFO] [archetype:create-from-project]
29-Apr-2009 09:58:41 [exec] [INFO]

29-Apr-2009 09:58:41 [exec] [ERROR] BUILD ERROR
29-Apr-2009 09:58:41 [exec] [INFO]

29-Apr-2009 09:58:41 [exec] [INFO] Cannot create archetype from this
project.
29-Apr-2009 09:58:41 [exec]
29-Apr-2009 09:58:41 [exec] Embedded error: /opt/​j2ee/​domains/
appfuse.org/​builds/​webapps/​atlassian-bamboo/​ data/​data-1.2/​xml-data/
build-dir/​APF-TRUNK/​archetypes/​ appfuse-core/​target/​core-archetype/
src/​main/​archetype/​ archetype.properties (No such file or directory)
-- 
View this message in context: 
http://www.nabble.com/archetype%3Acreate-from-project-works-locally%2C-but-not-in-Bamboo-tp23318184p23318184.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



Issues with archetype:create-from-project

2009-04-28 Thread mraible

I've been using archetype:create-from-project to create archetypes and have
noticed some issues:

1. The generated archetype has a version of 1.0-SNAPSHOT. I want the
archetype's version to be the same as my project.

2. When I have an empty property (e.g. jdbc.password/jdbc.password),
it's removed from the resulting pom.xml.

3. When generating a multi-module archetype, the package names in my
hibernate.cfg.xml are replaced with ${package}. This doesn't happen when
generating a single-module archetype.

4. Package expansion doesn't happen for files in a package hierarchy under
src/main/resources.

5. I'm unable to set a description for the generated archetype.

6. Replacing of package names with ${package} seems to work different b/w
multi-module and single-module projects. In a multi-module project,
org.appfuse.webapp gets replaced with ${package}.webapp. In a
single-module project, org.appfuse.webapp gets replaced with ${package}.

7. TLD files are not scanned for packages to replace.

8. The web.xml file is not scanned for packages to replace.

I've been able to workaround most of these issues by using Ant to manipulate
the project after it's generated (before installing). Should I enter these
as issues in JIRA?

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Issues-with-archetype%3Acreate-from-project-tp23286970p23286970.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: Is it possible to add files to an archetype from other directories?

2009-04-27 Thread mraible

I was able to code a workaround using Ant to create the project then
archetype:create-from-project to create it. The nice thing about using Ant
to do this was I was also able to modify errors in the create process to
make working archetypes.

After doing this, I've discovered that the code I was using to materialize
archetypes automatically no longer works. The code is below and the error
I'm experiencing is as follows:

org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345)
at
org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009)
Caused by: org.apache.velocity.exception.ParseErrorException: Lexical error:
org.apache.velocity.runtime.parser.TokenMgrError: Lexical error at line 102,
column 93.  Encountered: EOF after : 
at org.apache.velocity.Template.process(Template.java:141)
at
org.apache.velocity.runtime.resource.ResourceManagerImpl.loadResource(ResourceManagerImpl.java:423)
at
org.apache.velocity.runtime.resource.ResourceManagerImpl.getResource(ResourceManagerImpl.java:341)
at
org.apache.velocity.runtime.RuntimeInstance.getTemplate(RuntimeInstance.java:831)
at
org.apache.velocity.app.VelocityEngine.mergeTemplate(VelocityEngine.java:440)
at
org.apache.maven.archetype.DefaultArchetype.processTemplate(DefaultArchetype.java:904)


protected void createTestProject(String archetypeArtifactId, String
archetypeVersion) throws Exception {
MavenProject project = getMavenProject();
FileUtils.deleteDirectory(getTestFile(target/ +
project.getArtifactId()));

MapString, String parameters = new HashMapString, String();

parameters.put(groupId, project.getGroupId());
parameters.put(artifactId, project.getArtifactId());
parameters.put(version, 1.0-SNAPSHOT);
parameters.put(basedir, getTestFile(target).getAbsolutePath());

Archetype archetype = (Archetype) lookup(Archetype.ROLE);

ArtifactRepositoryLayout layout =
(ArtifactRepositoryLayout)
container.lookup(ArtifactRepositoryLayout.ROLE, default);

String mavenRepoLocal = file:// + System.getProperty(user.home)
+ System.getProperty(file.separator) +
.m2 + System.getProperty(file.separator) + repository;
ArtifactRepository localRepository = new
DefaultArtifactRepository(local, mavenRepoLocal, layout);

ListArtifactRepository remoteRepositories = new
ArrayListArtifactRepository();
/*String mavenRepoRemote = http://repo1.maven.org/maven2;;
ArtifactRepository remoteRepository = new
DefaultArtifactRepository(remote, mavenRepoRemote, layout);

remoteRepositories.add(remoteRepository);*/

String archetypeGroupId = org.appfuse.archetypes;
archetype.createArchetype(archetypeGroupId, archetypeArtifactId,
archetypeVersion, localRepository,
remoteRepositories, parameters);
}

Any ideas?

Thanks,

Matt

Grant Rettke wrote:
 
 On Fri, Apr 24, 2009 at 4:24 AM, mraible m...@raibledesigns.com wrote:
 I'd like to hand-craft an archetype that consists of a single pom.xml and
 pulls it's sources from other modules/directories in my project. Is that
 possible?
 
 That seems to go against the grain of Maven.
 
 Does Maven make stuff like this easy?
 
 -
 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/Is-it-possible-to-add-files-to-an-archetype-from-other-directories--tp23212840p23265718.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: Is it possible to add files to an archetype from other directories?

2009-04-27 Thread mraible
;;
 ArtifactRepository remoteRepository = new
 DefaultArtifactRepository(remote, mavenRepoRemote, layout);
 
 remoteRepositories.add(remoteRepository);*/
 
 String archetypeGroupId = org.appfuse.archetypes;
 archetype.createArchetype(archetypeGroupId, archetypeArtifactId,
 archetypeVersion, localRepository,
 remoteRepositories, parameters);
 }
 
 Any ideas?
 
 Thanks,
 
 Matt
 
 Grant Rettke wrote:
  
  On Fri, Apr 24, 2009 at 4:24 AM, mraible m...@raibledesigns.com
 wrote:
  I'd like to hand-craft an archetype that consists of a single pom.xml
 and
  pulls it's sources from other modules/directories in my project. Is
 that
  possible?
  
  That seems to go against the grain of Maven.
  
  Does Maven make stuff like this easy?
  
  -
  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/Is-it-possible-to-add-files-to-an-archetype-from-other-directories--tp23212840p23265718.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
 
 
 _
 Rediscover Hotmail®: Get quick friend updates right in your inbox. 
 http://windowslive.com/RediscoverHotmail?ocid=TXT_TAGLM_WL_HM_Rediscover_Updates2_042009
 

-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-add-files-to-an-archetype-from-other-directories--tp23212840p23266743.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



Is it possible to add files to an archetype from other directories?

2009-04-24 Thread mraible

I'd like to hand-craft an archetype that consists of a single pom.xml and
pulls it's sources from other modules/directories in my project. Is that
possible?

In case anyone needs a more detailed explanation why, here goes...

I'm working on AppFuse, which contains many different archetypes and
stacks of frameworks. In the 2.0.x form, we used WARs and overlays and
have found it difficult for users to understand. Rather than pulling in WARs
(and reading their classpaths with the warpath plugin), I'd rather include
all the WAR source in an archetype. This evening, using the war-plugin and
Jetty's support for multiple source directories, I was able to modify things
so all the web/** projects can pull files from web/common/** and build their
WARs as normal, without needing to copy common files to all the modules.

If I want to use a similar setup with archetypes, I need to create a pom.xml
and an archetype descriptor, then slurp in all the files from web/common and
web/framework. If it's not possible to use ../.. notation in an archetype
descriptor, what's the best way to include these common files for new users?

Thanks,

Matt

P.S. I also tried using mvn archetype:create-from-project, but that doesn't
work b/c it 1) keeps the hierarchy of parent pom, which most users probably
won't like and 2) there's no way to automate the building/deploying of these
generated archetypes.
-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-add-files-to-an-archetype-from-other-directories--tp23212840p23212840.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



Is it possible to automatically append -DperformRelease=true to mvn deploy

2008-05-09 Thread mraible

Hello, 

When I deploy to my company's repository, I want to include artifact
javadocs and sources. The easiest way I've found to do this is to use mvn
deploy -DperformRelease=true. Is there anyway to automate the passing of
the flag so I can do mvn deploy and it has the same effect as mvn deploy
-DperformRelease=true?

Is using a profile (that gets activated on deploy) the best way to do this
or is it possible to define these plugins and have their executions run on
deploy?

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-automatically-append--DperformRelease%3Dtrue-to-mvn-deploy-tp17152685p17152685.html
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Is it possible to configure the maven-jar-plugin to use a prefix for classes?

2008-04-25 Thread mraible

Is it possible to configure the maven-jar-plugin to use a prefix for classes?

I want to put them in a directory other than the root.

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-configure-the-maven-jar-plugin-to-use-a-prefix-for-classes--tp16904340s177p16904340.html
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Code Coverage Plugins with Maven 2

2007-11-24 Thread mraible

I've created an issue for this in MOJO's JIRA. If this is the wrong location,
please let me know.

http://jira.codehaus.org/browse/MOJO-954

Matt


mraible wrote:
 
 This didn't work. AFAICT, the Cobertura and AspectJ plugin can't be
 activated at the same time if you want Cobertura reports to work.
 
 Matt
 
 
 mraible wrote:
 
 It looks like this is a known issue in the aspectj-maven-plugin. 
 
 http://jira.codehaus.org/browse/MOJO-456
 
 Looks like we're using the latest version, so I guess I need to add a new
 execution with a configuration to do weaveMainSourceFolder=false.
 
 Matt
 
 
 mraible wrote:
 
 Hmmm, it looks like the aspectj-maven-plugin is causing the problem. If
 I remove the following from my pom.xml, everything works fine:
 
 plugin
 groupIdorg.codehaus.mojo/groupId
 artifactIdaspectj-maven-plugin/artifactId
 version1.0-beta-2/version
 configuration
 source1.5/source
 verbosetrue/verbose
 complianceLevel1.5/complianceLevel
 showWeaveInfotrue/showWeaveInfo
 aspectLibraries
 aspectLibrary
 groupIdorg.springframework/groupId
 artifactIdspring-aspects/artifactId
 /aspectLibrary
 /aspectLibraries
 /configuration
 executions
 execution
 goals
 goalcompile/goal
 /goals
 /execution
 /executions
 /plugin
 
 Any ideas how to make the two play nicely together?
 
 Matt
 
 mraible wrote:
 
 This is what I'm using. However, it reports 0% coverage. Maybe this is
 caused by another plugin?
 
 Matt
 
 
 Iker Almandoz wrote:
 
 Matt, 
 Cobertura 2.0 works ok for me...
 
 My pom.xml has:
 
   build
plugins
 plugin
   groupIdorg.codehaus.mojo/groupId
   artifactIdcobertura-maven-plugin/artifactId
   version2.0/version
   /plugin
 
 
 That sets the cobertura version to 2.0 as the latest did not seem to
 work...
 
   reporting
   plugins
 
plugin
groupIdorg.codehaus.mojo/groupId
artifactIdcobertura-maven-plugin/artifactId
/plugin
 
 
 Regards, 
 Iker
 
 -Original Message-
 From: mraible [mailto:[EMAIL PROTECTED] 
 Sent: Monday, September 24, 2007 9:57 AM
 To: users@maven.apache.org
 Subject: Code Coverage Plugins with Maven 2
 
 
 AFAICT, the cobertura-maven-plugin (versions 2.0 and 2.1) doesn't work
 and
 neither does the emma-maven-plugin in Mojo's sandbox. Has anyone had
 any
 luck with either of these plugins? Is there an open source
 code-coverage
 plugin that works with Maven 2? I know about Clover, but that's not
 open
 source.
 
 Using Emma and Cobertura with Ant seem to work great.
 
 Thanks,
 
 Matt
 -- 
 View this message in context:
 http://www.nabble.com/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#
 a12863761
 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/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#a13926228
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: running hibernate3 plugin with jpaconfiguration

2007-09-24 Thread mraible

It works in AppFuse - maybe it'd help to look at our configuration.

Archetype creation commands  @
http://appfuse.org/display/APF/AppFuse+QuickStart

Change from Hibernate to JPA:
http://appfuse.org/display/APF/Using+JPA#UsingJPA-setup

HTH,

Matt


thebugslayer wrote:
 
 Hi,
 Can someone please help me see why I do not see my database table
 created after I ran $ mvn hibernate3:hbm2ddl? I don't have any errors,
 just database wasn't updated.
 
 This is my partial pom.xml
  plugin
 groupIdorg.codehaus.mojo/groupId
 artifactIdhibernate3-maven-plugin/artifactId
 version2.0-alpha-2/version
 configuration
 components
 component
 namehbm2ddl/name
 /component
 /components
 componentProperties
 
 implementationjpaconfiguration/implementation
 droptrue/drop
 createtrue/create
 exporttrue/export
 jdk5true/jdk5
 persistenceunitdefault/persistenceunit
 /componentProperties
 /configuration
 dependencies
 dependency
 groupIdmysql/groupId
 artifactIdmysql-connector-java/artifactId
 version5.0.5/version
 /dependency
 /dependencies
 /plugin
 
 Here is my persistence.xml
 ?xml version=1.0 encoding=UTF-8?
 persistence xmlns=http://java.sun.com/xml/ns/persistence;
  xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
  xsi:schemaLocation=http://java.sun.com/xml/ns/persistence
 http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd;
  version=1.0
 
 persistence-unit name=default
 providerorg.hibernate.ejb.HibernatePersistence/provider
 properties
 !-- Auto detect annotation model classes --
 property name=hibernate.archive.autodetection
 value=class/
 
 !-- Datasource --
 property name=hibernate.dialect
 value=org.hibernate.dialect.MySQLDialect/
 property name=hibernate.connection.driver_class
 value=com.mysql.jdbc.Driver/
 property name=hibernate.connection.username value=root/
 property name=hibernate.connection.password value=/
 property name=hibernate.connection.url
 value=jdbc:mysql://localhost/auction_dev/
 
 /properties
 /persistence-unit
 /persistence
 
 Here is my mvn output:
 [INFO] [hibernate3:hbm2ddl]
 04:40:52,707  INFO org.hibernate.ejb.Version - Hibernate EntityManager
 3.2.0.GA
 04:40:52,723  INFO org.hibernate.cfg.annotations.Version - Hibernate
 Annotations 3.2.0.GA
 04:40:52,730  INFO org.hibernate.cfg.Environment - Hibernate 3.2.0.cr5
 04:40:52,734  INFO org.hibernate.cfg.Environment -
 hibernate.properties not found
 04:40:52,735  INFO org.hibernate.cfg.Environment - Bytecode provider
 name : cglib
 04:40:52,740  INFO org.hibernate.cfg.Environment - using JDK 1.4
 java.sql.Timestamp handling
 [DEBUG] basedir: /Users/zemian/Desktop/projects/auction
 [INFO] src/main/resources/hibernate.cfg.xml not found within the
 project. Trying absolute path.
 [INFO] No hibernate configuration file loaded.
 [INFO] src/main/resources/database.properties not found within the
 project. Trying absolute path.
 [INFO] No hibernate properties file loaded.
 04:40:53,067  INFO org.hibernate.dialect.Dialect - Using dialect:
 org.hibernate.dialect.MySQLDialect
 04:40:53,108  INFO org.hibernate.tool.hbm2ddl.SchemaExport - Running
 hbm2ddl schema export
 04:40:53,109  INFO org.hibernate.tool.hbm2ddl.SchemaExport - exporting
 generated schema to database
 04:40:53,112  INFO
 org.hibernate.connection.DriverManagerConnectionProvider - Using
 Hibernate built-in connection pool (not for production use!)
 04:40:53,112  INFO
 org.hibernate.connection.DriverManagerConnectionProvider - Hibernate
 connection pool size: 20
 04:40:53,112  INFO
 org.hibernate.connection.DriverManagerConnectionProvider - autocommit
 mode: true
 04:40:53,116  INFO
 org.hibernate.connection.DriverManagerConnectionProvider - using
 driver: com.mysql.jdbc.Driver at URL:
 jdbc:mysql://localhost/auction_dev
 04:40:53,116  INFO
 org.hibernate.connection.DriverManagerConnectionProvider - connection
 properties: {user=root, password=, autocommit=true,
 release_mode=auto}
 04:40:53,329  INFO org.hibernate.tool.hbm2ddl.SchemaExport - schema
 export complete
 04:40:53,330  INFO
 org.hibernate.connection.DriverManagerConnectionProvider - cleaning up
 connection pool: jdbc:mysql://localhost/auction_dev
 [INFO]
 
 [INFO] BUILD SUCCESSFUL
 [INFO]
 
 
 

Code Coverage Plugins with Maven 2

2007-09-24 Thread mraible

AFAICT, the cobertura-maven-plugin (versions 2.0 and 2.1) doesn't work and
neither does the emma-maven-plugin in Mojo's sandbox. Has anyone had any
luck with either of these plugins? Is there an open source code-coverage
plugin that works with Maven 2? I know about Clover, but that's not open
source.

Using Emma and Cobertura with Ant seem to work great.

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#a12863761
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: Code Coverage Plugins with Maven 2

2007-09-24 Thread mraible

This is what I'm using. However, it reports 0% coverage. Maybe this is caused
by another plugin?

Matt


Iker Almandoz wrote:
 
 Matt, 
 Cobertura 2.0 works ok for me...
 
 My pom.xml has:
 
   build
plugins
 plugin
   groupIdorg.codehaus.mojo/groupId
   artifactIdcobertura-maven-plugin/artifactId
   version2.0/version
   /plugin
 
 
 That sets the cobertura version to 2.0 as the latest did not seem to
 work...
 
   reporting
   plugins
 
plugin
groupIdorg.codehaus.mojo/groupId
artifactIdcobertura-maven-plugin/artifactId
/plugin
 
 
 Regards, 
 Iker
 
 -Original Message-
 From: mraible [mailto:[EMAIL PROTECTED] 
 Sent: Monday, September 24, 2007 9:57 AM
 To: users@maven.apache.org
 Subject: Code Coverage Plugins with Maven 2
 
 
 AFAICT, the cobertura-maven-plugin (versions 2.0 and 2.1) doesn't work and
 neither does the emma-maven-plugin in Mojo's sandbox. Has anyone had any
 luck with either of these plugins? Is there an open source code-coverage
 plugin that works with Maven 2? I know about Clover, but that's not open
 source.
 
 Using Emma and Cobertura with Ant seem to work great.
 
 Thanks,
 
 Matt
 -- 
 View this message in context:
 http://www.nabble.com/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#
 a12863761
 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/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#a12864295
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: Code Coverage Plugins with Maven 2

2007-09-24 Thread mraible

Hmmm, it looks like the aspectj-maven-plugin is causing the problem. If I
remove the following from my pom.xml, everything works fine:

plugin
groupIdorg.codehaus.mojo/groupId
artifactIdaspectj-maven-plugin/artifactId
version1.0-beta-2/version
configuration
source1.5/source
verbosetrue/verbose
complianceLevel1.5/complianceLevel
showWeaveInfotrue/showWeaveInfo
aspectLibraries
aspectLibrary
groupIdorg.springframework/groupId
artifactIdspring-aspects/artifactId
/aspectLibrary
/aspectLibraries
/configuration
executions
execution
goals
goalcompile/goal
/goals
/execution
/executions
/plugin

Any ideas how to make the two play nicely together?

Matt

mraible wrote:
 
 This is what I'm using. However, it reports 0% coverage. Maybe this is
 caused by another plugin?
 
 Matt
 
 
 Iker Almandoz wrote:
 
 Matt, 
 Cobertura 2.0 works ok for me...
 
 My pom.xml has:
 
   build
plugins
 plugin
  groupIdorg.codehaus.mojo/groupId
  artifactIdcobertura-maven-plugin/artifactId
  version2.0/version
  /plugin
 
 
 That sets the cobertura version to 2.0 as the latest did not seem to
 work...
 
   reporting
   plugins
 
plugin
groupIdorg.codehaus.mojo/groupId
artifactIdcobertura-maven-plugin/artifactId
/plugin
 
 
 Regards, 
 Iker
 
 -Original Message-
 From: mraible [mailto:[EMAIL PROTECTED] 
 Sent: Monday, September 24, 2007 9:57 AM
 To: users@maven.apache.org
 Subject: Code Coverage Plugins with Maven 2
 
 
 AFAICT, the cobertura-maven-plugin (versions 2.0 and 2.1) doesn't work
 and
 neither does the emma-maven-plugin in Mojo's sandbox. Has anyone had any
 luck with either of these plugins? Is there an open source code-coverage
 plugin that works with Maven 2? I know about Clover, but that's not open
 source.
 
 Using Emma and Cobertura with Ant seem to work great.
 
 Thanks,
 
 Matt
 -- 
 View this message in context:
 http://www.nabble.com/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#
 a12863761
 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/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#a12864355
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: Code Coverage Plugins with Maven 2

2007-09-24 Thread mraible

It looks like this is a known issue in the aspectj-maven-plugin. 

http://jira.codehaus.org/browse/MOJO-456

Looks like we're using the latest version, so I guess I need to add a new
execution with a configuration to do weaveMainSourceFolder=false.

Matt


mraible wrote:
 
 Hmmm, it looks like the aspectj-maven-plugin is causing the problem. If I
 remove the following from my pom.xml, everything works fine:
 
 plugin
 groupIdorg.codehaus.mojo/groupId
 artifactIdaspectj-maven-plugin/artifactId
 version1.0-beta-2/version
 configuration
 source1.5/source
 verbosetrue/verbose
 complianceLevel1.5/complianceLevel
 showWeaveInfotrue/showWeaveInfo
 aspectLibraries
 aspectLibrary
 groupIdorg.springframework/groupId
 artifactIdspring-aspects/artifactId
 /aspectLibrary
 /aspectLibraries
 /configuration
 executions
 execution
 goals
 goalcompile/goal
 /goals
 /execution
 /executions
 /plugin
 
 Any ideas how to make the two play nicely together?
 
 Matt
 
 mraible wrote:
 
 This is what I'm using. However, it reports 0% coverage. Maybe this is
 caused by another plugin?
 
 Matt
 
 
 Iker Almandoz wrote:
 
 Matt, 
 Cobertura 2.0 works ok for me...
 
 My pom.xml has:
 
   build
plugins
 plugin
 groupIdorg.codehaus.mojo/groupId
 artifactIdcobertura-maven-plugin/artifactId
 version2.0/version
 /plugin
 
 
 That sets the cobertura version to 2.0 as the latest did not seem to
 work...
 
   reporting
   plugins
 
plugin
groupIdorg.codehaus.mojo/groupId
artifactIdcobertura-maven-plugin/artifactId
/plugin
 
 
 Regards, 
 Iker
 
 -Original Message-
 From: mraible [mailto:[EMAIL PROTECTED] 
 Sent: Monday, September 24, 2007 9:57 AM
 To: users@maven.apache.org
 Subject: Code Coverage Plugins with Maven 2
 
 
 AFAICT, the cobertura-maven-plugin (versions 2.0 and 2.1) doesn't work
 and
 neither does the emma-maven-plugin in Mojo's sandbox. Has anyone had any
 luck with either of these plugins? Is there an open source code-coverage
 plugin that works with Maven 2? I know about Clover, but that's not open
 source.
 
 Using Emma and Cobertura with Ant seem to work great.
 
 Thanks,
 
 Matt
 -- 
 View this message in context:
 http://www.nabble.com/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#
 a12863761
 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/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#a12864482
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: Code Coverage Plugins with Maven 2

2007-09-24 Thread mraible

This didn't work. AFAICT, the Cobertura and AspectJ plugin can't be activated
at the same time if you want Cobertura reports to work.

Matt


mraible wrote:
 
 It looks like this is a known issue in the aspectj-maven-plugin. 
 
 http://jira.codehaus.org/browse/MOJO-456
 
 Looks like we're using the latest version, so I guess I need to add a new
 execution with a configuration to do weaveMainSourceFolder=false.
 
 Matt
 
 
 mraible wrote:
 
 Hmmm, it looks like the aspectj-maven-plugin is causing the problem. If I
 remove the following from my pom.xml, everything works fine:
 
 plugin
 groupIdorg.codehaus.mojo/groupId
 artifactIdaspectj-maven-plugin/artifactId
 version1.0-beta-2/version
 configuration
 source1.5/source
 verbosetrue/verbose
 complianceLevel1.5/complianceLevel
 showWeaveInfotrue/showWeaveInfo
 aspectLibraries
 aspectLibrary
 groupIdorg.springframework/groupId
 artifactIdspring-aspects/artifactId
 /aspectLibrary
 /aspectLibraries
 /configuration
 executions
 execution
 goals
 goalcompile/goal
 /goals
 /execution
 /executions
 /plugin
 
 Any ideas how to make the two play nicely together?
 
 Matt
 
 mraible wrote:
 
 This is what I'm using. However, it reports 0% coverage. Maybe this is
 caused by another plugin?
 
 Matt
 
 
 Iker Almandoz wrote:
 
 Matt, 
 Cobertura 2.0 works ok for me...
 
 My pom.xml has:
 
   build
plugins
 plugin
groupIdorg.codehaus.mojo/groupId
artifactIdcobertura-maven-plugin/artifactId
version2.0/version
/plugin
 
 
 That sets the cobertura version to 2.0 as the latest did not seem to
 work...
 
   reporting
   plugins
 
plugin
groupIdorg.codehaus.mojo/groupId
artifactIdcobertura-maven-plugin/artifactId
/plugin
 
 
 Regards, 
 Iker
 
 -Original Message-
 From: mraible [mailto:[EMAIL PROTECTED] 
 Sent: Monday, September 24, 2007 9:57 AM
 To: users@maven.apache.org
 Subject: Code Coverage Plugins with Maven 2
 
 
 AFAICT, the cobertura-maven-plugin (versions 2.0 and 2.1) doesn't work
 and
 neither does the emma-maven-plugin in Mojo's sandbox. Has anyone had
 any
 luck with either of these plugins? Is there an open source
 code-coverage
 plugin that works with Maven 2? I know about Clover, but that's not
 open
 source.
 
 Using Emma and Cobertura with Ant seem to work great.
 
 Thanks,
 
 Matt
 -- 
 View this message in context:
 http://www.nabble.com/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#
 a12863761
 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/Code-Coverage-Plugins-with-Maven-2-tf4510331s177.html#a12864765
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Issue with maven-eclipse-plugin 2.4: java.lang.NoClassDefFoundError: org/codehaus/plexus/util/IOUtil

2007-09-20 Thread mraible

Any idea what could be causing this? I get it when running mvn
eclipse:eclipse on a modular project. I'm on OS X with JDK 5. 

[INFO]

[ERROR] FATAL ERROR
[INFO]

[INFO] org/codehaus/plexus/util/IOUtil
[INFO]

[INFO] Trace
java.lang.NoClassDefFoundError: org/codehaus/plexus/util/IOUtil
at
org.apache.maven.plugin.ide.AbstractIdeSupportMojo.resolveSourceAndJavadocArtifacts(AbstractIdeSupportMojo.java:886)
at
org.apache.maven.plugin.ide.AbstractIdeSupportMojo.execute(AbstractIdeSupportMojo.java:470)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:443)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:539)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:493)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:463)

To reproduce:

1. mvn archetype:create -DarchetypeGroupId=org.appfuse.archetypes
-DarchetypeArtifactId=appfuse-modular-jsf
-DremoteRepositories=http://static.appfuse.org/releases
-DarchetypeVersion=2.0 -DgroupId=com.mycompany.app -DartifactId=myproject

2. cd myproject;mvn eclipse:eclipse

Matt
-- 
View this message in context: 
http://www.nabble.com/Issue-with-maven-eclipse-plugin-2.4%3A-java.lang.NoClassDefFoundError%3A-org-codehaus-plexus-util-IOUtil-tf4487130s177.html#a12795813
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: Issue with maven-eclipse-plugin 2.4: java.lang.NoClassDefFoundError: org/codehaus/plexus/util/IOUtil

2007-09-20 Thread mraible

You can use -Ph2 to use H2 instead of MySQL. You can also run with
-Dmaven.test.skip=true to bypass all the connecting to the database and
downloading of Tomcat to run Cargo/WebTest tests.

Matt


Wayne Fay wrote:
 
 I couldn't even get the first step to work correctly:
 
 [INFO]
 
 [ERROR] BUILD ERROR
 [INFO]
 
 [INFO] Error creating from archetype
 
 Embedded error: Error processing templates.
 Encountered  pageContext.request.remoteUser}\li \c:url \
 class=\current\fmt:mes
 sage key=\login.title\/ /li/c:if\r\nmenu:displayMenu
 name=\MainMenu\/\r\nmenu:displayMenu name=\
 UserMenu\/\r\nmenu:displayMenu name=\AdminMenu\/\r\n
 menu:displayMenu name=\Logout\/\r\n/ul\r\n/menu
 :useMenuDisplayer at line 6, column 24.
 Was expecting one of:
 } ...
 DOT ...
 
 The reason is that I apparently had a less-than-latest version of
 m-archetype-p. I updated with -U and got 1.0-alpha-7 which worked
 successfully.
 
 
 I also noticed something kinda odd -- see the WARNING below:
 
 Downloading:
 http://repository.codehaus.org/aspectj/aspectjtools/1.5.2a/aspectjtools-1.5.2a.jar
 Downloading:
 http://repo1.maven.org/maven2/aspectj/aspectjtools/1.5.2a/aspectjtools-1.5.2a.jar
 [INFO] [aspectj:compile {execution: default}]
 [WARNING] bad version number found in C:\Documents and
 Settings\WFay\.m2\repository\aspectj\aspectjrt\1.5.3\aspectjrt-1.
 5.3.jar expected 1.5.2a found 1.5.3
 
 Tried to run mvn eclipse:eclipse and it failed to resolve artifact
 for the myproject-core:jar. So I tried mvn install and it failed since
 I don't have a Mysql db running right this minute.
 
 So maybe later this afternoon if I have a few minutes free I can see
 about getting past that error. But I have yet to get to your problem,
 it seems.
 
 Wayne
 
 On 9/20/07, mraible [EMAIL PROTECTED] wrote:

 Any idea what could be causing this? I get it when running mvn
 eclipse:eclipse on a modular project. I'm on OS X with JDK 5.

 [INFO]
 
 [ERROR] FATAL ERROR
 [INFO]
 
 [INFO] org/codehaus/plexus/util/IOUtil
 [INFO]
 
 [INFO] Trace
 java.lang.NoClassDefFoundError: org/codehaus/plexus/util/IOUtil
at
 org.apache.maven.plugin.ide.AbstractIdeSupportMojo.resolveSourceAndJavadocArtifacts(AbstractIdeSupportMojo.java:886)
at
 org.apache.maven.plugin.ide.AbstractIdeSupportMojo.execute(AbstractIdeSupportMojo.java:470)
at
 org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:443)
at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:539)
at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:493)
at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:463)

 To reproduce:

 1. mvn archetype:create -DarchetypeGroupId=org.appfuse.archetypes
 -DarchetypeArtifactId=appfuse-modular-jsf
 -DremoteRepositories=http://static.appfuse.org/releases
 -DarchetypeVersion=2.0 -DgroupId=com.mycompany.app -DartifactId=myproject

 2. cd myproject;mvn eclipse:eclipse

 Matt
 --
 View this message in context:
 http://www.nabble.com/Issue-with-maven-eclipse-plugin-2.4%3A-java.lang.NoClassDefFoundError%3A-org-codehaus-plexus-util-IOUtil-tf4487130s177.html#a12795813
 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/Issue-with-maven-eclipse-plugin-2.4%3A-java.lang.NoClassDefFoundError%3A-org-codehaus-plexus-util-IOUtil-tf4487130s177.html#a12798634
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: Issue with maven-eclipse-plugin 2.4: java.lang.NoClassDefFoundError: org/codehaus/plexus/util/IOUtil

2007-09-20 Thread mraible

Running mvn -U didn't fix the problem, but rm -r ~/.m2/repository/* did.
;-)

Thanks,

Matt


Wayne Fay wrote:
 
 Thanks Matt, that does it. mvn install was successful. And then mvn
 eclipse:eclipse was successful too.
 
 [INFO] Wrote Eclipse project for myproject-core to
 C:\cvs_root\myproject\core.
 ...
 [INFO] Wrote Eclipse project for myproject-webapp to
 C:\cvs_root\myproject\web.
 ...
 [INFO] BUILD SUCCESSFUL
 
 So I have to assume you simply have some weird versions of things or
 bad poms or something in your repo cache... Try -U to update
 everything (??).
 
 Wayne
 
 On 9/20/07, mraible [EMAIL PROTECTED] wrote:

 You can use -Ph2 to use H2 instead of MySQL. You can also run with
 -Dmaven.test.skip=true to bypass all the connecting to the database and
 downloading of Tomcat to run Cargo/WebTest tests.

 Matt


 Wayne Fay wrote:
 
  I couldn't even get the first step to work correctly:
 
  [INFO]
 
 
  [ERROR] BUILD ERROR
  [INFO]
 
 
  [INFO] Error creating from archetype
 
  Embedded error: Error processing templates.
  Encountered  pageContext.request.remoteUser}\li \c:url \
  class=\current\fmt:mes
  sage key=\login.title\/ /li/c:if\r\nmenu:displayMenu
  name=\MainMenu\/\r\nmenu:displayMenu name=\
  UserMenu\/\r\nmenu:displayMenu name=\AdminMenu\/\r\n
  menu:displayMenu name=\Logout\/\r\n/ul\r\n/menu
  :useMenuDisplayer at line 6, column 24.
  Was expecting one of:
  } ...
  DOT ...
 
  The reason is that I apparently had a less-than-latest version of
  m-archetype-p. I updated with -U and got 1.0-alpha-7 which worked
  successfully.
 
 
  I also noticed something kinda odd -- see the WARNING below:
 
  Downloading:
 
 http://repository.codehaus.org/aspectj/aspectjtools/1.5.2a/aspectjtools-1.5.2a.jar
  Downloading:
 
 http://repo1.maven.org/maven2/aspectj/aspectjtools/1.5.2a/aspectjtools-1.5.2a.jar
  [INFO] [aspectj:compile {execution: default}]
  [WARNING] bad version number found in C:\Documents and
  Settings\WFay\.m2\repository\aspectj\aspectjrt\1.5.3\aspectjrt-1.
  5.3.jar expected 1.5.2a found 1.5.3
 
  Tried to run mvn eclipse:eclipse and it failed to resolve artifact
  for the myproject-core:jar. So I tried mvn install and it failed since
  I don't have a Mysql db running right this minute.
 
  So maybe later this afternoon if I have a few minutes free I can see
  about getting past that error. But I have yet to get to your problem,
  it seems.
 
  Wayne
 
  On 9/20/07, mraible [EMAIL PROTECTED] wrote:
 
  Any idea what could be causing this? I get it when running mvn
  eclipse:eclipse on a modular project. I'm on OS X with JDK 5.
 
  [INFO]
 
 
  [ERROR] FATAL ERROR
  [INFO]
 
 
  [INFO] org/codehaus/plexus/util/IOUtil
  [INFO]
 
 
  [INFO] Trace
  java.lang.NoClassDefFoundError: org/codehaus/plexus/util/IOUtil
 at
 
 org.apache.maven.plugin.ide.AbstractIdeSupportMojo.resolveSourceAndJavadocArtifacts(AbstractIdeSupportMojo.java:886)
 at
 
 org.apache.maven.plugin.ide.AbstractIdeSupportMojo.execute(AbstractIdeSupportMojo.java:470)
 at
 
 org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:443)
 at
 
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:539)
 at
 
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:493)
 at
 
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:463)
 
  To reproduce:
 
  1. mvn archetype:create -DarchetypeGroupId=org.appfuse.archetypes
  -DarchetypeArtifactId=appfuse-modular-jsf
  -DremoteRepositories=http://static.appfuse.org/releases
  -DarchetypeVersion=2.0 -DgroupId=com.mycompany.app
 -DartifactId=myproject
 
  2. cd myproject;mvn eclipse:eclipse
 
  Matt
  --
  View this message in context:
 
 http://www.nabble.com/Issue-with-maven-eclipse-plugin-2.4%3A-java.lang.NoClassDefFoundError%3A-org-codehaus-plexus-util-IOUtil-tf4487130s177.html#a12795813
  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/Issue-with-maven-eclipse-plugin-2.4%3A-java.lang.NoClassDefFoundError%3A-org-codehaus-plexus-util-IOUtil-tf4487130s177.html#a12798634
 Sent from

Re: Is it possible to customize maven-war-plugin so JARs aren't put in src/main/webapp/WEB-INF/lib when using war:inplace?

2007-09-18 Thread mraible

I tried this and it doesn't work.

warSourceExcludesWEB-INF/lib/**,WEB-INF/classes/struts.xml/warSourceExcludes

I also tried customizing it just for the war:inplace goal:

executions
execution
idwar-inplace/id
goals
goalinplace/goal
/goals
configuration
   
warSourceExcludesWEB-INF/lib/**,WEB-INF/classes/struts.xml/warSourceExcludes
/configuration
/execution
/executions

I'm using maven-war-plugin version 2.0.2.

Thanks,

Matt



Tim Kettler wrote:
 
 Hi,
 
 warSourceExcludesWEB-INF/lib/*.jar,...,.../warSourceExcludes [1]
 
 -Tim
 
 [1] http://maven.apache.org/plugins/maven-war-plugin/inplace-mojo.html
 
 mraible schrieb:
 Is it possible to customize maven-war-plugin so JARs aren't put in
 src/main/webapp/WEB-INF/lib when using war:inplace?
 
 I'd like to stop JARs from getting put in this directory (if I remove it,
 jetty:run still works fine), as well as exclude some files from
 src/main/resources (because Jetty picks those up too).
 
 Thanks,
 
 Matt
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-customize-maven-war-plugin-so-JARs-aren%27t-put-in-src-main-webapp-WEB-INF-lib-when-using-war%3Ainplace--tf4466701s177.html#a12759424
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Is it possible to customize maven-war-plugin so JARs aren't put in src/main/webapp/WEB-INF/lib when using war:inplace?

2007-09-17 Thread mraible

Is it possible to customize maven-war-plugin so JARs aren't put in
src/main/webapp/WEB-INF/lib when using war:inplace?

I'd like to stop JARs from getting put in this directory (if I remove it,
jetty:run still works fine), as well as exclude some files from
src/main/resources (because Jetty picks those up too).

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-customize-maven-war-plugin-so-JARs-aren%27t-put-in-src-main-webapp-WEB-INF-lib-when-using-war%3Ainplace--tf4466701s177.html#a12735845
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Using Ant to test Maven Plugins

2007-05-31 Thread mraible

I'm using Ant to test a Maven Plugin (as well as archetypes). I tried using
Maven Embedder, but was unable to get it to execute some of my extension
plugins with version 2.0.4.  Now I'm having issues getting Ant to fail
properly when executing Maven fails.  I'm sure this is probably more of an
Ant question, but hopefully someone here can help.

In my build.xml, I have a macrodef to execute Maven on various platforms:

macrodef name=maven
attribute name=dir/
attribute name=name default=/
attribute name=archetype default=/
attribute name=version default=/
attribute name=command default=archetype:create
-DarchetypeGroupId=org.appfuse [EMAIL PROTECTED]
[EMAIL PROTECTED] -DgroupId=com.company [EMAIL PROTECTED]/

sequential
exec dir=@{dir} executable=mvn.bat os=Windows XP
failonerror=true errorproperty=command.failed
arg line=@{command}/
/exec
exec dir=@{dir} executable=mvn os=Mac OS X
failonerror=true errorproperty=command.failed
arg line=@{command}/
/exec
exec dir=@{dir} executable=mvn os=Linux
failonerror=true errorproperty=command.failed
arg line=@{command}/
/exec

/sequential
/macrodef

I have another macrodef that calls this one:

macrodef name=create-gen-basic
attribute name=archetype/
attribute name=version default=${version}/
attribute name=name/

sequential
delete dir=${test.dir}/@{name}/
mkdir dir=${test.dir}/
maven dir=${test.dir} archetype=@{archetype}
version=@{version} name=@{name}/

!-- copy Person.java to src --
copy todir=${test.dir}/@{name}/src/main/java/com
fileset dir=src/test/java/com includes=**/*.java/
/copy

!-- add Person to hibernate.cfg.xml --
replace
file=${test.dir}/@{name}/src/main/resources/hibernate.cfg.xml
replacetoken![CDATA[mapping
class=org.appfuse.model.Role/]]/replacetoken
replacevalue![CDATA[mapping
class=org.appfuse.model.Role/
mapping class=com.company.model.Person/]]/replacevalue
/replace

!-- run gen install integration-test --
maven dir=${test.dir}/@{name} command=appfuse:gen
-Dentity=Person/
maven dir=${test.dir}/@{name} command=appfuse:install
-Dentity=Person/
maven dir=${test.dir}/@{name} command=integration-test/

!-- test w/o generic core --
maven dir=${test.dir}/@{name} command=appfuse:gen
-Dentity=Person -Damp.genericCore=false/
maven dir=${test.dir}/@{name} command=appfuse:install
-Dentity=Person -Damp.genericCore=false/
maven dir=${test.dir}/@{name} command=integration-test/
/sequential
/macrodef

The problem I'm experiencing is if any of the maven calls fail, the build
continues and I get no warnings failures.

The full build file is available at:

http://tinyurl.com/2aopar

If anyone has a solution, please let me know. I realize that I could
probably use Maven Embedder 2.1-SNAPSHOT to solve this, but I'd rather not
depend on something that's fluctuating.

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Using-Ant-to-test-Maven-Plugins-tf3848312s177.html#a10900020
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Maven Embedder Example?

2007-05-07 Thread mraible

Does anyone have a Maven Embedder example that runs archetype:create?  I'd
like to create an archetype, run a plugin and verify that files are created
in the new project.  I could run the archetype creation and plugin with Ant,
but that doesn't seem to be a very good way to test the code generation
plugin I'm writing.

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Maven-Embedder-Example--tf3706476s177.html#a10366156
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 Embedder Example?

2007-05-07 Thread mraible

I figured out how to generate an archetype programmatically (see code below).
Now I'm trying to execute goals w/in that project using MavenEmbedder. It
seems to *almost* works, except that a plugin with
extensionstrue/extensions is failing. Does the MavenEmbedder not
support plugins with extensions?

Thanks,

Matt

protected void createTestProject(String archetypeArtifactId, String
archetypeVersion) throws Exception {
MavenProject project = getMavenProject();
FileUtils.deleteDirectory(getTestFile(target/ +
project.getArtifactId()));

MapString, String parameters = new HashMapString, String();

parameters.put(groupId, project.getGroupId());
parameters.put(artifactId, project.getArtifactId());
parameters.put(version, 1.0-SNAPSHOT);
parameters.put(basedir, getTestFile(target).getAbsolutePath());

Archetype archetype = (Archetype) lookup(Archetype.ROLE);

ArtifactRepositoryLayout layout =
(ArtifactRepositoryLayout)
container.lookup(ArtifactRepositoryLayout.ROLE, default);

String mavenRepoLocal = project.getRepositories().get(0).toString();

ArtifactRepository localRepository = new
DefaultArtifactRepository(local, mavenRepoLocal, layout);

ListArtifactRepository remoteRepositories = new
ArrayListArtifactRepository();
String mavenRepoRemote = http://static.appfuse.org/repository;;
ArtifactRepository remoteRepository = new
DefaultArtifactRepository(remote, mavenRepoRemote, layout);

remoteRepositories.add(remoteRepository);

String archetypeGroupId = org.appfuse;
archetype.createArchetype(archetypeGroupId, archetypeArtifactId,
archetypeVersion, localRepository,
remoteRepositories, parameters);
}


mraible wrote:
 
 Does anyone have a Maven Embedder example that runs archetype:create?  I'd
 like to create an archetype, run a plugin and verify that files are
 created in the new project.  I could run the archetype creation and plugin
 with Ant, but that doesn't seem to be a very good way to test the code
 generation plugin I'm writing.
 
 Thanks,
 
 Matt
 

-- 
View this message in context: 
http://www.nabble.com/Maven-Embedder-Example--tf3706476s177.html#a10367706
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Getting releases automatically rsynched to central

2007-04-17 Thread mraible

I'd like to see about getting AppFuse releases automatically synched to
Maven's central repo. How do I go about doing this. The FAQ[1] says ask this
on dev@, but I was scared off by the big yellow banner[2] that said post
questions to [EMAIL PROTECTED] ;-)

I'm prepared to post releases to a publicly available URL (i.e.
http://static.appfuse.org/releases), but don't know if that's sufficient.

Thanks,

Matt

[1] http://maven.apache.org/project-faq.html
[2] http://www.nabble.com/Maven-Developers-f179.html
-- 
View this message in context: 
http://www.nabble.com/Getting-releases-automatically-rsynched-to-central-tf3597718s177.html#a10048290
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] Color logging?

2007-04-08 Thread mraible

Andy,

Do you have an update on this?

Thanks,

Matt


Andrew Williams-5 wrote:
 
 I will try to put instructions on a website somewhere this week.
 
 Andy
 
 On 14 Mar 2007, at 16:15, mraible wrote:
 

 I agree that the logging output needs to be fixed.  In particular,  
 I'd love
 to see mvn -Dsurefire.useFile=false become the default so users  
 can see
 test failures in the console instead of digging through text  
 files.  Most
 folks that use Maven are coming from Ant, where they're used to this
 behavior.

 In the meantime, would you mind sending me your impl so I can try  
 it out?

 Thanks,

 Matt


 Andrew Williams-5 wrote:

 I have some colour logging that works, but it is not a core part of
 maven yet.
 It was suggested that we need to work on fixing up the logging output
 before we jazz it up.

 The impl I have supports both ANSI and HTML right now.

 Andy

 On 13 Mar 2007, at 15:26, mraible wrote:


 Bump... has the status of this changed?  When I google for Maven
 color
 logging, it seems like it might exist, but I can't tell for sure.

 Thanks,

 Matt


 Matt Raible-3 wrote:

 Is it possible to configure Maven so it spits out color logging
 like Ant
 does?

 FWIW:

 export ANT_ARGS='-logger
 org.apache.tools.ant.listener.AnsiColorLogger'

 gives pretty color logging in Ant.

 Thanks,

 Matt

 --- 
 --
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




 -- 
 View this message in context: http://www.nabble.com/Color-logging--
 tf2208089s177.html#a9456866
 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/Color-logging-- 
 tf2208089s177.html#a9477884
 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/Color-logging--tf2208089s177.html#a9894199
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Is it possible to suppress the Velocity warnings when using archetype:create?

2007-04-04 Thread mraible

Is it possible to suppress the Velocity warnings when using archetype:create? 
When users (most of them new to Maven) create a new project with AppFuse,
they often think it fails.  I can see why - here's the output when creating
a new project:

Listening for transport dt_socket at address: 5005
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'archetype'.
[INFO]

[INFO] Building Maven Default Project
[INFO]task-segment: [archetype:create] (aggregator-style)
[INFO]

[INFO] Setting property: classpath.resource.loader.class =
'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on = 'false'.
[INFO] Setting property: resource.loader = 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound = 'false'.
[INFO] ** 
[INFO] Starting Jakarta Velocity v1.4
[INFO] RuntimeInstance initializing.
[INFO] Default Properties File:
org\apache\velocity\runtime\defaults\velocity.properties
[INFO] Default ResourceManager initializing. (class
org.apache.velocity.runtime.resource.ResourceManagerImpl)
[INFO] Resource Loader Instantiated:
org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
[INFO] ClasspathResourceLoader : initialization starting.
[INFO] ClasspathResourceLoader : initialization complete.
[INFO] ResourceCache : initialized. (class
org.apache.velocity.runtime.resource.ResourceCacheImpl)
[INFO] Default ResourceManager initialization complete.
[INFO] Loaded System Directive:
org.apache.velocity.runtime.directive.Literal
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse
[INFO] Loaded System Directive:
org.apache.velocity.runtime.directive.Include
[INFO] Loaded System Directive:
org.apache.velocity.runtime.directive.Foreach
[INFO] Created: 20 parsers.
[INFO] Velocimacro : initialization starting.
[INFO] Velocimacro : adding VMs from VM library template :
VM_global_library.vm
[ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in
any resource loader.
[INFO] Velocimacro : error using  VM library template VM_global_library.vm :
org.apache.velocity.exception.ResourceNotFoundException: Unable to find
resource 'VM_global_library.vm'
[INFO] Velocimacro :  VM library template macro registration complete.
[INFO] Velocimacro : allowInline = true : VMs can be defined inline in
templates
[INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may
NOT replace previous VM definitions
[INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be 
global in scope if allowed.
[INFO] Velocimacro : initialization complete.
[INFO] Velocity successfully started.
[INFO] [archetype:create]
[INFO] Defaulting package to group ID: org.appfuse.tutorial
[INFO] We are using command line specified remote repositories:
http://static.appfuse.org/repository
[INFO]

[INFO] Using following parameters for creating Archetype:
appfuse-basic-jsf:2.0-m4
[INFO]

[INFO] Parameter: groupId, Value: org.appfuse.tutorial
[INFO] Parameter: packageName, Value: org.appfuse.tutorial
[INFO] Parameter: basedir, Value: c:\Source
[INFO] Parameter: package, Value: org.appfuse.tutorial
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: artifactId, Value: myproject
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 50,column 26] :
${appfuse.version} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 102,column 31] :
${maven.test.skip} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 115,column 34] :
${jdbc.groupId} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 116,column 37] :
${jdbc.artifactId} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 117,column 34] :
${jdbc.version} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 126,column 42] :
${dbunit.dataTypeFactoryName} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 127,column 29] :
${jdbc.driverClassName} is not a 

Is it possible to suppress the Velocity warnings when using archetype:create?

2007-04-04 Thread mraible

Is it possible to suppress the Velocity warnings when using archetype:create? 
When users (most of them new to Maven) create a new project with AppFuse,
they often think it fails.  I can see why - here's the output when creating
a new project:

Listening for transport dt_socket at address: 5005
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'archetype'.
[INFO]

[INFO] Building Maven Default Project
[INFO]task-segment: [archetype:create] (aggregator-style)
[INFO]

[INFO] Setting property: classpath.resource.loader.class =
'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on = 'false'.
[INFO] Setting property: resource.loader = 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound = 'false'.
[INFO] ** 
[INFO] Starting Jakarta Velocity v1.4
[INFO] RuntimeInstance initializing.
[INFO] Default Properties File:
org\apache\velocity\runtime\defaults\velocity.properties
[INFO] Default ResourceManager initializing. (class
org.apache.velocity.runtime.resource.ResourceManagerImpl)
[INFO] Resource Loader Instantiated:
org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
[INFO] ClasspathResourceLoader : initialization starting.
[INFO] ClasspathResourceLoader : initialization complete.
[INFO] ResourceCache : initialized. (class
org.apache.velocity.runtime.resource.ResourceCacheImpl)
[INFO] Default ResourceManager initialization complete.
[INFO] Loaded System Directive:
org.apache.velocity.runtime.directive.Literal
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse
[INFO] Loaded System Directive:
org.apache.velocity.runtime.directive.Include
[INFO] Loaded System Directive:
org.apache.velocity.runtime.directive.Foreach
[INFO] Created: 20 parsers.
[INFO] Velocimacro : initialization starting.
[INFO] Velocimacro : adding VMs from VM library template :
VM_global_library.vm
[ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in
any resource loader.
[INFO] Velocimacro : error using  VM library template VM_global_library.vm :
org.apache.velocity.exception.ResourceNotFoundException: Unable to find
resource 'VM_global_library.vm'
[INFO] Velocimacro :  VM library template macro registration complete.
[INFO] Velocimacro : allowInline = true : VMs can be defined inline in
templates
[INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may
NOT replace previous VM definitions
[INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be 
global in scope if allowed.
[INFO] Velocimacro : initialization complete.
[INFO] Velocity successfully started.
[INFO] [archetype:create]
[INFO] Defaulting package to group ID: org.appfuse.tutorial
[INFO] We are using command line specified remote repositories:
http://static.appfuse.org/repository
[INFO]

[INFO] Using following parameters for creating Archetype:
appfuse-basic-jsf:2.0-m4
[INFO]

[INFO] Parameter: groupId, Value: org.appfuse.tutorial
[INFO] Parameter: packageName, Value: org.appfuse.tutorial
[INFO] Parameter: basedir, Value: c:\Source
[INFO] Parameter: package, Value: org.appfuse.tutorial
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: artifactId, Value: myproject
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 50,column 26] :
${appfuse.version} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 102,column 31] :
${maven.test.skip} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 115,column 34] :
${jdbc.groupId} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 116,column 37] :
${jdbc.artifactId} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 117,column 34] :
${jdbc.version} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 126,column 42] :
${dbunit.dataTypeFactoryName} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = archetype-resources/pom.xml [line 127,column 29] :
${jdbc.driverClassName} is not a 

Re: Using the assembly plugin to package up WARs and ZIPs

2007-03-29 Thread mraible



John Casey wrote:
 
 On 3/28/07, mraible [EMAIL PROTECTED] wrote:


 Are you saying I should have two assemblies; one that creates a zip from
 the
 static content and one that takes the output from that and bundles it
 with
 the WARs?

 That sounds reasonable.  I'm still wondering how I can attach the zip to
 a
 WAR when it's installed with another WAR.  Is that possible?  It doesn't
 seem like it.
 
 
 
 Sorry, I'm not sure I follow; what do you  mean by installed with?
 
 -j
 

I mean the assembly is created and installed in my local repo (using the
following config):

plugin
artifactIdmaven-assembly-plugin/artifactId
version2.1/version
configuration
descriptors
   
descriptorsrc/assembly/static-content.xml/descriptor
/descriptors
/configuration
executions
execution
idmake-assembly/id
phaseverify/phase
goals
goalattached/goal
/goals
/execution
/executions
/plugin

According to 

http://maven.apache.org/plugins/maven-assembly-plugin/examples/single/including-and-excluding-artifacts.html

it looks like I might be able to use this artifact in another WAR using:

dependency
groupId${pom.groupId}/groupId
artifactIdwar1/artifactId
version${pom.version}/version
classifierstatic-content/classifier
typezip/type
/dependency

Can assemblies in the repo be treated as dependencies?

Thanks,

Matt

-- 
View this message in context: 
http://www.nabble.com/Using-the-assembly-plugin-to-package-up-WARs-and-ZIPs-tf3477317s177.html#a9728215
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: Using the assembly plugin to package up WARs and ZIPs

2007-03-29 Thread mraible

So how do I get the dependency unzipped and included in the WAR that depends
on this?  I'd like to do this in a profile so it happens when I pass in
-PincludeImages (and not by default).

Matt


John Casey wrote:
 
 sure, they can be treated as dependencies. You have the syntax down, too.
 
 -j
 
 On 3/29/07, mraible [EMAIL PROTECTED] wrote:




 John Casey wrote:
 
  On 3/28/07, mraible [EMAIL PROTECTED] wrote:
 
 
  Are you saying I should have two assemblies; one that creates a zip
 from
  the
  static content and one that takes the output from that and bundles it
  with
  the WARs?
 
  That sounds reasonable.  I'm still wondering how I can attach the zip
 to
  a
  WAR when it's installed with another WAR.  Is that possible?  It
 doesn't
  seem like it.
 
 
 
  Sorry, I'm not sure I follow; what do you  mean by installed with?
 
  -j
 

 I mean the assembly is created and installed in my local repo (using the
 following config):

 plugin
 artifactIdmaven-assembly-plugin/artifactId
 version2.1/version
 configuration
 descriptors

 descriptorsrc/assembly/static-content.xml/descriptor
 /descriptors
 /configuration
 executions
 execution
 idmake-assembly/id
 phaseverify/phase
 goals
 goalattached/goal
 /goals
 /execution
 /executions
 /plugin

 According to


 http://maven.apache.org/plugins/maven-assembly-plugin/examples/single/including-and-excluding-artifacts.html

 it looks like I might be able to use this artifact in another WAR using:

 dependency
 groupId${pom.groupId}/groupId
 artifactIdwar1/artifactId
 version${pom.version}/version
 classifierstatic-content/classifier
 typezip/type
 /dependency

 Can assemblies in the repo be treated as dependencies?

 Thanks,

 Matt

 --
 View this message in context:
 http://www.nabble.com/Using-the-assembly-plugin-to-package-up-WARs-and-ZIPs-tf3477317s177.html#a9728215
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 

-- 
View this message in context: 
http://www.nabble.com/Using-the-assembly-plugin-to-package-up-WARs-and-ZIPs-tf3477317s177.html#a9735698
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: Using the assembly plugin to package up WARs and ZIPs

2007-03-28 Thread mraible

I've managed to get my WARs and ZIPs into the same release ZIP using the
following assembly descriptor.  However, I'd like to combine the two zips
into a single zip.  Is this possible with the maven-assembly-plugin or do I
need to resort to Ant for that?

assembly
idbin/id
formats
formatzip/format
/formats
moduleSets
moduleSet
includes
includecom.foo:foo-core:jar/include
includecom.foo:foo-war1:war/include
includecom.foo:foo-war2:war/include
/includes
binaries
unpackfalse/unpack
/binaries
/moduleSet
/moduleSets
fileSets
fileSet
directorysites/war1/target/directory
outputDirectory/outputDirectory
includes
include*.zip/include
/includes
/fileSet
fileSet
directorysites/war2/target/directory
outputDirectory/outputDirectory
includes
include*.zip/include
/includes
/fileSet
/fileSets
/assembly

If I do need to resort to Ant, is it a good idea to configure this assembly
in my root pom.xml?  While this seems the simplest way, creating an
assembly module seems like it might give me the ability to create my
release zip after everything else has been executed.  With the root pom.xml,
I believe install happens before any modules are built, so it'd be tough to
hook into the lifecycle to build the release zip.

Thanks,

Matt


mraible wrote:
 
 I'm trying to use the assembly plugin to package up WARs from a bunch of
 sub-projects.  My goal is to get a target/release.zip after running mvn
 package from the top-level directory.
 
 I have this working when I run mvn package assembly:assembly, but I'd
 like to make it work for mvn package of my root pom.xml.  Is it possible
 to use an execution to make this work?
 
 2ndly, I'm using the assembly plugin to zip up static content in my WARs
 so it can be deployed to an external webserver.  I have it working
 (details at
 http://www.nabble.com/Re%3A-Packaging-up-images-p9699901s177.html), but 1)
 I can't get one WAR to depend on these zipped artifacts and 2) I can't
 figure out how to get the top-level assembly to include the zip files.
 
 Currently, there are zip files created by an assembly in each WAR project. 
 In an ideal world, I could combine these into one static-content.zip in
 the zip that's produced by the root assembly.  Here's the bin.xml I'm
 using for my top-level assembly:
 
 assembly
   idbin/id
   formats
 formatzip/format
   /formats
   includeBaseDirectoryfalse/includeBaseDirectory
   moduleSets
 moduleSet
   includes
 includecom.company:webapp1:war/include
 includecom.company:webapp2:war/include
   /includes
   binaries
 outputDirectory/outputDirectory
 unpackfalse/unpack
   /binaries
 /moduleSet
   /moduleSets
 /assembly
 
 Thanks,
 
 Matt
 

-- 
View this message in context: 
http://www.nabble.com/Using-the-assembly-plugin-to-package-up-WARs-and-ZIPs-tf3477317s177.html#a9718419
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: Using the assembly plugin to package up WARs and ZIPs

2007-03-28 Thread mraible

Are you saying I should have two assemblies; one that creates a zip from the
static content and one that takes the output from that and bundles it with
the WARs?

That sounds reasonable.  I'm still wondering how I can attach the zip to a
WAR when it's installed with another WAR.  Is that possible?  It doesn't
seem like it.

Matt


John Casey wrote:
 
 Rather than creating static zips in each module directory, why not use a
 fileSet to refer to the module subdirs that contain the static content,
 and
 create the single static zip from the top level? Then, if you want that
 static content in a zip that's in addition to the war and jar files in
 your
 distro zip, you *might* be able to put the static assembly fragments in a
 separate assembly descriptor, bound to the lifecycle in an earlier phase
 (in
 a separate execution/). Then, simply refer to the output of that static
 assembly when you create the other one that contains the wars, etc.
 
 Does that make sense?
 
 -john
 
 On 3/28/07, mraible [EMAIL PROTECTED] wrote:


 I've managed to get my WARs and ZIPs into the same release ZIP using the
 following assembly descriptor.  However, I'd like to combine the two zips
 into a single zip.  Is this possible with the maven-assembly-plugin or do
 I
 need to resort to Ant for that?

 assembly
 idbin/id
 formats
 formatzip/format
 /formats
 moduleSets
 moduleSet
 includes
 includecom.foo:foo-core:jar/include
 includecom.foo:foo-war1:war/include
 includecom.foo:foo-war2:war/include
 /includes
 binaries
 unpackfalse/unpack
 /binaries
 /moduleSet
 /moduleSets
 fileSets
 fileSet
 directorysites/war1/target/directory
 outputDirectory/outputDirectory
 includes
 include*.zip/include
 /includes
 /fileSet
 fileSet
 directorysites/war2/target/directory
 outputDirectory/outputDirectory
 includes
 include*.zip/include
 /includes
 /fileSet
 /fileSets
 /assembly

 If I do need to resort to Ant, is it a good idea to configure this
 assembly
 in my root pom.xml?  While this seems the simplest way, creating an
 assembly module seems like it might give me the ability to create my
 release zip after everything else has been executed.  With the root
 pom.xml,
 I believe install happens before any modules are built, so it'd be tough
 to
 hook into the lifecycle to build the release zip.

 Thanks,

 Matt


 mraible wrote:
 
  I'm trying to use the assembly plugin to package up WARs from a bunch
 of
  sub-projects.  My goal is to get a target/release.zip after running
 mvn
  package from the top-level directory.
 
  I have this working when I run mvn package assembly:assembly, but I'd
  like to make it work for mvn package of my root pom.xml.  Is it
 possible
  to use an execution to make this work?
 
  2ndly, I'm using the assembly plugin to zip up static content in my
 WARs
  so it can be deployed to an external webserver.  I have it working
  (details at
  http://www.nabble.com/Re%3A-Packaging-up-images-p9699901s177.html), but
 1)
  I can't get one WAR to depend on these zipped artifacts and 2) I can't
  figure out how to get the top-level assembly to include the zip files.
 
  Currently, there are zip files created by an assembly in each WAR
 project.
  In an ideal world, I could combine these into one static-content.zip in
  the zip that's produced by the root assembly.  Here's the bin.xml I'm
  using for my top-level assembly:
 
  assembly
idbin/id
formats
  formatzip/format
/formats
includeBaseDirectoryfalse/includeBaseDirectory
moduleSets
  moduleSet
includes
  includecom.company:webapp1:war/include
  includecom.company:webapp2:war/include
/includes
binaries
  outputDirectory/outputDirectory
  unpackfalse/unpack
/binaries
  /moduleSet
/moduleSets
  /assembly
 
  Thanks,
 
  Matt
 

 --
 View this message in context:
 http://www.nabble.com/Using-the-assembly-plugin-to-package-up-WARs-and-ZIPs-tf3477317s177.html#a9718419
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 

-- 
View this message in context: 
http://www.nabble.com/Using-the-assembly-plugin-to-package-up-WARs-and-ZIPs-tf3477317s177.html#a9721785
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Powered by M2 - is it possible to add to the list?

2007-03-28 Thread mraible

Is it possible to add Equinox (used in Maestro) and AppFuse to the Powered
by M2 list?

http://maven.apache.org/powered-by-m2.html

Thanks!

Matt
-- 
View this message in context: 
http://www.nabble.com/Powered-by-M2---is-it-possible-to-add-to-the-list--tf3482768s177.html#a9721921
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: Powered by M2 - is it possible to add to the list?

2007-03-28 Thread mraible

Using http://equinox.dev.java.net is probably best for now.  If you'd like,
you can use AppFuse Light for the name.  We're changing the name because
of the conflict with the Eclipse project.

Matt


John Casey wrote:
 
 Is it the same thing to reference the Equinox page on dev.java.net, or is
 there a Mergere URL we can add? Does anyone know?
 
 BTW, I've added http://appfuse.org to the list.
 
 -john
 
 On 3/28/07, mraible [EMAIL PROTECTED] wrote:


 Is it possible to add Equinox (used in Maestro) and AppFuse to the
 Powered
 by M2 list?

 http://maven.apache.org/powered-by-m2.html

 Thanks!

 Matt
 --
 View this message in context:
 http://www.nabble.com/Powered-by-M2---is-it-possible-to-add-to-the-list--tf3482768s177.html#a9721921
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 

-- 
View this message in context: 
http://www.nabble.com/Powered-by-M2---is-it-possible-to-add-to-the-list--tf3482768s177.html#a9725803
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: Packaging up images

2007-03-27 Thread mraible

Here's what I came up with using the maven-antrun-plugin.  How would I do
this with the assembly plugin?

profile
idzipContent/id
build
plugins
plugin
artifactIdmaven-antrun-plugin/artifactId
executions
execution
idzipContent/id
phasepackage/phase
configuration
tasks
zip
zipfile=${project.build.directory}/static-content.zip
zipfileset
dir=src/main/webapp/content
patternset
id=srcfiles
include name=**/
exclude
name=*.psd/
/patternset
/zipfileset
/zip
/tasks
/configuration
goals
goalrun/goal
/goals
/execution
/executions
/plugin
/plugins
/build
/profile

Thanks,

Matt

dan tran wrote:
 
 zip and deploy? if so, use assembly:attached
 
 
 On 3/27/07, mraible [EMAIL PROTECTED] wrote:


 I'm currently migrating an ASP-based site to Maven and Subversion. The
 previous site didn't use any source control, so the images directory is
 quite large (1 GB).  I can exclude/include this directory easily enough
 with
 the maven-war-plugin and profiles, but I'm wondering what's the best way
 to
 zip it up as part of the build process. Should I use the
 maven-antrun-plugin, or is there a better way?

 Thanks,

 Matt
 --
 View this message in context:
 http://www.nabble.com/Packaging-up-images-tf3474277s177.html#a9696408
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 

-- 
View this message in context: 
http://www.nabble.com/Packaging-up-images-tf3474277s177.html#a9696856
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Packaging up images

2007-03-27 Thread mraible

I'm currently migrating an ASP-based site to Maven and Subversion. The
previous site didn't use any source control, so the images directory is
quite large (1 GB).  I can exclude/include this directory easily enough with
the maven-war-plugin and profiles, but I'm wondering what's the best way to
zip it up as part of the build process. Should I use the
maven-antrun-plugin, or is there a better way?

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Packaging-up-images-tf3474277s177.html#a9696408
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: Packaging up images

2007-03-27 Thread mraible

OK, I got it working by adding the following profile:

profile
idstatic-content/id
build
plugins
plugin
artifactIdmaven-assembly-plugin/artifactId
configuration
descriptors
   
descriptorsrc/assembly/static-content.xml/descriptor
/descriptors
/configuration
executions
execution
idmake-assembly/id
phasepackage/phase
goals
goalattached/goal
/goals
/execution
/executions
/plugin
/plugins
/build
/profile

In src/assembly/static-content.xml, I have:

assembly
idstatic-content/id
formats
formatzip/format
/formats
fileSets
fileSet
directorysrc/main/webapp/content/directory
excludes
exclude**/*.psd/exclude
/excludes
/fileSet
/fileSets
/assembly

Everything seems to work fine.  However, I'd like to include this static
content in another webapp that depends on this WAR.  I tried adding the
following, but it doesn't include this content in the final war when running
mvn package.

dependency
groupId${pom.groupId}/groupId
artifactIdmy-webapp/artifactId
version${pom.version}/version
classifierstatic-content/classifier
typezip/type
/dependency

AFAICT, my classifier and type is correct.

Thanks,

Matt


dan tran wrote:
 
 You need to create an assemlby file and configure it to zip up your
 directory.  There is plenty examples at assembly-plugin's site.
 
 -D
 
 
 On 3/27/07, mraible [EMAIL PROTECTED] wrote:


 Here's what I came up with using the maven-antrun-plugin.  How would I do
 this with the assembly plugin?

profile
idzipContent/id
build
plugins
plugin
artifactIdmaven-antrun-plugin/artifactId
executions
execution
idzipContent/id
phasepackage/phase
configuration
tasks
zip
 zipfile=${project.build.directory}/static-content.zip
zipfileset
 dir=src/main/webapp/content
patternset
 id=srcfiles
include
 name=**/
exclude
 name=*.psd/
/patternset
/zipfileset
/zip
/tasks
/configuration
goals
goalrun/goal
/goals
/execution
/executions
/plugin
/plugins
/build
/profile

 Thanks,

 Matt

 dan tran wrote:
 
  zip and deploy? if so, use assembly:attached
 
 
  On 3/27/07, mraible [EMAIL PROTECTED] wrote:
 
 
  I'm currently migrating an ASP-based site to Maven and Subversion. The
  previous site didn't use any source control, so the images directory
 is
  quite large (1 GB).  I can exclude/include this directory easily
 enough
  with
  the maven-war-plugin and profiles, but I'm wondering what's the best
 way
  to
  zip it up as part of the build process. Should I use the
  maven-antrun-plugin, or is there a better way?
 
  Thanks,
 
  Matt
  --
  View this message in context:
  http://www.nabble.com/Packaging-up-images-tf3474277s177.html#a9696408
  Sent from the Maven - Users mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Packaging-up-images-tf3474277s177.html#a9696856
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 

-- 
View this message in context: 
http://www.nabble.com/Packaging-up-images-tf3474277s177.html#a9699901

Using the assembly plugin to package up WARs and ZIPs

2007-03-27 Thread mraible

I'm trying to use the assembly plugin to package up WARs from a bunch of
sub-projects.  My goal is to get a target/release.zip after running mvn
package from the top-level directory.

I have this working when I run mvn package assembly:assembly, but I'd like
to make it work for mvn package of my root pom.xml.  Is it possible to use
an execution to make this work?

2ndly, I'm using the assembly plugin to zip up static content in my WARs so
it can be deployed to an external webserver.  I have it working (details at
http://www.nabble.com/Re%3A-Packaging-up-images-p9699901s177.html), but 1) I
can't get one WAR to depend on these zipped artifacts and 2) I can't figure
out how to get the top-level assembly to include the zip files.

Currently, there are zip files created by an assembly in each WAR project. 
In an ideal world, I could combine these into one static-content.zip in the
zip that's produced by the root assembly.  Here's the bin.xml I'm using for
my top-level assembly:

assembly
  idbin/id
  formats
formatzip/format
  /formats
  includeBaseDirectoryfalse/includeBaseDirectory
  moduleSets
moduleSet
  includes
includecom.company:webapp1:war/include
includecom.company:webapp2:war/include
  /includes
  binaries
outputDirectory/outputDirectory
unpackfalse/unpack
  /binaries
/moduleSet
  /moduleSets
/assembly

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Using-the-assembly-plugin-to-package-up-WARs-and-ZIPs-tf3477317s177.html#a9706416
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] Color logging?

2007-03-14 Thread mraible

I agree that the logging output needs to be fixed.  In particular, I'd love
to see mvn -Dsurefire.useFile=false become the default so users can see
test failures in the console instead of digging through text files.  Most
folks that use Maven are coming from Ant, where they're used to this
behavior.

In the meantime, would you mind sending me your impl so I can try it out?

Thanks,

Matt


Andrew Williams-5 wrote:
 
 I have some colour logging that works, but it is not a core part of  
 maven yet.
 It was suggested that we need to work on fixing up the logging output  
 before we jazz it up.
 
 The impl I have supports both ANSI and HTML right now.
 
 Andy
 
 On 13 Mar 2007, at 15:26, mraible wrote:
 

 Bump... has the status of this changed?  When I google for Maven  
 color
 logging, it seems like it might exist, but I can't tell for sure.

 Thanks,

 Matt


 Matt Raible-3 wrote:

 Is it possible to configure Maven so it spits out color logging  
 like Ant
 does?

 FWIW:

 export ANT_ARGS='-logger  
 org.apache.tools.ant.listener.AnsiColorLogger'

 gives pretty color logging in Ant.

 Thanks,

 Matt

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




 -- 
 View this message in context: http://www.nabble.com/Color-logging-- 
 tf2208089s177.html#a9456866
 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/Color-logging--tf2208089s177.html#a9477884
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: Overriding properties in a dependency's pom.xml

2007-03-14 Thread mraible

Bump.

I'd really, really like the ability to override the property of a dependency
in a project's pom.xml.  Can anyone answer if this is currently possible -
for example using the dependencyManagement feature?  If it's not possible,
is it possible to write a plugin to do this or is everything locked down in
Maven's core?

This feature is essential to the AppFuse project if we want to allow
multiple persistent frameworks for users.  Requiring folks to use a -D
parameter (or modifying MAVEN_OPTS) is quite unmaintainable.

Thanks,

Matt


mraible wrote:
 
 I've entered an enhancement request for this at:
 
 http://jira.codehaus.org/browse/MNG-2757
 
 Maven Developers: how hard would it be to allow property overriding?  It
 seems like a natural thing to want to do.
 
 Thanks,
 
 Matt
 
 
 Larry Meadors-2 wrote:
 
 On 1/4/07, mraible [EMAIL PROTECTED] wrote:
 Is Maven like Ant in that properties are immutable?  If so, can I hook
 into
 the lifecycle sooner and set this dao.framework property from the local
 pom.xml?
 
 I was thinking the same thing - it sure is acting like that is the case,
 no?
 
 Larry
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Overriding-properties-in-a-dependency%27s-pom.xml-tf2921218s177.html#a9484182
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] Color logging?

2007-03-13 Thread mraible

Bump... has the status of this changed?  When I google for Maven color
logging, it seems like it might exist, but I can't tell for sure.

Thanks,

Matt


Matt Raible-3 wrote:
 
 Is it possible to configure Maven so it spits out color logging like Ant
 does?
 
 FWIW:
 
 export ANT_ARGS='-logger org.apache.tools.ant.listener.AnsiColorLogger'
 
 gives pretty color logging in Ant.
 
 Thanks,
 
 Matt
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Color-logging--tf2208089s177.html#a9456866
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] Is it possible to have application-specific properties in settings.xml?

2007-03-13 Thread mraible

I'm seeing some strange behavior with this.  I've added a profiles.xml in the
root of my project. Its contents are:

profiles
profile
idxp/id
activation
activeByDefaulttrue/activeByDefault
/activation
properties

jdbc.url![CDATA[jdbc:jtds:sqlserver://xpbox:1433/database]]/jdbc.url
/properties
/profile
/profiles

When I cd into core and run mvn test, the correct jdbc.url property is
put into my filtered properties file.  However, when I run mvn test from
the top-level directory, it uses the value from pom.xml.  

If I move the contents of profiles.xml to ~/.m2/settings.xml, everything
works fine, but I'm back to my same problem where this is a global property
override, and I'm only looking to override for this one project.

Any ideas why this happens?

Thanks,

Matt


mraible wrote:
 
 Thanks for the tip - I was able to use a profiles.xml file in my local
 project directory to get the behavior I wanted. Now I'm only overriding
 the property for a single project, and as long as I don't check it in to
 SVN, everyone else retains the default behavior from pom.xml.  Another
 thing I tried was to use file activation in settings.xml (because there
 are different files in the 2 Maven projects), but that didn't seem to
 work.  Here's what I used:
 
   activation
 file
 exists${basedir}/lib/install.sh/exists
 /file
 /activation
 
 Thanks for the help Wayne - you solved my problem.
 
 Matt
 
 
 Wayne Fay wrote:
 
 Have you considered using a profiles.xml file (checked into SCM) which
 contains settings specific to each person's environment? Then you
 would use -Pmrmac which would specify the SQL server on another box,
 while -Pmrxp would specify a local SQL server etc.
 
 This profiles.xml file would be available for everyone to read/write
 but they would be responsible to only edit their piece of the config.
 And you could have a generic config that is used for the common
 developer environment with generic data. I'm not sure if this would
 solve all your problems, though, as it would require you to copy this
 profile.xml file to multiple locations in your SCM and potentially
 keep them all in-sync.
 
 Wayne
 
 On 3/12/07, mraible [EMAIL PROTECTED] wrote:

 I've read this page quite a few times and the answer still doesn't jump
 out
 at me.  If I have two Maven projects that are completely unrelated, but
 they
 use the same property name - how do I override this property's value for
 one
 project, but not for the other?

 In other words, I want jdbc.url to have localhost for most projects
 on
 my system.  And in the SVN version of this other project, I have
 localhost.  However, because I need to connect to a Windows/SQL Server
 box
 for this one project, I need to change jdbc.url to have xpboxname
 instead of localhost.  If I use any sort of system properties, that
 applies
 to all projects.  If I modify the pom.xml, that changes things for
 everyone
 (which doesn't need to happen because I'm on the only one on a Mac).

 I'm all for a workaround, but the only two options I see right now are:

 1. Comment out the activeByDefault setting in pom.xml when I want to
 work
 on other projects (not the one that needs XP).
 2. Change /etc/hosts so localhost resolves to my XP box.

 Thanks for any advice,

 Matt


 Wayne Fay wrote:
 
  It might be useful to review this documentation to make sure you're
  doing it the one true way. ;-)
 
 
 http://maven.apache.org/guides/introduction/introduction-to-profiles.html
 
  Wayne
 
  On 3/12/07, mraible [EMAIL PROTECTED] wrote:
 
  Don't worry - I am doing things The Maven Way with properties in
 the
  root
  pom.xml.  However, for this particular application, I need to
 override a
  property in settings.xml (I'm on a Mac and need to connect to a SQL
  Server
  instance not on localhost). The problem is, I have another
 application
  that uses the same property name (this can't be that rare, can it?).
 So
  when
  I override it in settings.xml, it overrides all my projects that use
 that
  property name.
 
  Matt
 
 
 
  Wayne Fay wrote:
  
   You are really not encouraged to use application-specific
 properties
   in a settings.xml file, as your builds will not be portable.
 Instead,
   these kinds of properties should be placed directly in the pom
 (parent
   or children as appropriate) of the project you are working on.
  
   I use a similar process for our Ant builds, with project-specific
   properties in my user home loaded first, then all-projects
 properties,
   etc. I'm pretty sure this is a common pattern across Ant users.
  
   Wayne
  
   On 3/12/07, mraible [EMAIL PROTECTED] wrote:
  
   Since there's been no answers to this question, I'll assume the
 answer
  is
   No, it's not possible to use settings.xml to have
  application-specific
   properties.
  
   Matt
  
  
   mraible wrote:
   
I have a number of properties

Re: [m2] Is it possible to have application-specific properties in settings.xml?

2007-03-13 Thread mraible

I'll make sure and keep the discussion on this list after trying your test
project.

Thanks,

Matt


Wayne Fay wrote:
 
 I have no idea... I made a little test project to see what happens and
 it seems to work like I said, and not like you're experiencing, so I
 guess something else is up on your side (??).
 
 I will go ahead and send the zip directly to you Matt as I know
 attachments generally don't get passed through this mailing list...
 But please reply to this email (on list) so we can keep the
 conversation public, if you don't mind.
 
 Wayne
 
 On 3/13/07, mraible [EMAIL PROTECTED] wrote:

 I'm seeing some strange behavior with this.  I've added a profiles.xml in
 the
 root of my project. Its contents are:

 profiles
 profile
 idxp/id
 activation
 activeByDefaulttrue/activeByDefault
 /activation
 properties

 jdbc.url![CDATA[jdbc:jtds:sqlserver://xpbox:1433/database]]/jdbc.url
 /properties
 /profile
 /profiles

 When I cd into core and run mvn test, the correct jdbc.url property
 is
 put into my filtered properties file.  However, when I run mvn test
 from
 the top-level directory, it uses the value from pom.xml.

 If I move the contents of profiles.xml to ~/.m2/settings.xml, everything
 works fine, but I'm back to my same problem where this is a global
 property
 override, and I'm only looking to override for this one project.

 Any ideas why this happens?

 Thanks,

 Matt


 mraible wrote:
 
  Thanks for the tip - I was able to use a profiles.xml file in my local
  project directory to get the behavior I wanted. Now I'm only overriding
  the property for a single project, and as long as I don't check it in
 to
  SVN, everyone else retains the default behavior from pom.xml.  Another
  thing I tried was to use file activation in settings.xml (because
 there
  are different files in the 2 Maven projects), but that didn't seem to
  work.  Here's what I used:
 
activation
  file
  exists${basedir}/lib/install.sh/exists
  /file
  /activation
 
  Thanks for the help Wayne - you solved my problem.
 
  Matt
 
 
  Wayne Fay wrote:
 
  Have you considered using a profiles.xml file (checked into SCM) which
  contains settings specific to each person's environment? Then you
  would use -Pmrmac which would specify the SQL server on another box,
  while -Pmrxp would specify a local SQL server etc.
 
  This profiles.xml file would be available for everyone to read/write
  but they would be responsible to only edit their piece of the config.
  And you could have a generic config that is used for the common
  developer environment with generic data. I'm not sure if this would
  solve all your problems, though, as it would require you to copy this
  profile.xml file to multiple locations in your SCM and potentially
  keep them all in-sync.
 
  Wayne
 
  On 3/12/07, mraible [EMAIL PROTECTED] wrote:
 
  I've read this page quite a few times and the answer still doesn't
 jump
  out
  at me.  If I have two Maven projects that are completely unrelated,
 but
  they
  use the same property name - how do I override this property's value
 for
  one
  project, but not for the other?
 
  In other words, I want jdbc.url to have localhost for most
 projects
  on
  my system.  And in the SVN version of this other project, I have
  localhost.  However, because I need to connect to a Windows/SQL
 Server
  box
  for this one project, I need to change jdbc.url to have xpboxname
  instead of localhost.  If I use any sort of system properties, that
  applies
  to all projects.  If I modify the pom.xml, that changes things for
  everyone
  (which doesn't need to happen because I'm on the only one on a Mac).
 
  I'm all for a workaround, but the only two options I see right now
 are:
 
  1. Comment out the activeByDefault setting in pom.xml when I want
 to
  work
  on other projects (not the one that needs XP).
  2. Change /etc/hosts so localhost resolves to my XP box.
 
  Thanks for any advice,
 
  Matt
 
 
  Wayne Fay wrote:
  
   It might be useful to review this documentation to make sure you're
   doing it the one true way. ;-)
  
  
 
 http://maven.apache.org/guides/introduction/introduction-to-profiles.html
  
   Wayne
  
   On 3/12/07, mraible [EMAIL PROTECTED] wrote:
  
   Don't worry - I am doing things The Maven Way with properties in
  the
   root
   pom.xml.  However, for this particular application, I need to
  override a
   property in settings.xml (I'm on a Mac and need to connect to a
 SQL
   Server
   instance not on localhost). The problem is, I have another
  application
   that uses the same property name (this can't be that rare, can
 it?).
  So
   when
   I override it in settings.xml, it overrides all my projects that
 use
  that
   property name.
  
   Matt
  
  
  
   Wayne Fay wrote:
   
You are really not encouraged to use application-specific
  properties

Re: [m2] Is it possible to have application-specific properties in settings.xml?

2007-03-13 Thread mraible

Thanks for sending me a sample project Wayne.  You are correct - it works
fine for your project.  However, I've stared at your project and mine for
the last 15 minutes and I still can't figure out what's different.  One
thing that's different is I'm filtering testResources rather than
resources, but I doubt that's it.  Also, I don't have filtering turned on
in my root pom.xml, but rather in my core module.  I tried moving things in
yours and it still works.  Doh!  

I tried running mvn help:active-profiles on both projects. Mine has the
same results as yours.

Now that I'm writing this, one thing comes to mind that could be the
problem:

In my root pom.xml, I have:

properties
jdbc.urllocalhost.for.mysql/jdbc.url
/properties

profiles
   profile
  idsqlserver/id
  activationactiveByDefaulttrue/activeByDefault/activation
  properties
  jdbc.urllocalhost.for.sqlserver/jdbc.url
  /properties
  /profile
/profiles

So it's possible that my sqlserver profile is overriding my profiles.xml. 
Is there any way to order these or is it better to move my default
properties into a profile for mysql?

Thanks,

Matt


Wayne Fay wrote:
 
 I have no idea... I made a little test project to see what happens and
 it seems to work like I said, and not like you're experiencing, so I
 guess something else is up on your side (??).
 
 I will go ahead and send the zip directly to you Matt as I know
 attachments generally don't get passed through this mailing list...
 But please reply to this email (on list) so we can keep the
 conversation public, if you don't mind.
 
 Wayne
 
 On 3/13/07, mraible [EMAIL PROTECTED] wrote:

 I'm seeing some strange behavior with this.  I've added a profiles.xml in
 the
 root of my project. Its contents are:

 profiles
 profile
 idxp/id
 activation
 activeByDefaulttrue/activeByDefault
 /activation
 properties

 jdbc.url![CDATA[jdbc:jtds:sqlserver://xpbox:1433/database]]/jdbc.url
 /properties
 /profile
 /profiles

 When I cd into core and run mvn test, the correct jdbc.url property
 is
 put into my filtered properties file.  However, when I run mvn test
 from
 the top-level directory, it uses the value from pom.xml.

 If I move the contents of profiles.xml to ~/.m2/settings.xml, everything
 works fine, but I'm back to my same problem where this is a global
 property
 override, and I'm only looking to override for this one project.

 Any ideas why this happens?

 Thanks,

 Matt


 mraible wrote:
 
  Thanks for the tip - I was able to use a profiles.xml file in my local
  project directory to get the behavior I wanted. Now I'm only overriding
  the property for a single project, and as long as I don't check it in
 to
  SVN, everyone else retains the default behavior from pom.xml.  Another
  thing I tried was to use file activation in settings.xml (because
 there
  are different files in the 2 Maven projects), but that didn't seem to
  work.  Here's what I used:
 
activation
  file
  exists${basedir}/lib/install.sh/exists
  /file
  /activation
 
  Thanks for the help Wayne - you solved my problem.
 
  Matt
 
 
  Wayne Fay wrote:
 
  Have you considered using a profiles.xml file (checked into SCM) which
  contains settings specific to each person's environment? Then you
  would use -Pmrmac which would specify the SQL server on another box,
  while -Pmrxp would specify a local SQL server etc.
 
  This profiles.xml file would be available for everyone to read/write
  but they would be responsible to only edit their piece of the config.
  And you could have a generic config that is used for the common
  developer environment with generic data. I'm not sure if this would
  solve all your problems, though, as it would require you to copy this
  profile.xml file to multiple locations in your SCM and potentially
  keep them all in-sync.
 
  Wayne
 
  On 3/12/07, mraible [EMAIL PROTECTED] wrote:
 
  I've read this page quite a few times and the answer still doesn't
 jump
  out
  at me.  If I have two Maven projects that are completely unrelated,
 but
  they
  use the same property name - how do I override this property's value
 for
  one
  project, but not for the other?
 
  In other words, I want jdbc.url to have localhost for most
 projects
  on
  my system.  And in the SVN version of this other project, I have
  localhost.  However, because I need to connect to a Windows/SQL
 Server
  box
  for this one project, I need to change jdbc.url to have xpboxname
  instead of localhost.  If I use any sort of system properties, that
  applies
  to all projects.  If I modify the pom.xml, that changes things for
  everyone
  (which doesn't need to happen because I'm on the only one on a Mac).
 
  I'm all for a workaround, but the only two options I see right now
 are:
 
  1. Comment out the activeByDefault setting in pom.xml when I want
 to
  work
  on other

Re: [m2] Is it possible to have application-specific properties in settings.xml?

2007-03-12 Thread mraible

Since there's been no answers to this question, I'll assume the answer is
No, it's not possible to use settings.xml to have application-specific
properties.

Matt


mraible wrote:
 
 I have a number of properties for database settings in my root pom.xml:
 
 !-- Database settings --

 dbunit.dataTypeFactoryNameorg.dbunit.dataset.datatype.DefaultDataTypeFactory/dbunit.dataTypeFactoryName
 dbunit.operation.typeCLEAN_INSERT/dbunit.operation.type

 hibernate.dialectorg.hibernate.dialect.MySQLInnoDBDialect/hibernate.dialect
 jdbc.groupIdmysql/jdbc.groupId
 jdbc.artifactIdmysql-connector-java/jdbc.artifactId
 jdbc.version5.0.3/jdbc.version
 jdbc.driverClassNamecom.mysql.jdbc.Driver/jdbc.driverClassName

 jdbc.url![CDATA[jdbc:mysql://localhost/tutorial?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url
 jdbc.usernameroot/jdbc.username
 jdbc.password/jdbc.password
 
 This works great when I have a single project.  However, I've started to
 develop two applications with this setup, and I need to locally override
 the jdbc.url for one of my projects.  Is it possible to do this on an
 application-specific basis w/o affecting both applications.  AFAIK,
 settings.xml doesn't have anything fancy like (does it?):
 
 activation
  property
  name${pom.artifactId}/name
  valueprojecttoactivatefor/value
  /property
 /activation
 
 With Ant, I was able to accomplish this using:
 
 !-- Load user overrides --
 property file=${user.home}/.${ant.project.name}-build.properties/
 property file=${user.home}/.build.properties/
 property file=build.properties/
 
 Thanks,
 
 Matt
 

-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-have-application-specific-properties-in-settings.xml--tf3363611s177.html#a9441555
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] Is it possible to have application-specific properties in settings.xml?

2007-03-12 Thread mraible

Don't worry - I am doing things The Maven Way with properties in the root
pom.xml.  However, for this particular application, I need to override a
property in settings.xml (I'm on a Mac and need to connect to a SQL Server
instance not on localhost). The problem is, I have another application
that uses the same property name (this can't be that rare, can it?). So when
I override it in settings.xml, it overrides all my projects that use that
property name.

Matt



Wayne Fay wrote:
 
 You are really not encouraged to use application-specific properties
 in a settings.xml file, as your builds will not be portable. Instead,
 these kinds of properties should be placed directly in the pom (parent
 or children as appropriate) of the project you are working on.
 
 I use a similar process for our Ant builds, with project-specific
 properties in my user home loaded first, then all-projects properties,
 etc. I'm pretty sure this is a common pattern across Ant users.
 
 Wayne
 
 On 3/12/07, mraible [EMAIL PROTECTED] wrote:

 Since there's been no answers to this question, I'll assume the answer is
 No, it's not possible to use settings.xml to have application-specific
 properties.

 Matt


 mraible wrote:
 
  I have a number of properties for database settings in my root pom.xml:
 
  !-- Database settings --
 
 
 dbunit.dataTypeFactoryNameorg.dbunit.dataset.datatype.DefaultDataTypeFactory/dbunit.dataTypeFactoryName
  dbunit.operation.typeCLEAN_INSERT/dbunit.operation.type
 
 
 hibernate.dialectorg.hibernate.dialect.MySQLInnoDBDialect/hibernate.dialect
  jdbc.groupIdmysql/jdbc.groupId
  jdbc.artifactIdmysql-connector-java/jdbc.artifactId
  jdbc.version5.0.3/jdbc.version
 
 jdbc.driverClassNamecom.mysql.jdbc.Driver/jdbc.driverClassName
 
 
 jdbc.url![CDATA[jdbc:mysql://localhost/tutorial?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url
  jdbc.usernameroot/jdbc.username
  jdbc.password/jdbc.password
 
  This works great when I have a single project.  However, I've started
 to
  develop two applications with this setup, and I need to locally
 override
  the jdbc.url for one of my projects.  Is it possible to do this on an
  application-specific basis w/o affecting both applications.  AFAIK,
  settings.xml doesn't have anything fancy like (does it?):
 
  activation
   property
   name${pom.artifactId}/name
   valueprojecttoactivatefor/value
   /property
  /activation
 
  With Ant, I was able to accomplish this using:
 
  !-- Load user overrides --
  property
 file=${user.home}/.${ant.project.name}-build.properties/
  property file=${user.home}/.build.properties/
  property file=build.properties/
 
  Thanks,
 
  Matt
 

 --
 View this message in context:
 http://www.nabble.com/Is-it-possible-to-have-application-specific-properties-in-settings.xml--tf3363611s177.html#a9441555
 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/Is-it-possible-to-have-application-specific-properties-in-settings.xml--tf3363611s177.html#a9444290
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] Is it possible to have application-specific properties in settings.xml?

2007-03-12 Thread mraible

I've read this page quite a few times and the answer still doesn't jump out
at me.  If I have two Maven projects that are completely unrelated, but they
use the same property name - how do I override this property's value for one
project, but not for the other?

In other words, I want jdbc.url to have localhost for most projects on
my system.  And in the SVN version of this other project, I have
localhost.  However, because I need to connect to a Windows/SQL Server box
for this one project, I need to change jdbc.url to have xpboxname
instead of localhost.  If I use any sort of system properties, that applies
to all projects.  If I modify the pom.xml, that changes things for everyone
(which doesn't need to happen because I'm on the only one on a Mac).

I'm all for a workaround, but the only two options I see right now are:

1. Comment out the activeByDefault setting in pom.xml when I want to work
on other projects (not the one that needs XP).
2. Change /etc/hosts so localhost resolves to my XP box.

Thanks for any advice,

Matt


Wayne Fay wrote:
 
 It might be useful to review this documentation to make sure you're
 doing it the one true way. ;-)
 
 http://maven.apache.org/guides/introduction/introduction-to-profiles.html
 
 Wayne
 
 On 3/12/07, mraible [EMAIL PROTECTED] wrote:

 Don't worry - I am doing things The Maven Way with properties in the
 root
 pom.xml.  However, for this particular application, I need to override a
 property in settings.xml (I'm on a Mac and need to connect to a SQL
 Server
 instance not on localhost). The problem is, I have another application
 that uses the same property name (this can't be that rare, can it?). So
 when
 I override it in settings.xml, it overrides all my projects that use that
 property name.

 Matt



 Wayne Fay wrote:
 
  You are really not encouraged to use application-specific properties
  in a settings.xml file, as your builds will not be portable. Instead,
  these kinds of properties should be placed directly in the pom (parent
  or children as appropriate) of the project you are working on.
 
  I use a similar process for our Ant builds, with project-specific
  properties in my user home loaded first, then all-projects properties,
  etc. I'm pretty sure this is a common pattern across Ant users.
 
  Wayne
 
  On 3/12/07, mraible [EMAIL PROTECTED] wrote:
 
  Since there's been no answers to this question, I'll assume the answer
 is
  No, it's not possible to use settings.xml to have
 application-specific
  properties.
 
  Matt
 
 
  mraible wrote:
  
   I have a number of properties for database settings in my root
 pom.xml:
  
   !-- Database settings --
  
  
 
 dbunit.dataTypeFactoryNameorg.dbunit.dataset.datatype.DefaultDataTypeFactory/dbunit.dataTypeFactoryName
   dbunit.operation.typeCLEAN_INSERT/dbunit.operation.type
  
  
 
 hibernate.dialectorg.hibernate.dialect.MySQLInnoDBDialect/hibernate.dialect
   jdbc.groupIdmysql/jdbc.groupId
   jdbc.artifactIdmysql-connector-java/jdbc.artifactId
   jdbc.version5.0.3/jdbc.version
  
  jdbc.driverClassNamecom.mysql.jdbc.Driver/jdbc.driverClassName
  
  
 
 jdbc.url![CDATA[jdbc:mysql://localhost/tutorial?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url
   jdbc.usernameroot/jdbc.username
   jdbc.password/jdbc.password
  
   This works great when I have a single project.  However, I've
 started
  to
   develop two applications with this setup, and I need to locally
  override
   the jdbc.url for one of my projects.  Is it possible to do this on
 an
   application-specific basis w/o affecting both applications.  AFAIK,
   settings.xml doesn't have anything fancy like (does it?):
  
   activation
property
name${pom.artifactId}/name
valueprojecttoactivatefor/value
/property
   /activation
  
   With Ant, I was able to accomplish this using:
  
   !-- Load user overrides --
   property
  file=${user.home}/.${ant.project.name}-build.properties/
   property file=${user.home}/.build.properties/
   property file=build.properties/
  
   Thanks,
  
   Matt
  
 
  --
  View this message in context:
 
 http://www.nabble.com/Is-it-possible-to-have-application-specific-properties-in-settings.xml--tf3363611s177.html#a9441555
  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/Is-it-possible-to-have-application-specific-properties-in-settings.xml--tf3363611s177.html#a9444290
 Sent from the Maven - Users mailing list archive at Nabble.com

Re: [m2] Is it possible to have application-specific properties in settings.xml?

2007-03-12 Thread mraible

Thanks for the tip - I was able to use a profiles.xml file in my local
project directory to get the behavior I wanted. Now I'm only overriding the
property for a single project, and as long as I don't check it in to SVN,
everyone else retains the default behavior from pom.xml.  Another thing I
tried was to use file activation in settings.xml (because there are
different files in the 2 Maven projects), but that didn't seem to work. 
Here's what I used:

activation
file
exists${basedir}/lib/install.sh/exists
/file
/activation

Thanks for the help Wayne - you solved my problem.

Matt


Wayne Fay wrote:
 
 Have you considered using a profiles.xml file (checked into SCM) which
 contains settings specific to each person's environment? Then you
 would use -Pmrmac which would specify the SQL server on another box,
 while -Pmrxp would specify a local SQL server etc.
 
 This profiles.xml file would be available for everyone to read/write
 but they would be responsible to only edit their piece of the config.
 And you could have a generic config that is used for the common
 developer environment with generic data. I'm not sure if this would
 solve all your problems, though, as it would require you to copy this
 profile.xml file to multiple locations in your SCM and potentially
 keep them all in-sync.
 
 Wayne
 
 On 3/12/07, mraible [EMAIL PROTECTED] wrote:

 I've read this page quite a few times and the answer still doesn't jump
 out
 at me.  If I have two Maven projects that are completely unrelated, but
 they
 use the same property name - how do I override this property's value for
 one
 project, but not for the other?

 In other words, I want jdbc.url to have localhost for most projects
 on
 my system.  And in the SVN version of this other project, I have
 localhost.  However, because I need to connect to a Windows/SQL Server
 box
 for this one project, I need to change jdbc.url to have xpboxname
 instead of localhost.  If I use any sort of system properties, that
 applies
 to all projects.  If I modify the pom.xml, that changes things for
 everyone
 (which doesn't need to happen because I'm on the only one on a Mac).

 I'm all for a workaround, but the only two options I see right now are:

 1. Comment out the activeByDefault setting in pom.xml when I want to
 work
 on other projects (not the one that needs XP).
 2. Change /etc/hosts so localhost resolves to my XP box.

 Thanks for any advice,

 Matt


 Wayne Fay wrote:
 
  It might be useful to review this documentation to make sure you're
  doing it the one true way. ;-)
 
 
 http://maven.apache.org/guides/introduction/introduction-to-profiles.html
 
  Wayne
 
  On 3/12/07, mraible [EMAIL PROTECTED] wrote:
 
  Don't worry - I am doing things The Maven Way with properties in the
  root
  pom.xml.  However, for this particular application, I need to override
 a
  property in settings.xml (I'm on a Mac and need to connect to a SQL
  Server
  instance not on localhost). The problem is, I have another
 application
  that uses the same property name (this can't be that rare, can it?).
 So
  when
  I override it in settings.xml, it overrides all my projects that use
 that
  property name.
 
  Matt
 
 
 
  Wayne Fay wrote:
  
   You are really not encouraged to use application-specific properties
   in a settings.xml file, as your builds will not be portable.
 Instead,
   these kinds of properties should be placed directly in the pom
 (parent
   or children as appropriate) of the project you are working on.
  
   I use a similar process for our Ant builds, with project-specific
   properties in my user home loaded first, then all-projects
 properties,
   etc. I'm pretty sure this is a common pattern across Ant users.
  
   Wayne
  
   On 3/12/07, mraible [EMAIL PROTECTED] wrote:
  
   Since there's been no answers to this question, I'll assume the
 answer
  is
   No, it's not possible to use settings.xml to have
  application-specific
   properties.
  
   Matt
  
  
   mraible wrote:
   
I have a number of properties for database settings in my root
  pom.xml:
   
!-- Database settings --
   
   
  
 
 dbunit.dataTypeFactoryNameorg.dbunit.dataset.datatype.DefaultDataTypeFactory/dbunit.dataTypeFactoryName
   
 dbunit.operation.typeCLEAN_INSERT/dbunit.operation.type
   
   
  
 
 hibernate.dialectorg.hibernate.dialect.MySQLInnoDBDialect/hibernate.dialect
jdbc.groupIdmysql/jdbc.groupId
jdbc.artifactIdmysql-connector-java/jdbc.artifactId
jdbc.version5.0.3/jdbc.version
   
   jdbc.driverClassNamecom.mysql.jdbc.Driver/jdbc.driverClassName
   
   
  
 
 jdbc.url![CDATA[jdbc:mysql://localhost/tutorial?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url
jdbc.usernameroot/jdbc.username
jdbc.password/jdbc.password
   
This works great when I have a single project.  However, I've

Is it possible to have application-specific properties in settings.xml?

2007-03-07 Thread mraible

I have a number of properties for database settings in my root pom.xml:

!-- Database settings --
   
dbunit.dataTypeFactoryNameorg.dbunit.dataset.datatype.DefaultDataTypeFactory/dbunit.dataTypeFactoryName
dbunit.operation.typeCLEAN_INSERT/dbunit.operation.type
   
hibernate.dialectorg.hibernate.dialect.MySQLInnoDBDialect/hibernate.dialect
jdbc.groupIdmysql/jdbc.groupId
jdbc.artifactIdmysql-connector-java/jdbc.artifactId
jdbc.version5.0.3/jdbc.version
jdbc.driverClassNamecom.mysql.jdbc.Driver/jdbc.driverClassName
   
jdbc.url![CDATA[jdbc:mysql://localhost/tutorial?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url
jdbc.usernameroot/jdbc.username
jdbc.password/jdbc.password

This works great when I have a single project.  However, I've started to
develop two applications with this setup, and I need to locally override the
jdbc.url for one of my projects.  Is it possible to do this on an
application-specific basis w/o affecting both applications.  AFAIK,
settings.xml doesn't have anything fancy like (does it?):

activation
 property
 name${pom.artifactId}/name
 valueprojecttoactivatefor/value
 /property
/activation

With Ant, I was able to accomplish this using:

!-- Load user overrides --
property file=${user.home}/.${ant.project.name}-build.properties/
property file=${user.home}/.build.properties/
property file=build.properties/

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-have-application-specific-properties-in-settings.xml--tf3363611s177.html#a9357756
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Selenium, profiles and executing certain browsers on certain OSs

2007-03-06 Thread mraible

I'm using the salenese Ant task to run some Selenium tests in my project. 
I want tests to run in Firefox on all platforms, and Firefox and IE when
running on Windows.  I've got everything working using the XML below, but
it's quite verbose.  Is there a way to simplify, or is this the recommended
strategy?

profiles
profile
id${cargo.container}/id
activation
property
name!maven.test.skip/name
/property
/activation
build
plugins
plugin
groupIdorg.codehaus.cargo/groupId
artifactIdcargo-maven2-plugin/artifactId
version0.2/version
...
/plugin
plugin
artifactIdmaven-antrun-plugin/artifactId
executions
execution
idlaunch-selenium/id
phaseintegration-test/phase
configuration
tasks
taskdef
resource=selenium-ant.properties
classpath
refid=maven.plugin.classpath/
/taskdef
selenese
suite=src/test/resources/selenium/TestSuite.html
  browser=*firefox
timeoutInSeconds=180
 
results=${project.build.directory}/selenium-firefox-results.html
 
startURL=http://${cargo.host}:${cargo.port}/${project.build.finalName}//
/tasks
/configuration
goals
goalrun/goal
/goals
/execution
/executions
dependencies
dependency
groupIdant/groupId
artifactIdant-nodeps/artifactId
version1.6.5/version
/dependency
dependency
   
groupIdorg.openqa.selenium.server/groupId
artifactIdselenium-server/artifactId
version0.9.1-SNAPSHOT/version
/dependency
/dependencies
/plugin
/plugins
/build
/profile
profile
idwindows/id
activation
os
familyWindows/family
/os
/activation
build
plugins
plugin
artifactIdmaven-antrun-plugin/artifactId
executions
execution
idlaunch-selenium/id
phaseintegration-test/phase
configuration
tasks
taskdef
resource=selenium-ant.properties
classpath
refid=maven.plugin.classpath/
/taskdef
selenese
suite=src/test/resources/selenium/TestSuite.html
  browser=*firefox
timeoutInSeconds=180
 
results=${project.build.directory}/selenium-firefox-results.html
 
startURL=http://${cargo.host}:${cargo.port}/${project.build.finalName}//
selenese
suite=src/test/resources/selenium/TestSuite.html
  browser=*iexplore
timeoutInSeconds=180
 
results=${project.build.directory}/selenium-ie-results.html
 
startURL=http://${cargo.host}:${cargo.port}/${project.build.finalName}//
/tasks
/configuration
goals
goalrun/goal
/goals
/execution
/executions
/plugin
/plugins
/build
/profile
/profiles

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Selenium%2C-profiles-and-executing-certain-browsers-on-certain-OSs-tf3358368s177.html#a9341212

Re: [m2] Selenium, profiles and executing certain browsers on certain OSs

2007-03-06 Thread mraible

My current setup only executes Cargo and Selenium when -Dmaven.test.skip=true
is not passed in.  If I move the plugin information to the regular build
part of my pom.xml, do I leave the execution information in profiles?

After adding another profile for Selenium on OS X (for Safari), my
integration-testing section is almost 200 lines long. Yes, it does work,
but it does seem awful verbose.

http://rafb.net/p/2hIgrI84.html

Matt


Eric Redmond wrote:
 
 Sure... pull the build configurations out of the profiles into the project
 build and replace the ant config values with properties... then use the
 profiles to set those property values.
 
 Eric
 
 On 3/6/07, mraible [EMAIL PROTECTED] wrote:


 I'm using the salenese Ant task to run some Selenium tests in my
 project.
 I want tests to run in Firefox on all platforms, and Firefox and IE when
 running on Windows.  I've got everything working using the XML below, but
 it's quite verbose.  Is there a way to simplify, or is this the
 recommended
 strategy?

 profiles
 profile
 id${cargo.container}/id
 activation
 property
 name!maven.test.skip/name
 /property
 /activation
 build
 plugins
 plugin
 groupIdorg.codehaus.cargo/groupId
 artifactIdcargo-maven2-plugin/artifactId
 version0.2/version
 ...
 /plugin
 plugin
 artifactIdmaven-antrun-plugin/artifactId
 executions
 execution
 idlaunch-selenium/id
 phaseintegration-test/phase
 configuration
 tasks
 taskdef
 resource=selenium-ant.properties
 classpath
 refid=maven.plugin.classpath/
 /taskdef
 selenese
 suite=src/test/resources/selenium/TestSuite.html
   browser=*firefox
 timeoutInSeconds=180

 results=${project.build.directory}/selenium-firefox-results.html

 startURL=http://${cargo.host}:${cargo.port}/${project.build.finalName
 }//
 /tasks
 /configuration
 goals
 goalrun/goal
 /goals
 /execution
 /executions
 dependencies
 dependency
 groupIdant/groupId
 artifactIdant-nodeps/artifactId
 version1.6.5/version
 /dependency
 dependency

 groupIdorg.openqa.selenium.server/groupId
 artifactIdselenium-server/artifactId
 version0.9.1-SNAPSHOT/version
 /dependency
 /dependencies
 /plugin
 /plugins
 /build
 /profile
 profile
 idwindows/id
 activation
 os
 familyWindows/family
 /os
 /activation
 build
 plugins
 plugin
 artifactIdmaven-antrun-plugin/artifactId
 executions
 execution
 idlaunch-selenium/id
 phaseintegration-test/phase
 configuration
 tasks
 taskdef
 resource=selenium-ant.properties
 classpath
 refid=maven.plugin.classpath/
 /taskdef
 selenese
 suite=src/test/resources/selenium/TestSuite.html
   browser=*firefox
 timeoutInSeconds=180

 results=${project.build.directory}/selenium-firefox-results.html

 startURL=http://${cargo.host}:${cargo.port}/${project.build.finalName
 }//
 selenese
 suite=src/test/resources/selenium/TestSuite.html
   browser=*iexplore
 timeoutInSeconds=180

 results=${project.build.directory}/selenium-ie-results.html

 startURL=http://${cargo.host}:${cargo.port}/${project.build.finalName
 }//
 /tasks

Re: [m2] How to deploy a war which is not includes directory WEB-INF/lib?

2007-02-12 Thread mraible

Here's how we do this in AppFuse:

plugin
artifactIdmaven-war-plugin/artifactId
version2.0.2/version
executions
execution
idskinny-war/id
goals
goalwar/goal
/goals
phasepost-integration-test/phase
inheritedfalse/inherited
configuration
   
warSourceExcludesWEB-INF/lib/**/warSourceExcludes
/configuration
/execution
/executions
/plugin

Hope this helps,

Matt

秋秋 wrote:
 
 HI,
 I use maven-war-plugin to deploy the war and use maven-jar-plugin to
 deploy the jar for the same project,the project is distributed deployed
 ,and
 I use jboss for the server,I want to deploy the 3th party jar in the
 directory %JBOSS_HOME%server\ProjectName\lib,
 and I don't want there is still a WEB-INF/lib directory in the war,because
 it will breeds strife.How can I do?
 
 

-- 
View this message in context: 
http://www.nabble.com/How-to-deploy-a-war-which-is-not-includes-directory-WEB-INF-lib--tf3212330s177.html#a8932025
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: Testing archetypes with Ant

2007-02-05 Thread mraible

I finally got everything working, but I'm also experiencing a strange side
effect. The common-test.xml[1] script is called from each archetype's
pom.xml:

profiles
profile
idintegration-test/id
activation
property
name!maven.test.skip/name
/property
/activation
build
plugins
plugin
artifactIdmaven-antrun-plugin/artifactId
version1.1/version
configuration
tasks
ant antfile=../common-test.xml dir=.
property name=archetype
value=${pom.artifactId}/
property name=version
value=${pom.version}/
/ant
/tasks
/configuration
executions
execution
phaseintegration-test/phase
goals
goalrun/goal
/goals
/execution
/executions
/plugin
/plugins
/build
/profile
/profiles

However, there's something in these archetype tests that causes downstream
antrun executions to fail. This no longer works:

plugin
artifactIdmaven-antrun-plugin/artifactId
version1.1/version
configuration
tasks
taskdef
resource=webtest_base_relaxed.taskdef
classpath
refid=maven.test.classpath/
/taskdef

AFAICT, the classpath is somehow getting messed up by the archetype Ant
execution.  If I comment out the archetype tests, the above taskdef works. 
Strangely enough, the archetype tests create archetypes and run integration
tests with the same taskdef and it works fine.  Do I need to fork the JVM
or something to get this to work?  Has anyone else experienced antrun
executions causing issues with other antrun executions?

Thanks,

Matt


[1] common-test.xml:

?xml version=1.0 encoding=UTF-8?
!-- This file is imported in the archetype pom.xml files for integration
tests --
project name=common-test default=test

property name=version value=${version}/
property name=archetype value=${archetype}/
property name=test.dir value=${basedir}/target/test-archetype/

target name=test description=Tests that 'mvn integration-test' works
with archetype
echo message=Creating archetype '${archetype}', version
'${version}'/
test archetype=${archetype} version=${version}/
/target

macrodef name=test
attribute name=archetype/
attribute name=version/

sequential
delete dir=${test.dir}/
mkdir dir=${test.dir}/
maven dir=${basedir} command=install
-Dmaven.test.skip=true/
maven dir=${test.dir} archetype=@{archetype}
version=@{version} /
maven dir=${test.dir}/archetype command=integration-test/
/sequential
/macrodef

macrodef name=maven
attribute name=dir/
attribute name=name default=/
attribute name=archetype default=/
attribute name=version default=/
attribute name=command default=archetype:create
-DarchetypeGroupId=org.appfuse [EMAIL PROTECTED]
[EMAIL PROTECTED] -DgroupId=com.mycompany
-DartifactId=archetype/

sequential
exec dir=@{dir} executable=mvn.bat os=Windows XP
failonerror=true
arg line=@{command}/
/exec
exec dir=@{dir} executable=mvn os=Mac OS X
failonerror=true
arg line=@{command}/
/exec
exec dir=@{dir} executable=mvn os=Linux
failonerror=true
arg line=@{command}/
/exec
/sequential
/macrodef
/project

-- 
View this message in context: 
http://www.nabble.com/Testing-archetypes-with-Ant-tf3167091s177.html#a8810296
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Is it possible to do string replacement in an archetype?

2007-02-03 Thread mraible

I'd have the following in the pom.xml of an archetype:

jdbc.url![CDATA[jdbc:mysql://localhost/${artifactId}?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url

If users use a dash in their artifactId, this will fail on most databases. 
Is there a String replacement tool available in the VelocityContext of the
archetype-plugin?  I'd like to do something like:

$stringutil.replace(${artifactId}, '-', '_')

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-do-string-replacement-in-an-archetype--tf3167058s177.html#a8785517
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Testing archetypes with Ant

2007-02-03 Thread mraible

I've figured out a way to test archetypes with Ant, but it's not quite as
clean as I'd like.  In my archetypes directory, I have a common-test.xml[1]
file that gets called from the archetype using the antrun-plugin:

The following works:

plugin
artifactIdmaven-antrun-plugin/artifactId
version1.1/version
configuration
tasks
ant antfile=test.xml/
/tasks
/configuration
executions
execution
phaseintegration-test/phase
goals
goalrun/goal
/goals
/execution
/executions
/plugin

If test.xml has:

?xml version=1.0 encoding=UTF-8?
project name=integration-test basedir=. default=test

!-- Import macrodefs for running Maven to create archetypes and run
integration tests --
import file=../common-test.xml/

target name=test description=Tests that 'mvn integration-test' works
with archetype
test archetype=appfuse-basic-jsf name=basicjsf
version=1.0-m3-SNAPSHOT/
/target
/project

Is it possible to move the contents from test.xml into the pom.xml itself? 
When I try to use the following, it fails with a NPE:

tasks
import file=../common-test.xml/
test archetype=appfuse-basic-jsf
name=basicjsf 
version=1.0-m3-SNAPSHOT/
/tasks

Error:

Embedded error: java.lang.NullPointerException
[INFO]

[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error executing ant
tasks
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
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
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)   
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error executing
ant tasks
at
org.apache.maven.plugin.antrun.AbstractAntMojo.executeTasks(AbstractAntMojo.java:114)
at
org.apache.maven.plugin.antrun.AntRunMojo.execute(AntRunMojo.java:83)   
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
... 16 more
Caused by: java.lang.NullPointerException
at org.apache.tools.ant.Task.perform(Task.java:373)
at org.apache.tools.ant.Target.execute(Target.java:341)
at
org.apache.maven.plugin.antrun.AbstractAntMojo.executeTasks(AbstractAntMojo.java:108)
... 19 more
Caused by: java.lang.NullPointerException
at
org.apache.tools.ant.taskdefs.ImportTask.execute(ImportTask.java:96)
at
org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
at org.apache.tools.ant.Task.perform(Task.java:364)
... 21 more

Does the antrun plugin support imports?

Is this the best way to test archetypes?

Thanks,

Matt

[1] common-test.xml:

?xml version=1.0 encoding=UTF-8?
!-- This file is imported in the archetype pom.xml files for integration
tests --
project
macrodef name=test
attribute name=name/
attribute name=archetype/
attribute name=version/

sequential
delete 

Re: Is it possible to do string replacement in an archetype?

2007-02-03 Thread mraible

I tried this and it doesn't work.  If I pass in an archetypeId with a dash in
it, it gets replaced verbatime with the archetypeId (no replacement takes
place).

Matt


Raphaël Piéroni-3 wrote:
 
 Hi Matt,
 
 According to String javadoc, you could try the replace(char oldChar, char
 newChar) method
 
 jdbc.url![CDATA[jdbc:mysql://localhost/${artifactId.replace('-','_')}
 ?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url
 
 I don't know if it works.
 
 Regards,
 
 
 Raphaël
 
 
 2007/2/3, mraible [EMAIL PROTECTED]:

 I'd have the following in the pom.xml of an archetype:

 jdbc.url
![CDATA[jdbc:mysql://localhost/${artifactId}?createDatabaseIfNotExist=trueamp;useUnicode=trueamp;characterEncoding=utf-8]]/jdbc.url

 If users use a dash in their artifactId, this will fail on most
 databases.
 Is there a String replacement tool available in the VelocityContext of
 the
 archetype-plugin?  I'd like to do something like:

 $stringutil.replace(${artifactId}, '-', '_')

 Thanks,

 Matt
 --
 View this message in context:
 http://www.nabble.com/Is-it-possible-to-do-string-replacement-in-an-archetype--tf3167058s177.html#a8785517
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 

-- 
View this message in context: 
http://www.nabble.com/Is-it-possible-to-do-string-replacement-in-an-archetype--tf3167058s177.html#a8785763
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: Testing archetypes with Ant

2007-02-03 Thread mraible

Hmmm, this might not work as good as I thought it did.  It seems when the
antrun plugin fails during integration testing, the antrun plugin running
the tests doesn't catch and report the failure.  Any idea how to fix this?

 [exec] [ERROR] BUILD ERROR
 [exec] [INFO]

 [exec] [INFO] Error executing ant tasks

 [exec] Embedded error: The following error occurred while executing
this line:
 [exec]
/Users/mraible/Work/appfuse-2.0/archetypes/appfuse-basic-spring/target/basicspring/src/test/resources/web-tests.xml:23:
Canoo Webtest: R_1454.
 [exec] Test failed.
 [exec] Test step steps
(/Users/mraible/Work/appfuse-2.0/archetypes/appfuse-basic-spring/target/basicspring/src/test/resources/web-tests.xml:25:
) null failed with message Step[invoke get Login Page (1/6)]: HTTP error
400, at: invoke
 [exec] [INFO]

 [exec] [INFO] For more information, run Maven with the -e switch
 [exec] [INFO]

 [exec] [INFO] Total time: 22 seconds
 [exec] [INFO] Finished at: Sat Feb 03 12:41:58 MST 2007
 [exec] [INFO] Final Memory: 22M/508M
 [exec] [INFO]

 [exec] Result: 1
[INFO] Executed tasks
[INFO] [install:install]
[INFO] Installing
/Users/mraible/Work/appfuse-2.0/archetypes/appfuse-basic-spring/target/appfuse-basic-spring-1.0-m3-SNAPSHOT.jar
to
/Users/mraible/.m2/repository/org/appfuse/appfuse-basic-spring/1.0-m3-SNAPSHOT/appfuse-basic-spring-1.0-m3-SNAPSHOT.jar
[INFO]

[INFO] BUILD SUCCESSFUL
[INFO]

[INFO] Total time: 29 seconds
[INFO] Finished at: Sat Feb 03 12:41:58 MST 2007
[INFO] Final Memory: 8M/508M
[INFO]


Thanks,

Matt


mraible wrote:
 
 I've figured out a way to test archetypes with Ant, but it's not quite as
 clean as I'd like.  In my archetypes directory, I have a
 common-test.xml[1] file that gets called from the archetype using the
 antrun-plugin:
 
 The following works:
 
 plugin
 artifactIdmaven-antrun-plugin/artifactId
 version1.1/version
 configuration
 tasks
 ant antfile=test.xml/
 /tasks
 /configuration
 executions
 execution
 phaseintegration-test/phase
 goals
 goalrun/goal
 /goals
 /execution
 /executions
 /plugin
 
 If test.xml has:
 
 ?xml version=1.0 encoding=UTF-8?
 project name=integration-test basedir=. default=test
 
 !-- Import macrodefs for running Maven to create archetypes and run
 integration tests --
 import file=../common-test.xml/
 
 target name=test description=Tests that 'mvn integration-test'
 works with archetype
 test archetype=appfuse-basic-jsf name=basicjsf
 version=1.0-m3-SNAPSHOT/
 /target
 /project
 
 Is it possible to move the contents from test.xml into the pom.xml itself? 
 When I try to use the following, it fails with a NPE:
 
 tasks
 import file=../common-test.xml/
 test archetype=appfuse-basic-jsf
 name=basicjsf 
 version=1.0-m3-SNAPSHOT/
 /tasks
 
 Error:
 
 Embedded error: java.lang.NullPointerException
 [INFO]
 
 [INFO] Trace
 org.apache.maven.lifecycle.LifecycleExecutionException: Error executing
 ant tasks
 at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
 at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
 at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
 at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
 at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
 at
 org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
 at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322

Re: native2ascii-maven-plugin is now in mojo's sandbox

2007-02-01 Thread mraible

This plugin doesn't seem to work on OS X:

[ERROR] BUILD ERROR
[INFO]

[INFO] Failed to resolve artifact.

Missing:
--
1) com.sun:tools:jar:dummy

  Try downloading the file manually from the project website.

  Then, install it using the command: 
  mvn install:install-file -DgroupId=com.sun -DartifactId=tools \
  -Dversion=dummy -Dpackaging=jar -Dfile=/path/to/file

  Path to dependency: 
1)
org.codehaus.mojo:native2ascii-maven-plugin:maven-plugin:1.0-beta-1-20070109.041736-1
2) com.sun:tools:jar:dummy

--
1 required artifact is missing.

for artifact: 
 
org.codehaus.mojo:native2ascii-maven-plugin:maven-plugin:1.0-beta-1-20070109.041736-1


mraible wrote:
 
 Thanks Dan - this is just what I needed!  :-D
 
 How would I configure this plugin to process multiple files?  Here's how I
 did it with Ant:
 
 native2ascii src=web/WEB-INF/classes
 dest=${build.dir}/web/classes 
 includes=ApplicationResources_zh*.properties
 encoding=UTF-8/
 native2ascii src=web/WEB-INF/classes
 dest=${build.dir}/web/classes 
 encoding=8859_1
 include name=ApplicationResources_de.properties/
 include name=ApplicationResources_fr.properties/
 include name=ApplicationResources_nl.properties/
 include name=ApplicationResources_pt*.properties/
 /native2ascii
 
 Here's a guess:
 
 plugin
 groupIdorg.codehaus.mojo/groupId
 artifactIdnative2ascii-maven-plugin/artifactId
 version1.0-beta-1-SNAPSHOT/version
 configuration
 desttarget/classes/dest
 srcsrc/main/resources/src
 /configuration
 executions
 execution
 goals
 goalnative2ascii/goal
 /goals
 configuration
 encodingUTF8/encoding
 includesApplicationResources_zh*/includes
 /configuration
 configuration
 encoding8859_1/encoding
 includes

 ApplicationResources_de.properties,ApplicationResources_fr.properties

 ApplicationResources_nl.properties,ApplicationResources_pt*.properties
 /includes
 /configuration
 /execution
 /executions
 /plugin
 
 But it doesn't work. Also, is it possible to change the lifecycle phase so
 it processes after the regular copy resources phase?  It seems likely to
 me that most folks will store their native resources in src/main/resources
 rather than in a new directory.  It'd be nice if we didn't have to exclude
 these files:
 
 resources
 resource
 directorysrc/main/resources/directory
 excludes
 excludeApplicationResources_zh*/exclude
 /excludes
 filteringtrue/filtering
 /resource
 /resources
 
 Thanks,
 
 Matt
 
 
 
 dan tran wrote:
 
 Hello every one,
 
 There seem to have a number of interests, including me, in a maven plugin
 version of ascii2native task,
 so I cooked up one and deployed a snapshot of
 native2ascii-maven-plugin-beta-1.
 
  The site is at http://mojo.codehaus.org/native2ascii-maven-plugin/
 
 Feedbacks are every welcomed.
 
 
 -D
 
 
 
 

-- 
View this message in context: 
http://www.nabble.com/native2ascii-maven-plugin-is-now-in-mojo%27s-sandbox-tf2944026s177.html#a8756443
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: native2ascii-maven-plugin is now in mojo's sandbox

2007-01-30 Thread mraible

Thanks Dan - this is just what I needed!  :-D

How would I configure this plugin to process multiple files?  Here's how I
did it with Ant:

native2ascii src=web/WEB-INF/classes
dest=${build.dir}/web/classes 
includes=ApplicationResources_zh*.properties
encoding=UTF-8/
native2ascii src=web/WEB-INF/classes
dest=${build.dir}/web/classes 
encoding=8859_1
include name=ApplicationResources_de.properties/
include name=ApplicationResources_fr.properties/
include name=ApplicationResources_nl.properties/
include name=ApplicationResources_pt*.properties/
/native2ascii

Here's a guess:

plugin
groupIdorg.codehaus.mojo/groupId
artifactIdnative2ascii-maven-plugin/artifactId
version1.0-beta-1-SNAPSHOT/version
configuration
desttarget/classes/dest
srcsrc/main/resources/src
/configuration
executions
execution
goals
goalnative2ascii/goal
/goals
configuration
encodingUTF8/encoding
includesApplicationResources_zh*/includes
/configuration
configuration
encoding8859_1/encoding
includes
   
ApplicationResources_de.properties,ApplicationResources_fr.properties
   
ApplicationResources_nl.properties,ApplicationResources_pt*.properties
/includes
/configuration
/execution
/executions
/plugin

But it doesn't work. Also, is it possible to change the lifecycle phase so
it processes after the regular copy resources phase?  It seems likely to me
that most folks will store their native resources in src/main/resources
rather than in a new directory.  It'd be nice if we didn't have to exclude
these files:

resources
resource
directorysrc/main/resources/directory
excludes
excludeApplicationResources_zh*/exclude
/excludes
filteringtrue/filtering
/resource
/resources

Thanks,

Matt



dan tran wrote:
 
 Hello every one,
 
 There seem to have a number of interests, including me, in a maven plugin
 version of ascii2native task,
 so I cooked up one and deployed a snapshot of
 native2ascii-maven-plugin-beta-1.
 
  The site is at http://mojo.codehaus.org/native2ascii-maven-plugin/
 
 Feedbacks are every welcomed.
 
 
 -D
 
 

-- 
View this message in context: 
http://www.nabble.com/native2ascii-maven-plugin-is-now-in-mojo%27s-sandbox-tf2944026s177.html#a8716097
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: Overriding properties in a dependency's pom.xml

2007-01-28 Thread mraible

I've entered an enhancement request for this at:

http://jira.codehaus.org/browse/MNG-2757

Maven Developers: how hard would it be to allow property overriding?  It
seems like a natural thing to want to do.

Thanks,

Matt


Larry Meadors-2 wrote:
 
 On 1/4/07, mraible [EMAIL PROTECTED] wrote:
 Is Maven like Ant in that properties are immutable?  If so, can I hook
 into
 the lifecycle sooner and set this dao.framework property from the local
 pom.xml?
 
 I was thinking the same thing - it sure is acting like that is the case,
 no?
 
 Larry
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Overriding-properties-in-a-dependency%27s-pom.xml-tf2921218s177.html#a8684683
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



What's the best way to specify versions for Maven Plugins?

2007-01-22 Thread mraible

What's the best way to specify versions for Maven Plugins. In the AppFuse
project, we're distributing archetypes that have plugins pre-defined in the
pom.xml files.

Should we:

1. Have no version 
2. Use the latest version in the Maven repo
3. Use versionLATEST/version
4. Use versionRELEASE/version

We've been using #1 and the downside seems to be that snapshot repositories
are checked for updates. Does this problem go away when we don't depend on
any snapshots?

#2 seems good, but it requires our users to manually update the version
number when a new release comes out.

I'm looking for the method that doesn't cause a slowdown (i.e. checking
repos for updates) in the build process, but auto-upgrades when new releases
come out.  We have found issues with some plugins (i.e. Jetty 6.0.1 doesn't
work with JSF), so for those we're willing to hard-code the plugin version.

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/What%27s-the-best-way-to-specify-versions-for-Maven-Plugins--tf3062027s177.html#a8514771
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Overriding properties in a dependency's pom.xml

2007-01-04 Thread mraible

I have a project that has dao.frameworkhibernate/dao.framework defined as
a property in the root pom.xml. In a service project, that property is
used as follows:

dependency
groupId${pom.groupId}/groupId
artifactIdappfuse-${dao.framework}/artifactId
version${pom.version}/version
/dependency

In turn, the service dependency is used in WAR projects:

dependency
groupId${pom.groupId}/groupId
artifactIdappfuse-service/artifactId
version${pom.version}/version
exclusions
/dependency

From here, child projects use this WAR project (it's overlayed).  We're
using the Maven WarPath plugin
(http://static.appfuse.org/plugins/maven-warpath-plugin/) to read
dependencies from WARs.

For some reason, if I put dao.frameworkibatis/dao.framework in my child
project, it doesn't override the variable in the service/pom.xml.  However,
if I pass in -Ddao.framework=ibatis from the command-line, everything works.  

Is it possible to override property values in child projects - or is it only
possible from the command-line?  My child project does not refer to any
other projects as parent projects.

Matt
-- 
View this message in context: 
http://www.nabble.com/Overriding-properties-in-a-dependency%27s-pom.xml-tf2921218s177.html#a8164734
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: Overriding properties in a dependency's pom.xml

2007-01-04 Thread mraible

I tried setting the dao.framework property in settings.xml, but that didn't
work either.

It seems there's only two ways to set a DAO Framework with AppFuse/Maven.

1. Pass it in from the command-line: mvn jetty:run-war
-Ddao.framework=jpa-hibernate
2. Set it in your MAVEN_OPTS environment variable: export
MAVEN_OPTS='-Ddao.framework=jpa-hibernate'.

Both of these seem pretty fragile as it requires end users to do something. 
If they don't set the MAVEN_OPTS variable, they'll end up with Hibernate
instead of iBATIS or JPA. Is there a better way to do this?  

Is Maven like Ant in that properties are immutable?  If so, can I hook into
the lifecycle sooner and set this dao.framework property from the local
pom.xml?

Thanks,

Matt



mraible wrote:
 
 I have a project that has dao.frameworkhibernate/dao.framework defined
 as a property in the root pom.xml. In a service project, that property
 is used as follows:
 
 dependency
 groupId${pom.groupId}/groupId
 artifactIdappfuse-${dao.framework}/artifactId
 version${pom.version}/version
 /dependency
 
 In turn, the service dependency is used in WAR projects:
 
 dependency
 groupId${pom.groupId}/groupId
 artifactIdappfuse-service/artifactId
 version${pom.version}/version
 exclusions
 /dependency
 
 From here, child projects use this WAR project (it's overlayed).  We're
 using the Maven WarPath plugin
 (http://static.appfuse.org/plugins/maven-warpath-plugin/) to read
 dependencies from WARs.
 
 For some reason, if I put dao.frameworkibatis/dao.framework in my
 child project, it doesn't override the variable in the service/pom.xml. 
 However, if I pass in -Ddao.framework=ibatis from the command-line,
 everything works.  
 
 Is it possible to override property values in child projects - or is it
 only possible from the command-line?  My child project does not refer to
 any other projects as parent projects.
 
 Matt
 

-- 
View this message in context: 
http://www.nabble.com/Overriding-properties-in-a-dependency%27s-pom.xml-tf2921218s177.html#a8173290
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Is there a publicly-available native2ascii plugin for Maven 2?

2006-12-29 Thread mraible

I've done a fair bit of research and it seems there's two ways to do
native2ascii processing with Maven 2:

1. Use the Ant tasks (quite verbose).
2. Write a plugin.

AFAICT, the only plugin that exists is at:

http://www.jakubpawlowicz.com/blog/2006/03/19/maven_native2ascii_plugin/

It looks like other folks are writing their own solution to this problem:

http://www.nabble.com/Inheritance-tf2714737s177.html#a7569097

Are there any native2ascii plugins in a public repo that I can re-use?  

With AppFuse 1.9.x, we used Ant and native2ascii, which worked great. 
However, with 2.0, we're moving to Maven 2.0 and finding that native2ascii
doesn't exist.  

What's the community's suggestion on this?  Should we push to get a publicly
available (open-source) native2ascii plugin?  Or should we just use the Ant
tasks and put a bunch of XML in our poms? As Maven users and experts, which
method do you prefer?

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Is-there-a-publicly-available-native2ascii-plugin-for-Maven-2--tf2897346s177.html#a8094869
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: Is there a publicly-available native2ascii plugin for Maven 2?

2006-12-29 Thread mraible

In a perfect world, native2ascii could be a native feature of the
maven-resources-plugin.

Matt


Wayne Fay wrote:
 
 Personally, I'd definitely prefer a Maven2-native (perhaps even
 coded/supported by Maven Dev team) native2ascii plugin.
 
 Perhaps Jakub would consider donating his plugin code?
 
 Wayne
 
 On 12/29/06, mraible [EMAIL PROTECTED] wrote:

 I've done a fair bit of research and it seems there's two ways to do
 native2ascii processing with Maven 2:

 1. Use the Ant tasks (quite verbose).
 2. Write a plugin.

 AFAICT, the only plugin that exists is at:

 http://www.jakubpawlowicz.com/blog/2006/03/19/maven_native2ascii_plugin/

 It looks like other folks are writing their own solution to this problem:

 http://www.nabble.com/Inheritance-tf2714737s177.html#a7569097

 Are there any native2ascii plugins in a public repo that I can re-use?

 With AppFuse 1.9.x, we used Ant and native2ascii, which worked great.
 However, with 2.0, we're moving to Maven 2.0 and finding that
 native2ascii
 doesn't exist.

 What's the community's suggestion on this?  Should we push to get a
 publicly
 available (open-source) native2ascii plugin?  Or should we just use the
 Ant
 tasks and put a bunch of XML in our poms? As Maven users and experts,
 which
 method do you prefer?

 Thanks,

 Matt
 --
 View this message in context:
 http://www.nabble.com/Is-there-a-publicly-available-native2ascii-plugin-for-Maven-2--tf2897346s177.html#a8094869
 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/Is-there-a-publicly-available-native2ascii-plugin-for-Maven-2--tf2897346s177.html#a8095668
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Is rsync with central repo still possible?

2006-12-22 Thread mraible

Rsyncing with ibiblio used to be possible using the following:

rsync -v -t -l -r ftp.ibiblio.org::maven2 .

However, now that the Maven repo has moved to Contegix, this command no
longer seems to work.  Now I get the following on OS X:

@ERROR: Unknown module 'maven2'
rsync: connection unexpectedly closed (0 bytes received so far) [receiver]
rsync error: error in rsync protocol data stream (code 12) at
/SourceCache/rsync/rsync-24/rsync/io.c(359)

Anyone know the command to rsync with the new central repo?

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Is-rsync-with-central-repo-still-possible--tf2873629s177.html#a8031762
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Can't find maven-plugin-tools-api

2006-12-13 Thread mraible

Any idea why the maven-plugin-tools-api is hosted in Mergere's repo and not
in central? I just started getting the following error today:

Downloading:
http://repo.mergere.com/maven2/org/apache/maven/maven-plugin-tools-
api/2.0/maven-plugin-tools-api-2.0.pom
[INFO]

[ERROR] BUILD ERROR
[INFO]

[INFO] Error building POM (may not be this project's POM).


Project ID: org.apache.maven:maven-plugin-tools-api

Reason: Error getting POM for 'org.apache.maven:maven-plugin-tools-api' from
the
 repository: Error transferring file
  org.apache.maven:maven-plugin-tools-api:pom:2.0

from the specified remote repositories:
  mergere-public-repository (http://repo.mergere.com/maven2),
  appfuse (http://static.appfuse.org/repository),
  ibiblio-public-repository (http://www.ibiblio.org/maven2),
  central (http://repo1.maven.org/maven2)

It appears that Mergere's repo is down and that's what's causing the
problem.  However, if it's a Maven core plugin, it seems that this should be
stored in central.

Matt
-- 
View this message in context: 
http://www.nabble.com/Can%27t-find-maven-plugin-tools-api-tf2817619s177.html#a7864425
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 I include base tests classes in main JAR

2006-11-18 Thread mraible

We're experiencing the following issue in AppFuse's migration to Maven 2:

http://issues.appfuse.org/browse/APF-478

For each artifact we're creating, we'd like to include the BaseTestCase
class from that project's test module.  It looks like other folks are
interested in doing this as well:

http://jira.codehaus.org/browse/MPJAR-34

The easiest way to do this seems to be to put the class in my source tree,
but then I have to add JUnit as a compile dependency and JUnit will end up
in any WARs that are created.  Seems simple enough, but the extra JAR in the
WAR seems ugly.

Another solution might be to post-process and add the class to the main JAR
before it's installed.  This seems possible, but I couldn't get it to work
with the following configuration:

artifactIdmaven-jar-plugin/artifactId
configuration
classesDirectory
${project.build.testOutputDirectory}
/classesDirectory
/configuration
executions
execution
phasepackage/phase
goals
goaljar/goal
/goals
/execution
/executions
/plugin

The 3rd solution I can think of is to create a new test module that
contains the base classes for all artifacts I'm creating.  This module can
then be referenced as a dependency in other modules.  The only problem with
this is this module will likely have a lot of dependencies, since my
BaseTestCase classes sometimes interact with Spring MVC, Tapestry, Struts
and JSF.  So I'll end up with a similar problem to the one spring-mock has. 
The workaround is likely to make all those dependencies optional.

The last solution I can think of is to include these test classes in the
archetypes that we create for end users.  However, the whole archetype
system doesn't appear to be very robust (i.e. I can't prompt users for
input), so I don't know if archetypes will even be useable for our needs.
We're currently thinking creating a Plugin is a better option, but I'm not
sure if plugins support prompting.  Do they?  If not, I suppose we could use
an Ant-based plugin or just write some sort of installer.

Thanks for any advice,

Matt

-- 
View this message in context: 
http://www.nabble.com/How-do-I-include-base-tests-classes-in-main-JAR-tf2660727s177.html#a7421437
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: dbunit plugin - how to consolidate and not run when skipping tests

2006-11-03 Thread mraible

We've compiled it and deployed it to the the AppFuse repo:

http://static.appfuse.org/repository/

We hope to figure out a way to get it released before we release AppFuse 2.0
final.  We're more than happy to contribute to the plugin.  AFAIK, Brian
Topping built the plugin when we converted an Ant-based AppFuse project to
Maven 2.

Matt


thomasvdv wrote:
 
 Matt,
 
 Where is this dbunit hosted?  I couldn't find it under
 
 http://snapshots.repository.codehaus.org/
 
 Cheers,
 Thomas
 
 
 On 11/1/06, mraible [EMAIL PROTECTED] wrote:


 I have the following configuration for the dbunit plugin:

 plugins
plugin
groupIdorg.codehaus.mojo/groupId
artifactIddbunit-maven-plugin/artifactId
version1.0-SNAPSHOT/version
configuration
driver${jdbc.driverClassName}/driver
username${jdbc.username}/username
password${jdbc.password}/password
url${jdbc.url}/url

 sourceData${basedir}/src/test/data/sample-data.xml/sourceData
sourceDataFormatxml/sourceDataFormat
/configuration
executions
execution
idtest-compile/id
phasetest-compile/phase
goals
goalclean-insert/goal
/goals
/execution
execution
idpre-integration-test/id
phasepre-integration-test/phase
goals
goalclean-insert/goal
/goals
/execution
/executions
dependencies
dependency
groupId${jdbc.groupId}/groupId
artifactId${jdbc.artifactId}/artifactId
version${jdbc.version}/version
/dependency
/dependencies
/plugin

 I'm using this in several poms in my application.  Is it possible to
 consolidate this so it only resides in one location?  I'm guessing I can
 put
 it into a top-level pom? If I do that, where should my sample-data.xml
 reside so all child modules can see it?

 Also, what phase should I use (instead of test-compile) so clean-insert
 is
 skipped when maven.test.skip=true?

 Thanks,

 Matt
 --
 http://raibledesigns.com

 --
 View this message in context:
 http://www.nabble.com/dbunit-plugin---how-to-consolidate-and-not-run-when-skipping-tests-tf2553978s177.html#a7116451
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 

-- 
View this message in context: 
http://www.nabble.com/dbunit-plugin---how-to-consolidate-and-not-run-when-skipping-tests-tf2553978s177.html#a7169427
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: How to native properties files with maven2

2006-11-01 Thread mraible

Is this plugin available in a public repository?  Is there an easier way to
do this that doesn't require tools.jar on the classpath?  This was awful
easy to do with Ant - seems like Maven 2 complicates things here.

Thanks,

Matt


Jakub Pawlowicz wrote:
 
 Hi,
 
 One way to process your properties files with native2ascii is to add Ant's
 native2ascii goal to the Maven's compilation phase.
 Here you could find how to do it (unfortunately only the version cached by
 Google works):
 http://216.239.59.104/search?q=cache:kJFwr1QUsy4J:www.jroller.com/page/wakaleo%3Fentry%3Dmaven_2_tip_using_tools+maven+native2asciihl=plgl=plct=clnkcd=7client=firefox-a
 
 I've described this solution, and proposed a not reduntant one on my
 blog:
 http://www.jakubpawlowicz.com/blog/2006/03/19/maven_native2ascii_plugin/
 
 Please feel free to send any comments about it.
 
 Hope this helps you a bit.
 Regards,
 Jakub
 
 On Thu, 25 May 2006 17:24:43 +0800, chang wei wrote
 Thanks, shen kai.
 
 I have tried maven-resources-plugin, but nothing happened.
 
 I create a web project with mvn. And the project's structure looks 
 like the following:
 
 my-app
 |-- pom.xml
 `-- src
 |-- main
   |   |-- webapp
 |   |   `-- WEB-INFO
 |   `-- resources
 |   `-- META-INF
 |   |-- application.properties
 |   `-- application_zh_CN.properties
 
 If I run mvn war:war$B!$(Bthe application_zh_CN.properties will be 
 packaged into my-app.war. However, Chinese words are in the 
 application_zh_CN.properties file, and  can not be displayed 
 correctly before be natvie2ascii.
 
 I want when I run mvn war:war, the maven natives the
 application_zh_CN.properties file first, then package it into war.
 
 Is there any way to do that?  Please advise, Thanks.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/How-to-native-properties-files-with-maven2-tf1679969s177.html#a7125646
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Using archetype:create to generate an archetype from an existing project

2006-10-08 Thread mraible

I'm trying to use the archetype plugin to create an archetype from an
existing project. From the following issue, I'm not quite sure if this
functionality exists or not:

http://jira.codehaus.org/browse/ARCHETYPE-31

When I try to run archetype:create against Equinox
(http://equinox.dev.java.net), I get the following error:

mvn archetype:create -DgroupId=org.appfuse
-DartifactId=equinox-spring-hibernate -Dpackaging=war

[INFO]

[ERROR] BUILD ERROR
[INFO]

[INFO] Error creating from archetype

Embedded error: Unable to add module to the current project as it is not of
packaging type 'pom'

Is it possible to create an archetype from an existing project?

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Using-archetype%3Acreate-to-generate-an-archetype-from-an-existing-project-tf2407158.html#a6709860
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: Using archetype:create to generate an archetype from an existing pro

2006-10-08 Thread mraible



Wayne Fay wrote:
 
 Matt,
 
 I don't believe this functionality has been implemented in any
 released plugins. IIUC, you're looking for the archetype plugin to
 look at your project and turn it into an archetype, which you can
 later use to create future projects/modules, right? Use your current
 project as a baseline for future work etc without all the work of
 *actually* creating an official archetype...
 
 

Yes, this is what I'm looking for.  Listing all the files in an XML file[1]
seems somewhat painful to me.  Equinox has 35[2] different combinations that
can be created, and it'd be quite a bit of work to write the archetype
descriptor for each one.

Thanks,

Matt

[1] http://maven.apache.org/guides/mini/guide-creating-archetypes.html
[2] http://home.raibledesigns.com:8280/artifacts/equinox-1.x/20061008173744/

-- 
View this message in context: 
http://www.nabble.com/Using-archetype%3Acreate-to-generate-an-archetype-from-an-existing-project-tf2407158.html#a6710331
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Issues with calling mvn from Ant on Linux

2006-10-08 Thread mraible

I have the following macrodef in Ant to run mvn to create project files. 
It works fine on Windows XP and OS X, but on Linux it spits out [exec]
Result: 1.  Any ideas on how to make this work on Linux?

Thanks,

Matt

macrodef name=projectfiles
attribute name=dir/
sequential
exec dir=@{dir} executable=mvn.bat os=Windows XP
arg line=eclipse:eclipse idea:idea/
/exec
exec dir=@{dir} executable=mvn os=Mac OS X
arg line=eclipse:eclipse idea:idea/
/exec
exec dir=@{dir} executable=mvn.sh os=Linux
arg line=eclipse:eclipse idea:idea/
/exec
/sequential
/macrodef
-- 
View this message in context: 
http://www.nabble.com/Issues-with-calling-mvn-from-Ant-on-Linux-tf2407585.html#a6710971
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: Issues with calling mvn from Ant on Linux

2006-10-08 Thread mraible

I've tried both and I get the same result.  In the example below (mvn.sh), I
tried creating a symlink to mvn.

Matt


Alexandre Russel-2 wrote:
 
 On Monday 09 October 2006 04:56, mraible wrote:
 I have the following macrodef in Ant to run mvn to create project
 files.
 It works fine on Windows XP and OS X, but on Linux it spits out [exec]
 Result: 1.  Any ideas on how to make this work on Linux?
 
 exec dir=@{dir} executable=mvn.sh os=Linux
 Are you sure the executable is mvn.sh and not mvn ?
 Alex
 
  
 

-- 
View this message in context: 
http://www.nabble.com/Issues-with-calling-mvn-from-Ant-on-Linux-tf2407585.html#a6711428
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: Does anyone know how to use the maven DBUnit plugin?

2006-08-24 Thread mraible



Ray Tsang wrote:
 
 i'm using dbunit ant task to load initial data.. i have something like
 the following in profiles section of the pom.xml.  it will execute
 when `mvn -DloadData=true`
 
 profile
   iddbunit-load-data/id
   activation
 property
   nameloadData/name
   valuetrue/value
 /property
   /activation
   build
 plugins
   plugin
 artifactIdmaven-antrun-plugin/artifactId
 executions
   execution
 idprocess-classes/id
 phaseprocess-classes/phase
 goals
   goalrun/goal
 /goals
 configuration
   tasks
 property value=CLEAN_INSERT name=operation /
 property value=src/test/sql/test-data.xml
 name=file /
 taskdef name=dbunit
   classname=org.dbunit.ant.DbUnitTask /
 dbunit driver=${database.driver}
   url=${database.url}
   userid=${database.username}
   password=${database.password}
   supportBatchStatement=false
   operation type=${operation}
 src=${file} format=xml /
 /dbunit
   /tasks
 /configuration
   /execution
 /executions
 dependencies
   dependency
 groupId${database.dependency.groupId}/groupId
 artifactId${database.dependency.artifactId}/artifactId
 version${database.dependency.version}/version
   /dependency
   dependency
 groupIddbunit/groupId
 artifactIddbunit/artifactId
 version2.1/version
   /dependency
   dependency
 groupIdant/groupId
 artifactIdant-nodeps/artifactId
 version1.6.5/version
 scopecompile/scope
   /dependency
   dependency
 groupIdcom.sun/groupId
 artifactIdtools/artifactId
 version1.5/version
 scopesystem/scope
 systemPath${java.home}/../lib/tools.jar/systemPath
   /dependency
 /dependencies
   /plugin
 /plugins
   /build
 /profile
 

I'm using a similar setup (see XML below), but having a couple of issues. 

1. Is it possible to have the task invoked at the beginning of the test
phase?  Using phasetest/phase invokes it after running all the tests.  I
want it to run before. Using phasetest-compile/phase works, but seems to
be one phase behind what I want. 

2. How do I load a properties file in to set the ${...} properties?  It
tried property
file=${project.build.sourceResources}/database.properties/ and it doesn't
work.I get the following error:

Embedded error: Class Not Found: JDBC driver ${jdbc.driverClassName} could
not be loaded


plugin
artifactIdmaven-antrun-plugin/artifactId
version1.1/version
executions
execution
phasetest-compile/phase
configuration
tasks
property
file=${project.build.sourceResources}/database.properties/
condition property=operation
value=MSSQL_CLEAN_INSERT else=CLEAN_INSERT
equals arg1=${database.type}
arg2=sqlserver/
/condition

property name=file
value=resources/dbunit/sample-data.xml/
taskdef name=dbunit
classname=org.dbunit.ant.DbUnitTask/
dbunit driver=${jdbc.driverClassName}
supportBatchStatement=false
url=${jdbc.url}
userid=${jdbc.username}
password=${jdbc.password}
operation type=${operation}
src=${file} format=xml/
/dbunit
/tasks
/configuration
goals
goalrun/goal
/goals
/execution
/executions
dependencies
dependency
groupIddbunit/groupId
artifactIddbunit/artifactId
version2.1/version
/dependency
/dependencies
/plugin

Thanks,

Matt

P.S. Anyone know if a DbUnit plugin that's being developed for M2?
-- 
View this message in context: 
http://www.nabble.com/Does-anyone-know-how-to-use-the-maven-DBUnit-plugin--tf1857895.html#a5969492
Sent from the Maven - Users forum at Nabble.com.



Re: [m2] DBUnit plugin form m2?

2006-08-24 Thread mraible



Srepfler Srgjan wrote:
 
 Hi,
 Does anyone know if there is a m2 plugin for DBUnit and if not, can 
 someone post an example pom that uses it via ant?
 

Is anyone working on such a plugin?  Using Ant is pretty verbose and seems
to require putting the data XML file in each module in my (limited)
experience.

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/-m2--DBUnit-plugin-form-m2--tf750700.html#a5970828
Sent from the Maven - Users forum at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [m2] Frustration getting Maven 2 and Hibernate working together

2006-08-24 Thread mraible



Paul Kuykendall wrote:
 
 Jose,
 
 I found this in a blog somewhere (I didn't bookmark it, just copied it
 into
 a tips and tricks email I sent myself at work).  I still ran into
 problems
 with the hibernate3-maven-plugin complaining it couldn't resolve a
 dependency somewhere down the line to maven-hibernate3-plugin.  It could
 have been something I've been doing wrong, but your problem was fairly
 easy
 to track down (after more than a few hours of google searching).  I did
 use
 a different way of doing the jta installation.  I created a jar file and
 installed that rather than the zip file.
 
 /Paul
 
 The below is quite shamefully included without attribution.  I take no
 claim
 for its origination.
 
 Special dependencies
 
 Most of the dependencies you need will be automatically downloaded by
 Maven
 from a remote repository, but two by Sun can't be held there. Go to this
 page http://java.sun.com/products/jta/ to get the JTA interfaces from
 the
 Download link next to Class Files 1.0.1B, then paste the following into
 a
 shell in your download directory:
 
 mvn install:install-file -DgroupId=javax.transaction \
   -DartifactId=jta -Dversion=1.0.1B -Dpackaging=jar \
   -Dfile=jta-1_0_1B-classes.zip
 
 (Or use jta.jar from the Hibernate 3.1.1 distribution, if you have that
 already — just change the -Dfile= parameter above.)
 
 For the EJB 3.0 *public final draft* dependency, you'll need to
 download Hibernate
 Annotationshttp://prdownloads.sourceforge.net/hibernate/hibernate-annotations-3.2.0.CR1.tar.gz?download,
 expand the archive, change to its lib directory, then:
 
 mvn install:install-file -DgroupId=javax.persistence \
   -DartifactId=ejb -Dversion=3.0-public-draft-20060502
  \
   -Dpackaging=jar -Dfile=ejb3-persistence.jar
 
 

Is it possible to override a plugin's dependencies, like you can with a
normal dependency?  I'm trying to use the maven-hibernate3-plugin, and
getting the following error:

Missing:
--
1) javax.transaction:jta:jar:1.0.1B

  Try downloading the file manually from: 
  http://java.sun.com/products/jta

  Then, install it using the command: 
  mvn install:install-file -DgroupId=javax.transaction -DartifactId=jta
\
  -Dversion=1.0.1B -Dpackaging=jar -Dfile=/path/to/file

  Path to dependency: 
1)
org.codehaus.mojo:hibernate3-maven-plugin:maven-plugin:1.0-20060418.000301-9
2) org.hibernate:hibernate-tools:jar:3.1.0.beta4
3) org.hibernate:hibernate:jar:3.1.2
4) javax.transaction:jta:jar:1.0.1B

--
1 required artifact is missing.

for artifact: 
 
org.codehaus.mojo:hibernate3-maven-plugin:maven-plugin:1.0-20060418.000301-9

I'd like to do something like I can do in my normal pom.xml's - where I can
use Geronimo's JTA implementation instead:

dependency
groupIdorg.hibernate/groupId
artifactIdhibernate/artifactId
version3.2.0.cr3/version
exclusions
exclusion
groupIdjavax.transaction/groupId
artifactIdjta/artifactId
/exclusion
/exclusions
/dependency
dependency
groupIdgeronimo-spec/groupId
artifactIdgeronimo-spec-jta/artifactId
version1.0.1B-rc4/version
/dependency

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/-m2--Frustration-getting-Maven-2-and-Hibernate-working-together-tf1892454.html#a5972898
Sent from the Maven - Users forum at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Converting AppFuse to a Maven 2 Project

2006-08-18 Thread mraible

While this looks like an ideal solution, it doesn't appear to work as I'd
like. 

Since I have 4 web/war projects implementing the same thing, it'd be nice to
put common files (i.e. filters, listeners) in a common project and have
that one overlay the other war projects.  Eventually, I'm hoping users will
be able to double war overlay and have the appfuse-jsf (and its dependent
appfuse-web-common war) war project overlay theirs.

However, having the web-common war as a dependency for appfuse-jsf doesn't
seem to work.  In my pom.xml, I have:

nameAppFuse JSF Module/name
build
defaultGoalinstall/defaultGoal
plugins
plugin
artifactIdmaven-war-plugin/artifactId
/plugin
/plugins
/build
...
dependency
groupId${pom.groupId}/groupId
artifactIdappfuse-web-common/artifactId
version${pom.version}/version
typewar/type
/dependency

Yet when I compile appfuse-jsf, it doesn't find the classes in
appfuse-web-common's WEB-INF/classes directory.  Seems like a bug to me. 
I'm sure the solution is to create a JAR for web-common and a WAR for
common-web, but I think it's more intuitive for the classloader to recognize
classes from the overlayed WAR.

Another issue I'm seeing is that the dependencies from appfuse-web-common
aren't recognized in appfuse-jsf.  For example, the following dependencies
are in appfuse-web-common, and needed by appfuse-jsf as well.  However,
appfuse-jsf doesn't find them when compiling.

dependency
groupIdjavax.servlet/groupId
artifactIdjsp-api/artifactId
version2.0/version
scopeprovided/scope
/dependency
dependency
groupIdjavax.servlet/groupId
artifactIdservlet-api/artifactId
version2.4/version
scopeprovided/scope
/dependency

I'm thought this might be an issue with scopeprovided/scope, but I
changed it to scopecompile/scope and the problem still exists.

How hard would it be to change the WAR overlay (or war dependency) to
support class and dependency resolution?  I'm willing to do the work if
someone can point me in the right direction.

Thanks,

Matt

Carlos Sanchez-4 wrote:
 
 even better ;)
 http://maven.apache.org/plugins/maven-war-plugin/examples/war-overlay.html
 
 On 7/19/06, Jörg Schaible [EMAIL PROTECTED] wrote:
 Hi Matt,

 Matt Raible wrote on Wednesday, July 19, 2006 7:56 AM:

 [snip]

  With Maven and separate modules,
  it seems like duplication might be a necessary evil.  For example,
  there are many common CSS/JavaScript files between the web framework
  implementations.  There's no way to copy these into each option's WAR
  at build-time is there?  The easiest way to solve this might be
  svn:externals AFAIK.

 Simply build a toolkit.war with your files to share. Let other wars
 dependend on it and anything will be copied over. See war plugin
 documentation.

 - Jörg

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 
 -- 
 I could give you my word as a Spaniard.
 No good. I've known too many Spaniards.
  -- The Princess Bride
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Converting-AppFuse-to-a-Maven-2-Project-tf1964609.html#a5870757
Sent from the Maven - Users forum at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Converting AppFuse to a Maven 2 Project

2006-08-09 Thread mraible

I started working on the Maven 2 conversion last night. I'm currently using
Carlos's nested recommendation. 

Here's a screenshot of the current structure:

http://raibledesigns.com/repository/images/appfuse2-structure.png

Using this structure, I get errors stating that the data and web parent
projects should have a packaging type of pom.  However, I want these
projects to create their own JAR artifacts.  Should these be moved into
common projects instead of having them in the root of data and web?

Thanks,

Matt
-- 
View this message in context: 
http://www.nabble.com/Converting-AppFuse-to-a-Maven-2-Project-tf1964609.html#a5729055
Sent from the Maven - Users forum at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]