Java Coder
Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.2:generate
1 Answer(s)      2 years and 9 months ago
Posted in : Maven


I am creating a project using following command:

Its giving following error:

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.2:generate (default-cli) on project standalone-pom: Execution default-cli of goal org.apache.maven.plugins:maven-archetype-plugin:2.2:generate failed: Plugin org.apache.maven.plugins:maven-archetype-plugin:2.2 or one of its dependencies could not be resolved: The following artifacts could not be resolved: org.apache.maven.archetype:archetype-descriptor:jar:2.2, org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-5, org.codehaus.groovy:groovy:jar:1.8.3: Could not transfer artifact org.apache.maven.archetype:archetype-descriptor:jar:2.2 from/to ( Access denied to: , ReasonPhrase:Forbidden. -> [Help 1]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1]

Suggest me the solution.



View Answers

May 30, 2014 at 12:16 PM


There was some error with the settings.xml file. I deleted the file settings.xml from the .m2 directory and now its working.

You might check the configuration in the settings.xml file and try to resolve the issue.


Related Tutorials/Questions & Answers: