mvn versions:set -DnewVersion=1.2.0-SNAPSHOT
指定jar
mvn dependency:sources -DincludeArtifactIds=common-annotation
全量sources
mvn dependency:resolve -Dclassifier=sources
mvn clean archetype:create-from-project -Darchetype.properties=./archetype.properties -Darchetype.filteredExtentions=java,xml,jsp,properties,sql
mvn archetype:generate -DgroupId=com.hellobike.base -DartifactId=mytest -Dpackage=com.hellobile.base.mytest -Dversion=1.0.0-SNAPSHOT -DarchetypeGroupId=com.hellobike.helloboot -DarchetypeArtifactId=sample-helloboot-archetype -DarchetypeVersion=1.0.0-SNAPSHOT
默认本地打包带不带日期, 从服务器下载的就带日期
远程下载也不带日期, 需要打包时候指定:
mvn clean deploy -DuseUniqueVersions=false
mvn help:effective-pom
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.build.timestamp.format>yyyy-MM-dd_HH_mm</maven.build.timestamp.format>
</properties>
<build>
<finalName>${project.artifactId}-${maven.build.timestamp}</finalName>
</build>
基于 Maven Archetype 创建项目
How is metadata about an archetype stored?
<requiredProperties>
<requiredProperty key="property-with-default">
<defaultValue>default-value</defaultValue>
</requiredProperty>
<requiredProperty key="property-without-default"/>
</requiredProperties>