[tor-commits] [Git][tpo/applications/fenix][tor-browser-81.1.1-10.0-1] 2 commits: Bug 40067: Fix reproducibility issue in classes2.dex

Matthew Finkel gitlab at torproject.org
Thu Oct 1 18:08:00 UTC 2020



Matthew Finkel pushed to branch tor-browser-81.1.1-10.0-1 at The Tor Project / Applications / fenix


Commits:
f18271e0 by Georg Koppen at 2020-10-01T17:46:09+00:00
Bug 40067: Fix reproducibility issue in classes2.dex

We make sure our MOZ_BUILD_DATE gets used as a source for showing date
related information on the Fenix about page.

- - - - -
9dfb59c8 by Matthew Finkel at 2020-10-01T18:07:25+00:00
Merge remote-tracking branch 'gkgl/bug_40067' into tor-browser-81.1.1-10.0-1

- - - - -


1 changed file:

- buildSrc/src/main/java/Config.kt


Changes:

=====================================
buildSrc/src/main/java/Config.kt
=====================================
@@ -38,7 +38,14 @@ object Config {
 
     @JvmStatic
     fun generateBuildDate(): String {
-        val dateTime = LocalDateTime.now()
+        val dateTime = if (System.getenv("MOZ_BUILD_DATE") != null) {
+          // Converting our MOZ_BUILD_DATE to LocalDateTime
+          val format = SimpleDateFormat("YYYYMMDDHHMMSS", Locale.US)
+          val date = format.parse(System.getenv("MOZ_BUILD_DATE"))
+          java.sql.Timestamp(date.getTime()).toLocalDateTime()
+        } else {
+          LocalDateTime.now()
+        }
         val timeFormatter = DateTimeFormatter.ofPattern("h:mm a")
 
         return "${dateTime.dayOfWeek.toString().toLowerCase().capitalize()} ${dateTime.monthValue}/${dateTime.dayOfMonth} @ ${timeFormatter.format(dateTime)}"



View it on GitLab: https://gitlab.torproject.org/tpo/applications/fenix/-/compare/ee0aa80246802b1ed3cd9474b676d74c88bcadf0...9dfb59c8e703ef7319d3536031a590aae74d6c6e

-- 
View it on GitLab: https://gitlab.torproject.org/tpo/applications/fenix/-/compare/ee0aa80246802b1ed3cd9474b676d74c88bcadf0...9dfb59c8e703ef7319d3536031a590aae74d6c6e
You're receiving this email because of your account on gitlab.torproject.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.torproject.org/pipermail/tor-commits/attachments/20201001/76d87d0a/attachment-0001.htm>


More information about the tor-commits mailing list