From 75c9e959de44a942f00d80070f9e5921ca0e6883 Mon Sep 17 00:00:00 2001 From: XiangRongLin <41164160+XiangRongLin@users.noreply.github.com> Date: Sun, 12 Sep 2021 20:19:45 +0200 Subject: [PATCH] Allow passing in package suffix for release builds through CLI param --- app/build.gradle | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/build.gradle b/app/build.gradle index 1219aeb33..07d2752c9 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -54,6 +54,11 @@ android { // debug build. This seems to be a Gradle bug, therefore // TODO: update Gradle version release { + if (System.properties.containsKey('packageSuffix')) { + applicationIdSuffix System.getProperty('packageSuffix') + resValue "string", "app_name", "NewPipe " + System.getProperty('packageSuffix') + archivesBaseName = 'NewPipe_' + System.getProperty('packageSuffix') + } minifyEnabled true shrinkResources false // disabled to fix F-Droid's reproducible build proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'