1
0
mirror of https://github.com/etesync/android synced 2024-12-23 23:18:46 +00:00

Remove build time from app.

It was never needed, slows down development builds, and is annoying for
reproducible builds
This commit is contained in:
Tom Hacohen 2019-01-23 19:48:16 +00:00
parent 3c3cc961ff
commit 18a00716f8
4 changed files with 3 additions and 5 deletions

View File

@ -24,7 +24,6 @@ android {
versionCode 51 versionCode 51
versionName "1.0.1" versionName "1.0.1"
buildConfigField "long", "buildTime", System.currentTimeMillis() + "L"
buildConfigField "boolean", "customCerts", "true" buildConfigField "boolean", "customCerts", "true"
} }

View File

@ -33,8 +33,7 @@ object HttpClient {
private val userAgent: String private val userAgent: String
init { init {
val date = SimpleDateFormat("yyyy/MM/dd", Locale.US).format(Date(BuildConfig.buildTime)) userAgent = "${App.appName}/${BuildConfig.VERSION_NAME} (okhttp3) Android/${Build.VERSION.RELEASE}"
userAgent = "${App.appName}/${BuildConfig.VERSION_NAME} (${date}; okhttp3) Android/${Build.VERSION.RELEASE}"
} }
fun create(context: Context?, logger: Logger, host: String?, token: String): OkHttpClient { fun create(context: Context?, logger: Logger, host: String?, token: String): OkHttpClient {

View File

@ -159,7 +159,7 @@ class AboutActivity : BaseActivity() {
private val components = arrayOf(ComponentInfo( private val components = arrayOf(ComponentInfo(
App.appName, BuildConfig.VERSION_NAME, Constants.webUri.toString(), App.appName, BuildConfig.VERSION_NAME, Constants.webUri.toString(),
DateFormatUtils.format(BuildConfig.buildTime, "yyyy") + " Tom Hacohen", "Tom Hacohen",
R.string.about_license_info_no_warranty, "gpl-3.0-standalone.html" R.string.about_license_info_no_warranty, "gpl-3.0-standalone.html"
), ComponentInfo( ), ComponentInfo(
"DAVdroid", "(forked from)", "https://syncadapter.bitfire.at", "DAVdroid", "(forked from)", "https://syncadapter.bitfire.at",

View File

@ -141,7 +141,7 @@ class DebugInfoActivity : BaseActivity(), LoaderManager.LoaderCallbacks<String>
var installedFrom = pm.getInstallerPackageName(BuildConfig.APPLICATION_ID) var installedFrom = pm.getInstallerPackageName(BuildConfig.APPLICATION_ID)
if (TextUtils.isEmpty(installedFrom)) if (TextUtils.isEmpty(installedFrom))
installedFrom = "APK (directly)" installedFrom = "APK (directly)"
report.append("\nSOFTWARE INFORMATION\n" + "EteSync version: ").append(BuildConfig.VERSION_NAME).append(" (").append(BuildConfig.VERSION_CODE).append(") ").append(Date(BuildConfig.buildTime)).append("\n") report.append("\nSOFTWARE INFORMATION\n" + "EteSync version: ").append(BuildConfig.VERSION_NAME).append(" (").append(BuildConfig.VERSION_CODE).append(") ").append("\n")
.append("Installed from: ").append(installedFrom).append("\n") .append("Installed from: ").append(installedFrom).append("\n")
} catch (ex: Exception) { } catch (ex: Exception) {
App.log.log(Level.SEVERE, "Couldn't get software information", ex) App.log.log(Level.SEVERE, "Couldn't get software information", ex)