我正在尝试将现有项目转换为 Maven 项目。它有 3 个模块,其中一个模块有多个源文件夹。 http://i.imgur.com/jZCnR.png
maven clean and install 或 eclipse clean 不会在 classes 和 test-classes 文件夹中创建类文件。项目结构是由那里没有类文件创建的。
以下插件配置在父 pom.xml 中定义。
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<id>add-source</id>
<phase>generate-sources</phase>
<goals><goal>add-source</goal></goals>
<configuration>
<sources>
<source>src/main/java/**/*.*</source>
<source>src/report/java/**/*.*</source>
<source>src/architect/java/**/*.*</source>
</sources>
</configuration>
</execution>
<execution>
<id>add-test-source</id>
<phase>generate-test-sources</phase>
<goals><goal>add-test-source</goal></goals>
<configuration>
<sources>
<source>src/test/java/**/*.*</source>
</sources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.0</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
<debug>false</debug>
</configuration>
<executions>
<execution>
<id>default-compile</id>
<phase>compile</phase>
<goals><goal>compile</goal></goals>
<configuration>
<includes>
<include>src/main/java/**/*.*</include>
<include>src/report/java/**/*.*</include>
<include>src/architect/java/**/*.*</include>
</includes>
</configuration>
</execution>
<execution>
<id>default-testCompile</id>
<phase>test-compile</phase>
<goals><goal>testCompile</goal></goals>
<configuration>
<testIncludes>
<include>src/test/java/**/*.*</include>
</testIncludes>
</configuration>
</execution>
</executions>
</plugin>
我究竟做错了什么?