maven approaches

hI,

i was reading about maven as below


Maven Project can be generated in two ways:-

Without argument( inside mvn archetype:generate )
With argument (inside mvn archetype:generate)

I wonder why we need maven. What are the advantages of it. What are above two approaches of creating maven project.


I downloaded maven 3.05 from
http://maven.apache.org/download.cgi

I gave command
mvn -version
it printed maven3.05

I created on folder called TestMaven in C drive.

I went to C:\TestMaven from windows command prompt on my windows 7 laptop.

I gave command ther saying

 mvn archetype:generate

I see .m2 folder created
C:\Users\xyz\.m2
then
I am gettign errors in command prompt as below

I see many
'Failed to retrieve plugin descriptor for org.apache.maven.plugins:mave.....'
also at the end

'No Plugin found for prefix 'archetype'
 mvn archetype:generate

I could not give below as next steps


Archetype
Group Id
Artifact Id

Version  and
package

What for above definitions used?

Please advise on how to set up and run maven projects.


Any links resources ideas highly appreciated. Thanks in advance
LVL 7
gudii9Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

girionisCommented:
0
gudii9Author Commented:
>>>Without argument( inside mvn archetype:generate )
>>With argument (inside mvn archetype:generate)


when i gave command on the command prompt
 (without aruments inside archetype:generate like Archetype (this is project type by default it is no 16  i.e quickstart)
Group Id (package name)

Artifact Id (application name)

Version  and
package
)
i got error message as below.not sure what is the issue

C:\Users\mavenTests>mvn archetype:generate
[INFO] Scanning for projects...
Downloading: http://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-
clean-plugin/2.4.1/maven-clean-plugin-2.4.1.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:mave
n-clean-plugin:2.4.1: Plugin org.apache.maven.plugins:maven-clean-plugin:2.4.1 o
r one of its dependencies could not be resolved: Failed to read artifact descrip
tor for org.apache.maven.plugins:maven-clean-plugin:jar:2.4.1
Downloading: http://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-
install-plugin/2.3.1/maven-install-plugin-2.3.1.pom


I would like to know what is the difference between above two approaches and which one to use in which practical scenario. please advise
0
girionisCommented:
This is a warning, you can probably ignore it. Does it cause any problems?
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Java EE

From novice to tech pro — start learning today.