如何在Maven中更改$ {project.build.outputDirectory}的默认值?

gal*_*lme 8 maven

我想知道如何将$ {project.build.outputDirectory}的默认值从目标/类更改为maven中的codebase.

谢谢

wem*_*emu 16

在构建中的pom.xml内:

<build>
  <directory>${project.basedir}/target</directory>
  <outputDirectory>${project.build.directory}/classes</outputDirectory>
</build>
Run Code Online (Sandbox Code Playgroud)

请访问http://maven.apache.org/pom.html,了解更多有关pom的乐趣