Я разрабатываю проекты в Eclipse и использую Maven, поэтому я создал новый архетип, используя ' maven-archetype-archetype ' Archetype , но как только я пытаюсь создать новый проект с моим новым архетипом, я получаю следующее сообщение об ошибке в Eclipse:
The META-INF/maven/archetype.xml descriptor cannot be found.
Есть идеи, в чем причина?
Обновление:
Мой файл archetype.xml:
<archetype>
<id>test-archetype</id>
<sources>
<source>src/</source>
</sources>
<testSources>
<source>test/</source>
</testSources>
</archetype>
Мой pom.xml:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>$my.group.id</groupId>
<artifactId>$test-archetype</artifactId>
<version>$0.0.1</version>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
</project>
Структура папок выглядит так:
archetype
|-- pom.xml
`-- src
`-- main
`-- resources
|-- META-INF
| `-- maven
| `--archetype.xml
`-- archetype-resources
|-- pom.xml
`-- src
`-- test
Адам.