> -----Original Message-----
> From: David Erickson [mailto:[EMAIL PROTECTED] 
> Sent: Friday, August 13, 2004 11:30 PM
> To: Maven Users List
> Subject: Re: A Goal that can execute a class' main method?
> 
> 1) ok so when I call maven from the command line like "maven 
> mygoal" how do I specify these things?  like "maven mygoal 
> -Dmyoption=myvalue" ?

yes

> 2) how can I get a handle on that variable from within my 
> goal scripts?

<maven:get var="" property="" default""/>
For concrete syntax you can check the announcement plugin "plugin.jelly" for
example

> 3) how can I get a handle on the classpath from the 
> dependencies in my project.xml?

You can check the java plugin
          <ant:classpath>
            <ant:path refid="maven.dependency.classpath"/>
            <ant:pathelement path="other paths"/>
          </ant:classpath>

> Thanks,
> David
> 
> ----- Original Message -----
> From: "Carlos Sanchez" <[EMAIL PROTECTED]>
> To: "'Maven Users List'" <[EMAIL PROTECTED]>
> Sent: Friday, August 13, 2004 3:19 PM
> Subject: RE: A Goal that can execute a class' main method?
> 
> 
> Hi,
> 
> You can implement it with ant tasks (<java> I think) in maven.xml
> 1) -Dvar=value
> 2) <java> can have nested classpath
> 
> Regards
> 
> Carlos Sanchez
> A Coru�a, Spain
> 
> Oness Project
> http://oness.sourceforge.net
> 
> 
> > -----Original Message-----
> > From: David Erickson [mailto:[EMAIL PROTECTED]
> > Sent: Friday, August 13, 2004 11:11 PM
> > To: Maven User List
> > Subject: A Goal that can execute a class' main method?
> >
> > Hi guys got a couple questions.  Ive got a project that has a
> > class that updates a database with information.  What I was
> > wondering is if it would be possible to make a maven goal
> > that executes that class, thus making it easy on the end user
> > (since the majority of the dependencies are listed within the
> > dep list).  The requirements are these:
> > 1) I'd need to be able to pass in a java environment variable
> > (from the command line) for where the datafiles are at to be
> > ported into the db
> > 2) I'd need to be able to add elements to the classpath of
> > the class that will be executed (From the command line) in
> > addition to the dependencies that are listed within maven
> >
> > Is something like this possible?  And if so, if you could
> > point me in the direction on how to implement it I'd be
> > greatly appreciative.
> > Thanks,
> > David
> >
> >
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 



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

Reply via email to