【发布时间】:2024-05-15 20:00:02
【问题描述】:
我的项目目前使用 Ant 构建,来构建我使用以下目标的 SQL:
<target name="build.update_database">
<artifact:mvn pom="${basedir}/../module-database/pom.xml">
<arg value="clean"/>
<arg value="compile"/>
<arg value="liquibase:updateSQL"/>
</artifact:mvn>
</target>
现在我想移动 Maven,如何在 pom.xml 中配置步骤 'clean'、'compile'、'liquibase:updateSQL'。
pom.xml 是:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.5.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
<debug>true</debug>
<encoding>UTF-8</encoding>
<optimize>true</optimize>
<showDeprecation>true</showDeprecation>
<showWarnings>true</showWarnings>
</configuration>
</plugin>
<plugin>
<groupId>org.liquibase</groupId>
<artifactId>liquibase-maven-plugin</artifactId>
<version>2.0.5</version>
<configuration>
<promptOnNonLocalDatabase>false</promptOnNonLocalDatabase>
<propertyFile>src/main/resources/liquibase.properties</propertyFile>
<verbose>true</verbose>
</configuration>
</plugin>
</plugins>
</build>
【问题讨论】: