Merge branch 'fdroid-add-release-signature' into 'master'
Add a release signature for fdroid apks See merge request ChristianPauly/fluffychat-flutter!1
This commit is contained in:
commit
ac0c411b7a
4
.gitignore
vendored
4
.gitignore
vendored
@ -36,3 +36,7 @@ lib/generated_plugin_registrant.dart
|
||||
|
||||
# Exceptions to above rules.
|
||||
!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
|
||||
|
||||
|
||||
/key.jks
|
||||
/android/key.properties
|
@ -28,9 +28,14 @@ build_web:
|
||||
- build/web/
|
||||
|
||||
|
||||
build_android:
|
||||
build_android_fdroid:
|
||||
stage: coverage
|
||||
script:
|
||||
- cd android && echo $FDROID_KEY | base64 --decode --ignore-garbage > key.jks && cd ..
|
||||
- cd android && echo "storePassword=${FDROID_KEY_PASS}" >> key.properties && cd ..
|
||||
- cd android && echo "keyPassword=${FDROID_KEY_PASS}" >> key.properties && cd ..
|
||||
- cd android && echo "keyAlias=key" >> key.properties && cd ..
|
||||
- cd android && echo "storeFile=../key.jks" >> key.properties && cd ..
|
||||
- flutter build apk --release
|
||||
artifacts:
|
||||
when: on_success
|
||||
|
@ -25,6 +25,12 @@ apply plugin: 'com.android.application'
|
||||
apply plugin: 'kotlin-android'
|
||||
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
|
||||
|
||||
def keystoreProperties = new Properties()
|
||||
def keystorePropertiesFile = rootProject.file('key.properties')
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdkVersion 28
|
||||
|
||||
@ -37,7 +43,6 @@ android {
|
||||
}
|
||||
|
||||
defaultConfig {
|
||||
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
|
||||
applicationId "chat.fluffy.fluffychat"
|
||||
minSdkVersion 16
|
||||
targetSdkVersion 28
|
||||
@ -46,11 +51,21 @@ android {
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
keyAlias keystoreProperties['keyAlias']
|
||||
keyPassword keystoreProperties['keyPassword']
|
||||
storeFile file(keystoreProperties['storeFile'])
|
||||
storePassword keystoreProperties['storePassword']
|
||||
}
|
||||
}
|
||||
buildTypes {
|
||||
release {
|
||||
// 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
|
||||
minifyEnabled true
|
||||
useProguard true
|
||||
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -8,7 +8,7 @@
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<application
|
||||
android:name="io.flutter.app.FlutterApplication"
|
||||
android:label="fluffychat"
|
||||
android:label="FluffyChat"
|
||||
android:icon="@mipmap/launcher_icon">
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
|
8
android/proguard-rules.pro
vendored
Normal file
8
android/proguard-rules.pro
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
## Flutter wrapper
|
||||
-keep class io.flutter.app.** { *; }
|
||||
-keep class io.flutter.plugin.** { *; }
|
||||
-keep class io.flutter.util.** { *; }
|
||||
-keep class io.flutter.view.** { *; }
|
||||
-keep class io.flutter.** { *; }
|
||||
-keep class io.flutter.plugins.** { *; }
|
||||
-dontwarn io.flutter.embedding.**
|
Loading…
Reference in New Issue
Block a user