File tree Expand file tree Collapse file tree 3 files changed +12
-4
lines changed Expand file tree Collapse file tree 3 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ apply from: "gradle/idea.gradle"
22
22
apply plugin : ' java'
23
23
24
24
group = ' com.palantir.docker.compose'
25
- version " git describe --tags --dirty" . execute(). text. trim(). replaceAll( / ^v / , ' ' )
25
+ version " git describe --tags --dirty" . execute(). text. trim()
26
26
27
27
apply plugin : ' com.palantir.baseline-checkstyle'
28
28
apply plugin : ' com.palantir.baseline-eclipse'
Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ general:
21
21
22
22
deployment :
23
23
release :
24
- tag : /v? [0-9]+(\.[0-9]+)+/
24
+ tag : /[0-9]+(\.[0-9]+)+/
25
25
commands :
26
26
- ./gradlew -i bintrayUpload
27
27
Original file line number Diff line number Diff line change @@ -58,8 +58,16 @@ bintray {
58
58
}
59
59
60
60
bintrayUpload. onlyIf {
61
- System . out. println (" Publishing with project version: " + project. version. toString())
62
- System . env. BINTRAY_USER && System . env. BINTRAY_KEY && project. version. toString() ==~ / v?\d +\.\d +\.\d +/
61
+ println " Attempting to publish with project version: " + project. version. toString()
62
+
63
+ def versionIsInCorrectFormat = project. version. toString() ==~ / \d +\.\d +\.\d +/
64
+
65
+ if (! versionIsInCorrectFormat) {
66
+ println " Cannot publish project with version " + project. version. toString() +
67
+ " ; it must be in form 'major.minor.patch'"
68
+ }
69
+
70
+ System . env. BINTRAY_USER && System . env. BINTRAY_KEY && versionIsInCorrectFormat
63
71
}
64
72
65
73
bintrayUpload. dependsOn ' generatePomFileForBintrayPublication' , ' build'
You can’t perform that action at this time.
0 commit comments