chore: release configuration

This commit is contained in:
Matyáš Caras 2023-04-03 19:13:37 +02:00
parent 2214eb68e7
commit afb921c153
3 changed files with 21 additions and 9 deletions

View file

@ -21,6 +21,12 @@ if (flutterVersionName == null) {
flutterVersionName = '1.0' flutterVersionName = '1.0'
} }
def keystoreProperties = new Properties()
def keystorePropertiesFile = rootProject.file('key.properties')
if (keystorePropertiesFile.exists()) {
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
}
apply plugin: 'com.android.application' apply plugin: 'com.android.application'
apply plugin: 'kotlin-android' apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
@ -43,7 +49,6 @@ android {
} }
defaultConfig { defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "cafe.caras.voyagehandbook" applicationId "cafe.caras.voyagehandbook"
// You can update the following values to match your application needs. // 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. // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
@ -53,13 +58,19 @@ android {
versionName flutterVersionName versionName flutterVersionName
} }
buildTypes { signingConfigs {
release { release {
// TODO: Add your own signing config for the release build. keyAlias keystoreProperties['keyAlias']
// Signing with the debug keys for now, so `flutter run --release` works. keyPassword keystoreProperties['keyPassword']
signingConfig signingConfigs.debug storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
} storePassword keystoreProperties['storePassword']
} }
}
buildTypes {
release {
signingConfig signingConfigs.release
}
}
} }
flutter { flutter {

View file

@ -1,5 +1,6 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android" <manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="cafe.caras.voyagehandbook"> package="cafe.caras.voyagehandbook">
<uses-permission android:name="android.permission.INTERNET"/>
<application <application
android:label="Voyage Handbook" android:label="Voyage Handbook"
android:name="${applicationName}" android:name="${applicationName}"

View file

@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts # In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix. # of the product and file versions while build-number is used as the build suffix.
version: 1.0.0+1 version: 1.0.0-alpha.1+1
environment: environment:
sdk: '>=2.19.4 <3.0.0' sdk: '>=2.19.4 <3.0.0'