Expand my Community achievements bar.

Error building AEM Archetype 23

Avatar

Level 10

Hello all,

I had an issue recently when trying to use the latest AEM Maven Archetype (23) for my personal use.

Problem

I used the following command (based on the command provided in the README):

mvn -B archetype:generate \
 -D archetypeGroupId=com.adobe.granite.archetypes \
 -D archetypeArtifactId=aem-project-archetype \
 -D archetypeVersion=23 \
 -D appTitle="My Site" \
 -D appId="mysite" \
 -D groupId="com.mysite" \
 -D frontendModule=general \
 -D includeExamples=n

It resulted in the following error:

Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:3.0.1:generate (default-cli) on project standalone-pom: Execution default-cli of goal org.apache.maven.plugins:maven-archetype-plugin:3.0.1:generate failed: A required class was missing while executing org.apache.maven.plugins:maven-archetype-plugin:3.0.1:generate: org/apache/ivy/Ivy

 

 

Solution

I solved the issue by specifying the latest version of maven-archetype-plugin (v3.1.2):

mvn -B org.apache.maven.plugins:maven-archetype-plugin:3.1.2:generate \
 -D archetypeGroupId=com.adobe.granite.archetypes \
 -D archetypeArtifactId=aem-project-archetype \
 -D archetypeVersion=23 \
 -D appTitle="My Site" \
 -D appId="mysite" \
 -D groupId="com.mysite" \
 -D frontendModule=general \
 -D includeExamples=n

Which results in:

...
[INFO] Executing META-INF/archetype-post-generate.groovy post-generation script
Creating content skeleton...
[INFO] Project created from Archetype in dir: /home/theo/dev/aem/mysite
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  6.799 s
[INFO] Finished at: 2020-06-22T10:14:21+02:00
[INFO] ------------------------------------------------------------------------

Hope this can help somebody 

7 Replies

Avatar

Administrator

This is what i would want all MVPs should be doing. Thank you for sharing this.



Kautuk Sahni

Avatar

Level 4

I have a issue but seems to be due to in a virtual box, could you please let me know, if you have any idea on below issue.

 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/archetype-23-build-new-aem...

 

@kautuk_sahni  @Theo_Pendle 

Avatar

Level 10

No sorry, still no luck. I even tried on a different device and account...