Skip to content

Commit

Permalink
build.gradle: Setup release build signing
Browse files Browse the repository at this point in the history
  • Loading branch information
sashko9807 committed Aug 5, 2023
1 parent fda14a1 commit e379305
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apply plugin: "com.android.application"

import com.android.build.OutputFile
import org.apache.tools.ant.taskdefs.condition.Os
import groovy.swing.SwingBuilder

/**
* The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets
Expand Down Expand Up @@ -238,6 +239,15 @@ android {
keyAlias 'androiddebugkey'
keyPassword 'android'
}
release {
if(project.hasProperty('BEACONMS_RELEASE_STORE_FILE')) {

storeFile file(BEACONMS_RELEASE_STORE_FILE)
storePassword BEACONMS_RELEASE_STORE_PASSWORD
keyAlias BEACONMS_RELEASE_KEY_ALIAS
keyPassword BEACONMS_RELEASE_KEY_PASSWORD
}
}
}
buildTypes {
debug {
Expand All @@ -246,7 +256,7 @@ android {
release {
// Caution! In production, you need to generate your own keystore file.
// see https://reactnative.dev/docs/signed-apk-android.
signingConfig signingConfigs.debug
signingConfig signingConfigs.release
minifyEnabled enableProguardInReleaseBuilds
proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
}
Expand Down

0 comments on commit e379305

Please sign in to comment.