From fada7691635f0c5e27605071d1584be351f42fc5 Mon Sep 17 00:00:00 2001 From: Igor Demin Date: Wed, 18 Sep 2024 11:44:40 +0200 Subject: [PATCH] Support "1.7.0+metadata" versions (#1568) Allow building versions "1.7.0-beta02+build454" We used this commit for beta01, beta02 builds. --- buildSrc/public/src/main/kotlin/androidx/build/Version.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildSrc/public/src/main/kotlin/androidx/build/Version.kt b/buildSrc/public/src/main/kotlin/androidx/build/Version.kt index c7700860e334b..0c4930c378f58 100644 --- a/buildSrc/public/src/main/kotlin/androidx/build/Version.kt +++ b/buildSrc/public/src/main/kotlin/androidx/build/Version.kt @@ -77,7 +77,7 @@ data class Version( private const val serialVersionUID = 345435634563L private val VERSION_FILE_REGEX = Pattern.compile("^(res-)?(.*).txt$") - private val VERSION_REGEX = Pattern.compile("^(\\d+)\\.(\\d+)\\.(\\d+)((?:\\.\\d+)?(?:-.+)?)?$") + private val VERSION_REGEX = Pattern.compile("^(\\d+)\\.(\\d+)\\.(\\d+)((?:\\.\\d+)?(?:[-\\+].+)?)?$") private fun checkedMatcher(versionString: String): Matcher { val matcher = VERSION_REGEX.matcher(versionString)