More examples testing.
This commit is contained in:
parent
c7d46bfd7a
commit
f4f0ce42ae
12 changed files with 50 additions and 38 deletions
|
@ -1,9 +1,14 @@
|
|||
// plugins {
|
||||
// id 'java'
|
||||
// id 'application'
|
||||
// id "net.thauvin.erik.gradle.semver" version "0.9.4-beta"
|
||||
// }
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenLocal()
|
||||
}
|
||||
dependencies {
|
||||
classpath "net.thauvin.erik.gradle:semver:0.9.4-beta"
|
||||
classpath "net.thauvin.erik.gradle:semver:0.9.5-beta"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -15,6 +20,8 @@ mainClassName = 'App'
|
|||
|
||||
version = 1.0
|
||||
|
||||
def f = new File("test.properties")
|
||||
|
||||
dependencies {
|
||||
|
||||
}
|
||||
|
@ -23,21 +30,26 @@ repositories {
|
|||
jcenter()
|
||||
}
|
||||
|
||||
task cleanVersion {
|
||||
delete "test.properties"
|
||||
clean {
|
||||
delete fileTree(dir: "$projectDir", include: "*.properties")
|
||||
}
|
||||
|
||||
clean.dependsOn("cleanVersion")
|
||||
incrementPatch {
|
||||
doFirst {
|
||||
println("[Gradle] exists: " + f.exists() + ", canRead: " + f.canRead())
|
||||
}
|
||||
}
|
||||
|
||||
run {
|
||||
//dependsOn("incrementPatch")
|
||||
//dependsOn("incrementPatch")
|
||||
doFirst {
|
||||
println("Version: $version")
|
||||
args = [f.name]
|
||||
}
|
||||
}
|
||||
|
||||
semver {
|
||||
properties = "$projectDir/example.properties"
|
||||
keysPrefix = "example."
|
||||
properties = "$projectDir/${f.name}"
|
||||
keysPrefix = f.name.substring(0, f.name.indexOf(".") + 1)
|
||||
buildMetaKey = "meta"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue