0

我正在为旧项目生成 pom 文件。然后我用 mvn clean compile install 测试 em。但有时sourceDirectory指向错误的文件夹并没有错误。我如何检查是否确实编译了某些东西,而无需仅更改 pom 或 mvn 调用的代码。

问候杰夫

4

1 回答 1

0

如果没有编译的源文件 xxxx-sources.jar 不存在,如果您使用插件:

  <plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-source-plugin</artifactId>
    <executions>
      <execution>
        <id>attach-sources</id>
        <goals>
          <goal>jar</goal>
        </goals>
      </execution>
    </executions>
  </plugin>
于 2013-07-09T10:54:55.877 回答