Today I created a maven project, and I did not consider creating a child maven project when the creation was completed.
During the encoding process, it was found that it was necessary to create a submodule, so a new submaven project was created under the maven project. After the subproject was created, maven was set. An error was found in the subproject file, and the error was as follows:
Some problems were encountered while processing the POMs: [ERROR] Invalid packaging for parent POM bo.zhao:myutil:1.0-SNAPSHOT (E:\IDEA\myutil\pom.xml), must be "pom" but is "jar" @ bo.zhao:myutil:1.0-SNAPSHOT, E:\IDEA\myutil\pom.xm
The key sentences are:Invalid
packaging
for
parent POM bo
.
zhao
:
myutil
:
1.0
-
SNAPSHOT
(
E
:
\IDEA\myutil\pom
.
xml
),
must be
"pom"
but is
"jar"
Solution:
The following nodes are added under the project node of the parent project file:
<packaging>pom</packaging>
Finally, update maven.