diff --git a/wallpaper/android/app/build.gradle b/wallpaper/android/app/build.gradle index 08c356b..7b153a8 100644 --- a/wallpaper/android/app/build.gradle +++ b/wallpaper/android/app/build.gradle @@ -22,8 +22,12 @@ if (flutterVersionName == null) { flutterVersionName = '1.0' } +def keystorePropertiesFile = rootProject.file("key.properties") +def keystoreProperties = new Properties() +keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) + android { - namespace "com.lux.wallpapertoday" + namespace "com.example.wallpaper" compileSdk flutter.compileSdkVersion ndkVersion flutter.ndkVersion @@ -42,7 +46,7 @@ android { defaultConfig { // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). - applicationId "com.example.wallpaper" + applicationId "com.lux.wallpapertoday" // You can update the following values to match your application needs. // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration. minSdkVersion flutter.minSdkVersion @@ -51,11 +55,27 @@ android { versionName flutterVersionName } - buildTypes { + signingConfigs { release { + keyAlias keystoreProperties['keyAlias'] + keyPassword keystoreProperties['keyPassword'] + storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null + storePassword keystoreProperties['storePassword'] + } + } + + buildTypes { + debug { + signingConfig signingConfigs.release + } + + release { + ndk{ + abiFilters "armeabi", "armeabi-v7a", "arm64-v8a" + } // TODO: Add your own signing config for the release build. // Signing with the debug keys for now, so `flutter run --release` works. - signingConfig signingConfigs.debug + signingConfig signingConfigs.release } } }