Skip to content

Commit f3b7d14

Browse files
Shanthoosh Pazhanjur VenkataramanShanthoosh Pazhanjur Venkataraman
authored andcommitted
Remove the RC version number from version file and the project version.
1 parent f07da8d commit f3b7d14

File tree

2 files changed

+2
-14
lines changed

2 files changed

+2
-14
lines changed

build.gradle

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -867,19 +867,7 @@ String getVersionFromFile() {
867867

868868
String getProjectVersion() {
869869
if (versionFileExists()) {
870-
String version = getVersionFromFile()
871-
// If version is in 900+ series, treat it as a pre-release
872-
Pattern pattern = Pattern.compile("^([0-9]+)\\.([0-9]+)\\.([0-9]+)\\.([0-9]+)(.*)?\$")
873-
Matcher matcher = pattern.matcher(version)
874-
if (matcher.matches()) {
875-
int lastNum = Integer.valueOf(matcher.group(4))
876-
if (lastNum >= 900) {
877-
// Convert 1.2.0.900+ to 1.2.0.0-rcX format
878-
int rcNum = lastNum - 899
879-
return matcher.group(1) + "." + matcher.group(2) + "." + matcher.group(3) + "." + rcNum
880-
}
881-
}
882-
return version
870+
return getVersionFromFile()
883871
}
884872

885873
try {

version.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.2.0.0-rc1
1+
1.2.0.*

0 commit comments

Comments
 (0)