[m2] JAXB 2.0 XJC task with mustang - tip

2006-05-21 Thread Aaron Anderson
I was trying to use the jaxb 2.0 maven 2 plugin from 
https://jaxb.dev.java.net/jaxb-maven2-plugin/ with JDK 1.6 but ran into a lot 
of classpath problems when generating the XML bindings. For future reference 
here a plugin setting for use in your m2 project that will use the built in xjc 
in mustang.
   
   


maven-antrun-plugin


generate-sources















${project.build.directory}/generated-sources/xjc


run



  

org.apache.maven.plugins
maven-compiler-plugin

1.6
1.6






overriding maven-core default implementations of components

2006-05-05 Thread Aaron Anderson
The maven-core artifact has a META-INF/plexus/components.xml that defines the 
default implementations for all the components. One can create a plugin that 
has it's own component.xml override and if a POM has this plugin configured 
with extention->true then the override will occur.
   
  I would like to take this a step further and somehow configure the default 
maven installation to use a custom component.xml file with custom 
implementations. For example, in the absence of a POM I would like the 
archetype plugin to use my implementation of the Archetype interface instead of 
the default one.
   
Is there a way to modify the default super POM that all POM's extend from to 
use a custom plugin that defines new implementations for components? Is 
modifying and creating a custom maven-core artifact the only way to change the 
default implementations for components?


Re: svn authentication with m2 release plugin

2006-05-05 Thread Aaron Anderson
thanks, 
   
  release:prepare -Dusername=myid =Dpassword=mypassword 
   
  did the trick

Alexandre Poitras <[EMAIL PROTECTED]> wrote:
  There is a mistake there, the plugin uses "username" ("user.name" is
the OS user in Java).

On 5/4/06, Andrew Kreps wrote:
> I'm not using SVN, but on the Maven site I found this:
>
>
> Use a different username in the SCM server than he one in the operating 
> system:
>
> Run mvn -Duser.name=your_username release:prepare
>
>
> It's on this page:
> http://maven.apache.org/plugins/maven-release-plugin/howto.html
>
> Hopefully that will help.
>
>
> On 5/4/06, Aaron Anderson wrote:
> > I am using subversion for scm and would like to use the m2 release plugin. 
> > I run release:prepare but I always get an "authorization failed" error from 
> > svn. After doing a network trace I can that the svn client is sending my 
> > operating system credentials (!) instead of my subversion credentials. I 
> > did not modify the svn cached credentials setting and can easily run svn 
> > up, co, etc without entering credentials and the credentials sent are 
> > correct.
> >
> > Why is svn not sending the proper cached credentials when run from the 
> > release plugin? Is there a way to specify the scm userID & pwd from the 
> > command line as there was with the m1 release plugin?
> >
> > TIA
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

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




Re: [m2] Archetype/packageName/directory structure

2006-05-05 Thread Aaron Anderson
I have been working on an enhanced archetype concept 
http://jira.codehaus.org/browse/ARCHETYPE-33 
   
  maybe it will get picked up
  


bryan hansen <[EMAIL PROTECTED]> wrote:
  Well, it should work... If I put a folder under the
archetype resources directory such as:
src/main/resources/archetype-resources/src/main/java/services

I would expect it to then put the ${packageName}
directory structure in front of it and it doesn't.

Any ideas of what I should try? The documentation on
this is very little.

Thanks,

Bryan

--- Alexandre Poitras 
wrote:

> I see. I have never tried it myself but it should
> work. One thing you
> might consider is that right now the archetype
> plugin doesn't care
> about an empty directory (I think it is a bug) and
> so you have to put
> a dumb java file in the directory in order to make
> it work.
> 
> 
> On 5/5/06, bryan hansen wrote:
> > Ok here goes. I am using a custom archetype to
> create
> > an AppFuse style project. We create a lot of small
> > projects in our organization and we want the
> directory
> > structure to be the same. There will be a view,
> > service, and model directory in every application.
> > These directories contain some basic base classes.
> So
> > when I run the archetype I would like the
> directory
> > structure to have a
> > ${packageName}/services/SomeService.java file, a
> > ${packageName}/view/SomeBackingBean.java file, and
> a
> > ${packageName}/model/SomeModel.java file.
> >
> > From all the examples that I have seen out there
> all
> > the archetypes are very simple and just dump a
> file
> > out to the ${packageName}/App.java.
> >
> > I want to be able to do a little more with the
> > directory structure than just dump out the main
> > package. I would think that this is possible, but
> I
> > can't see how to do it.
> >
> > That help?
> >
> >
> >
> >
> >
> > --- Alexandre Poitras
> 
> > wrote:
> >
> > > I really don't get what you want. Could you
> explain
> > > more precisely
> > >
> > > On 5/4/06, bryan hansen wrote:
> > > > I am creating a custom archetype and am not
> seeing
> > > a
> > > > way to have folders carried throught the
> > > archetype. I
> > > > have a source file in the resources directory
> such
> > > as:
> > > >
> > > >
> > >
> >
>
src/main/resources/archetype-resources/src/main/java/App.java
> > > >
> > > > When I run this through the archetype:create
> > > command
> > > > it will place this file under the package
> > > directory
> > > > correctly.
> src/main/java/com/mycompany/App.java
> > > >
> > > > I want to have some folders that get carried
> > > through
> > > > though such as:
> > > >
> > > >
> > >
> >
>
src/main/resources/archetype-resources/src/main/java/service/AppService.java
> > > >
> > > > so that when I run the archetype:create
> command it
> > > > will be placed in a folder like this:
> > > >
> > > >
> > >
> src/main/java/com/mycompany/service/AppService.java
> > > >
> > > > The way it is working now by putting it under
> the
> > > > resources directory it is building out a
> directory
> > > > structure and duplicating the package name
> > > underneath
> > > > it.
> > > >
> > >
> src/main/java/service/com/mycompany/AppService.java
> > > >
> > > > Is it possible with the archetype to have it
> > > create
> > > > the directory structure and carry it through
> like
> > > I
> > > > described?
> > > >
> > > > Thanks,
> > > >
> > > > Bryan
> > > >
> > > >
> __
> > > > Do You Yahoo!?
> > > > Tired of spam? Yahoo! Mail has the best spam
> > > protection around
> > > > http://mail.yahoo.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]
> > >
> > >
> >
> >
> > __
> > Do You Yahoo!?
> > Tired of spam? Yahoo! Mail has the best spam
> protection around
> > http://mail.yahoo.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]
> 
> 


__
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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




svn authentication with m2 release plugin

2006-05-04 Thread Aaron Anderson
I am using subversion for scm and would like to use the m2 release plugin. I 
run release:prepare but I always get an  "authorization failed" error from svn. 
After doing a network trace I can that the svn client is sending my operating 
system credentials (!) instead of my subversion credentials. I did not modify 
the svn cached credentials setting and can easily run svn up, co, etc without 
entering credentials and the credentials sent are correct. 
   
  Why is svn not sending the proper cached credentials when run from the 
release plugin? Is there a way to specify the scm userID & pwd from the command 
line as there was with the m1 release plugin?
   
  TIA


Re: Using profile property from settings.xml in plugin with requiresProject=false

2006-04-22 Thread Aaron Anderson
Hmm, I am running 2.0.3
   
  I did some additional debugging and opened up a JIRA issue about the profiles 
not being loaded in the standaloneSuperProject
   
  http://jira.codehaus.org/browse/MNG-2236
   
  Thanks for your help! it is greatly appreciated

Alexandre Poitras <[EMAIL PROTECTED]> wrote:
  It is fix in the version 2.0.1 so ensure you use the latest one :)
http://jira.codehaus.org/browse/MPH-11

On 4/22/06, Aaron Anderson wrote:
> I get a build error:
>
> [INFO] Cannot execute mojo: effective-settings. It requires a project with an 
> ex
> isting pom.xml, but the build is not using one.
>
>
> Alexandre Poitras wrote:
> What does "mvn help:effective-settings" output?
>
> On 4/20/06, Aaron Anderson wrote:
> > I am writing a maven 2 plugin that can be used to invoke some JMX 
> > operations on a server and I would like it to be able to be run the plugin 
> > from any directory. This plugin has parameters that's values are set from 
> > properties set in a profile defined in the settings.xml (bad form, I know). 
> > I have added the requiresProject=false annotation to the plugin so I can 
> > run it in the absence of a POM file. The plugin works fine when a POM is 
> > present.
> >
> > However, when I run the plugin without a POM the plugin's parameters thats 
> > values are set with expressions that reference the properties from the 
> > settings.xml profile are not set. It seems the settings.xml file is not 
> > loaded and the active profiles properties are not loaded into the plugin.
> >
> > Is this an expected behavior? Even without a POM present the super-pom is 
> > loaded so I would think the settings.xml should still be loaded and the 
> > profile properties applied to the plugin.
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
>

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




Re: Using profile property from settings.xml in plugin with requiresProject=false

2006-04-22 Thread Aaron Anderson
I get a build error: 
   
  [INFO] Cannot execute mojo: effective-settings. It requires a project with an 
ex
isting pom.xml, but the build is not using one.
  

Alexandre Poitras <[EMAIL PROTECTED]> wrote:
  What does "mvn help:effective-settings" output?

On 4/20/06, Aaron Anderson wrote:
> I am writing a maven 2 plugin that can be used to invoke some JMX operations 
> on a server and I would like it to be able to be run the plugin from any 
> directory. This plugin has parameters that's values are set from properties 
> set in a profile defined in the settings.xml (bad form, I know). I have added 
> the requiresProject=false annotation to the plugin so I can run it in the 
> absence of a POM file. The plugin works fine when a POM is present.
>
> However, when I run the plugin without a POM the plugin's parameters thats 
> values are set with expressions that reference the properties from the 
> settings.xml profile are not set. It seems the settings.xml file is not 
> loaded and the active profiles properties are not loaded into the plugin.
>
> Is this an expected behavior? Even without a POM present the super-pom is 
> loaded so I would think the settings.xml should still be loaded and the 
> profile properties applied to the plugin.
>
>

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




Using profile property from settings.xml in plugin with requiresProject=false

2006-04-20 Thread Aaron Anderson
I am writing a maven 2 plugin that can be used to invoke some JMX operations on 
a server and I would like it to be able to be run the plugin from any 
directory. This plugin has parameters that's values are set from properties set 
in a profile defined in the settings.xml (bad form, I know). I have added the 
requiresProject=false annotation to the plugin so I can run it in the absence 
of a POM file. The plugin works fine when a POM is present. 
   
  However, when I run the plugin without a POM the plugin's parameters thats 
values are set with expressions that reference the properties from the 
settings.xml profile are not set. It seems the settings.xml file is not loaded 
and the active profiles properties are not loaded into the plugin. 
   
  Is this an expected behavior? Even without a POM present the super-pom is 
loaded so I would think the settings.xml should still be loaded and the profile 
properties applied to the plugin.