如何在spring boot Gradle项目中为jar附加时间戳?
./gradlew build
创建 jar app-0.0.1-SNAPSHOT.jar
,如何创建带有时间戳的 jar
app-0.0.1-SNAPSHOT-2020-11-09.02-30.jar
-------- 摇篮
plugins {
id 'org.springframework.boot' version '2.3.5.RELEASE'
id 'io.spring.dependency-management' version '1.0.10.RELEASE'
id 'java'
}
group = 'com.example'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = '11'
repositories {
mavenCentral()
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter'
testImplementation('org.springframework.boot:spring-boot-starter-test') {
exclude group: 'org.junit.vintage', module: 'junit-vintage-engine'
}
}
test {
useJUnitPlatform()
}