Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

InvalidPackaging: Unable to add module to the current project #5

Open
xilu-wang opened this issue Sep 16, 2019 · 0 comments
Open

InvalidPackaging: Unable to add module to the current project #5

xilu-wang opened this issue Sep 16, 2019 · 0 comments

Comments

@xilu-wang
Copy link

Hi, mvn clean install success, but fail to generate the project from mvn archetype:generate.

Error message:

$ mvn archetype:generate \

 -DarchetypeGroupId=com.romeh.spring-boot-archetypes \
 -DarchetypeArtifactId=spring-boot-quickstart \
 -DarchetypeVersion=1.0.0 \
 -DgroupId=com.test \
 -DartifactId=sampleapp \
 -Dversion=1.0.0-SNAPSHOT \
 -DinteractiveMode=false

[INFO] Scanning for projects...
[INFO]
[INFO] ------< com.romeh.spring-boot-archetypes:spring-boot-quickstart >-------
[INFO] Building Spring Boot Maven Archetype: Quickstart 1.0.0
[INFO] --------------------------[ maven-archetype ]---------------------------
[INFO]
[INFO] >>> maven-archetype-plugin:3.0.1:generate (default-cli) > generate-sources @ spring-boot-quickstart >>>
[INFO]
[INFO] <<< maven-archetype-plugin:3.0.1:generate (default-cli) < generate-sources @ spring-boot-quickstart <<<
[INFO]
[INFO]
[INFO] --- maven-archetype-plugin:3.0.1:generate (default-cli) @ spring-boot-quickstart ---
[INFO] Generating project in Batch mode
[INFO] Archetype repository not defined. Using the one from [com.romeh.spring-boot-archetypes:spring-boot-quickstart:1.0.0] found in catalog local
[INFO] ----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype: spring-boot-quickstart:1.0.0
[INFO] ----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: com.test
[INFO] Parameter: artifactId, Value: sampleapp
[INFO] Parameter: version, Value: 1.0.0-SNAPSHOT
[INFO] Parameter: package, Value: com.test
[INFO] Parameter: packageInPathFormat, Value: com/test
[INFO] Parameter: package, Value: com.test
[INFO] Parameter: groupId, Value: com.test
[INFO] Parameter: artifactId, Value: sampleapp
[INFO] Parameter: version, Value: 1.0.0-SNAPSHOT
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.dom4j.io.SAXContentHandler (file:/Users/XXXXXX/.m2/repository/dom4j/dom4j/1.6.1/dom4j-1.6.1.jar) to method com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser$LocatorProxy.getEncoding()
WARNING: Please consider reporting this to the maintainers of org.dom4j.io.SAXContentHandler
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.286 s
[INFO] Finished at: 2019-09-16T08:54:52-07:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:3.0.1:generate (default-cli) on project spring-boot-quickstart: org.apache.maven.archetype.exception.InvalidPackaging: Unable to add module to the current project as it is not of packaging type 'pom' -> [Help 1]
[ERROR]
[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]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant