From 00e3c4bb5a5d96dd6dab2d43cb8ce449793b3bc4 Mon Sep 17 00:00:00 2001 From: Natsu Kagami Date: Tue, 26 Aug 2025 15:42:12 +0200 Subject: [PATCH] Change Nightly version date to be the current date in UTC --- project/Build.scala | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/project/Build.scala b/project/Build.scala index c79bc2522d9c..3d52ac233f73 100644 --- a/project/Build.scala +++ b/project/Build.scala @@ -99,7 +99,12 @@ object Build { /** Final version of Scala compiler, controlled by environment variables. */ val dottyVersion = { if (isRelease) baseVersion - else if (isNightly) s"${baseVersion}-bin-${VersionUtil.commitDate}-${VersionUtil.gitHash}-NIGHTLY" + else if (isNightly) { + val formatter = java.time.format.DateTimeFormatter.ofPattern("yyyyMMdd") + val currentDate = + formatter.format(java.time.ZonedDateTime.now(java.time.ZoneId.of("UTC"))) + s"${baseVersion}-bin-${currentDate}-${VersionUtil.gitHash}-NIGHTLY" + } else s"${baseVersion}-bin-SNAPSHOT" } def isRelease = sys.env.get("RELEASEBUILD").contains("yes")