AW: Got any simple tutorial to learn Maven?

2008-08-26 Thread Glase, Stefan
Hello Henry,

I would recommend you to read the book Maven: The Definitive Guide. You can 
get it for free from http://www.sonatype.com/community/definitive_guide.html 
and I like the examples that help to explain the concepts of maven.

Speaking of dependency management as you mention in your message there is a 
very easy example in chapter 3 and 4 of the book.

Hope to help
Stefan

-Ursprüngliche Nachricht-
Von: Henry Loke [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 26. August 2008 11:58
An: users@maven.apache.org
Betreff: Got any simple tutorial to learn Maven?


As mention in
http://docs.codehaus.org/display/GEOTOOLS/2+What+is+Maven+and+why+do+you+use+it
It also manages (and downloads) any third party jars that are needed for a
build.

Is it mean that if the log4j.jar used in my project, the maven is configure
in such the maven will go to repository to download the log4j.jar file and
put it into specific directory. When run the maven script, then the how
project will deploy successfully.

I read a lot about Maven...
But I still don't know how to implement it to my project.

But I no idea how to use Maven
I using JBoss and elipse for my project... Ant is use to compile and deploy
the code.

P/s: Even Maven is still new for me. But I still have effort to learn from
sketch. Beside documentation but I also need you all to support me.

Thanks...
--
View this message in context: 
http://www.nabble.com/Got-any-simple-tutorial-to-learn-Maven--tp19158765p19158765.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]


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



Re: AW: Got any simple tutorial to learn Maven?

2008-08-26 Thread Henry Loke

U follow the java World tutorial from this link
http://www.javaworld.com/javaworld/jw-12-2005/jw-1205-maven.html?page=3

I just start for a first create command as below

C:\Users\User\Desktop\jw-1205-maven\application\HotelDatabasemvn
archetype:crea
te -DgroupId=com.javaworld.hotels -DartifactId=HotelDatabase
-Dpackagename=com.j
avaworld.hotels
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'archetype'.
[INFO]

[INFO] Building Hotel Database tutorial application
[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] [archetype:create]
[WARNING] This goal is deprecated. Please use mvn archetype:generate instead
[INFO] Defaulting package to group ID: com.javaworld.hotels
[INFO]
-
---
[INFO] Using following parameters for creating OldArchetype:
maven-archetype-qui
ckstart:RELEASE
[INFO]
-
---
[INFO] Parameter: groupId, Value: com.javaworld.hotels
[INFO] Parameter: packageName, Value: com.javaworld.hotels
[INFO] Parameter: package, Value: com.javaworld.hotels
[INFO] Parameter: artifactId, Value: HotelDatabase
[INFO] Parameter: basedir, Value:
C:\Users\User\Desktop\jw-1205-maven\applicatio
n\HotelDatabase
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[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
pack
aging type 'pom'
[INFO]

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

[INFO] Total time: 2 seconds
[INFO] Finished at: Tue Aug 26 23:49:36 SGT 2008
[INFO] Final Memory: 8M/254M
[INFO]


===

From the first command I not succesfully create Archetype, what matter?

Thank


Glase, Stefan wrote:
 
 Hello Henry,
 
 I would recommend you to read the book Maven: The Definitive Guide. You
 can get it for free from
 http://www.sonatype.com/community/definitive_guide.html and I like the
 examples that help to explain the concepts of maven.
 
 Speaking of dependency management as you mention in your message there is
 a very easy example in chapter 3 and 4 of the book.
 
 Hope to help
 Stefan
 
 -Ursprüngliche Nachricht-
 Von: Henry Loke [mailto:[EMAIL PROTECTED]
 Gesendet: Dienstag, 26. August 2008 11:58
 An: users@maven.apache.org
 Betreff: Got any simple tutorial to learn Maven?
 
 
 As mention in
 http://docs.codehaus.org/display/GEOTOOLS/2+What+is+Maven+and+why+do+you+use+it
 It also manages (and downloads) any third party jars that are needed for a
 build.
 
 Is it mean that if the log4j.jar used in my project, the maven is
 configure
 in such the maven will go to repository to download the log4j.jar file and
 put it into specific directory. When run the maven script, then the how
 project will deploy successfully.
 
 I read a lot about Maven...
 But I still don't know how to implement it to my project.
 
 But I no idea how to use Maven
 I using JBoss and elipse for my project... Ant is use to compile and
 deploy
 the code.
 
 P/s: Even Maven is still new for me. But I still have effort to learn from
 sketch. Beside documentation but I also need you all to support me.
 
 Thanks...
 --
 View this message in context:
 http://www.nabble.com/Got-any-simple-tutorial-to-learn-Maven--tp19158765p19158765.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]
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Got-any-simple-tutorial-to-learn-Maven--tp19158765p19164822.html
Sent from the Maven - Users mailing list archive at Nabble.com.



Re: AW: Got any simple tutorial to learn Maven?

2008-08-26 Thread Guang Sheng
Hi,

I just started to learn Maven one month ago and now successfully migrated my
company's new project to maven, which has 8 sub-modules, using GWT,
Gigaspaces, spring, hibernate, etc..

Just want to share with you my experience. Although there are some
archetypes to help you get started easily, I think you still need to get
your hand dirty by handwriting the pom.xml, understanding all the major
elements of pom.xml, all the common plugins (e.g. compile, assembly, jar,
war), as well as the maven's lifecycle. Give yourself a few days to play
around, look at other maven projects.

Basically, by throwing you a pom.xml, if you can understand most of them and
what they are used for, then you're pretty well master the maven. Another
good experience is to setup a hosted repository in your intranet.

I personally feel that appfuse archetype helps me a lot when I learn about
Maven. I used the generated pom.xml as my blueprint when writing my own
pom.xml.
Here is the link: http://appfuse.org/display/APF/AppFuse+QuickStart. After
you created the archetype, run *mvn appfuse:full-source *(
http://appfuse.org/display/APF/FAQ#FAQ-whereisthesource).

Hope this helps you.

On Tue, Aug 26, 2008 at 11:54 PM, Henry Loke [EMAIL PROTECTED] wrote:


 U follow the java World tutorial from this link
 http://www.javaworld.com/javaworld/jw-12-2005/jw-1205-maven.html?page=3

 I just start for a first create command as below
 
 C:\Users\User\Desktop\jw-1205-maven\application\HotelDatabasemvn
 archetype:crea
 te -DgroupId=com.javaworld.hotels -DartifactId=HotelDatabase
 -Dpackagename=com.j
 avaworld.hotels
 [INFO] Scanning for projects...
 [INFO] Searching repository for plugin with prefix: 'archetype'.
 [INFO]
 
 [INFO] Building Hotel Database tutorial application
 [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] [archetype:create]
 [WARNING] This goal is deprecated. Please use mvn archetype:generate
 instead
 [INFO] Defaulting package to group ID: com.javaworld.hotels
 [INFO]
 -
 ---
 [INFO] Using following parameters for creating OldArchetype:
 maven-archetype-qui
 ckstart:RELEASE
 [INFO]
 -
 ---
 [INFO] Parameter: groupId, Value: com.javaworld.hotels
 [INFO] Parameter: packageName, Value: com.javaworld.hotels
 [INFO] Parameter: package, Value: com.javaworld.hotels
 [INFO] Parameter: artifactId, Value: HotelDatabase
 [INFO] Parameter: basedir, Value:
 C:\Users\User\Desktop\jw-1205-maven\applicatio
 n\HotelDatabase
 [INFO] Parameter: version, Value: 1.0-SNAPSHOT
 [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
 pack
 aging type 'pom'
 [INFO]
 
 [INFO] For more information, run Maven with the -e switch
 [INFO]
 
 [INFO] Total time: 2 seconds
 [INFO] Finished at: Tue Aug 26 23:49:36 SGT 2008
 [INFO] Final Memory: 8M/254M
 [INFO]
 

 ===

 From the first command I not succesfully create Archetype, what matter?

 Thank


 Glase, Stefan wrote:
 
  Hello Henry,
 
  I would recommend you to read the book Maven: The Definitive Guide. You
  can get it for free from
  http://www.sonatype.com/community/definitive_guide.html and I like the
  examples that help to explain the concepts of maven.
 
  Speaking of dependency management as you mention in your message there is
  a very easy example in chapter 3 and 4 of the book.
 
  Hope to help
  Stefan
 
  -Ursprüngliche Nachricht-
  Von: Henry Loke [mailto:[EMAIL PROTECTED]
  Gesendet: Dienstag, 26. August 2008 11:58
  An: users@maven.apache.org
  Betreff: Got any simple tutorial to learn Maven?
 
 
  As mention in
 
 http://docs.codehaus.org/display/GEOTOOLS/2+What+is+Maven+and+why+do+you+use+it
  It also manages (and downloads) any third party jars that are needed for
 a
  build.
 
  Is it mean that if the log4j.jar used in my project, the maven is
  configure
  in such