From 80eec270b3738eb175f541489d51a0f4292e359c Mon Sep 17 00:00:00 2001 From: azarz Date: Tue, 14 Nov 2023 10:53:18 +0100 Subject: [PATCH] add android deploy --- android/app/build.gradle | 6 +++--- capacitor.config.json | 8 +++++++- deploiement-appli-mobile.md | 3 +++ 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/android/app/build.gradle b/android/app/build.gradle index 5864f987..aad8f4eb 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -1,13 +1,13 @@ apply plugin: 'com.android.application' android { - namespace "geoportail.app" + namespace "fr.ign.geoportail" compileSdkVersion rootProject.ext.compileSdkVersion defaultConfig { - applicationId "geoportail.app" + applicationId "fr.ign.geoportail" minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion - versionCode 1 + versionCode 3 versionName "1.0" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" aaptOptions { diff --git a/capacitor.config.json b/capacitor.config.json index 2397706a..2180d31c 100644 --- a/capacitor.config.json +++ b/capacitor.config.json @@ -1,8 +1,14 @@ { - "appId": "geoportail.app", + "appId": "fr.ign.geoportail", "appName": "geoportail-app", "webDir": "www", "server": { "androidScheme": "https" + }, + "android": { + "overrideUserAgent": "IGN-app-android" + }, + "ios": { + "overrideUserAgent": "IGN-app-ios" } } diff --git a/deploiement-appli-mobile.md b/deploiement-appli-mobile.md index 979e2a3c..a9658376 100644 --- a/deploiement-appli-mobile.md +++ b/deploiement-appli-mobile.md @@ -8,6 +8,9 @@ ## Capacitor - `npm run build` - `npx cap sync` +- `npx cap build --keystorepath "c:/Users/amaur/Downloads/ign.keystore" --keystorepass "G3oportail" --keystorealias "geoportail_mobile" --keystorealiaspass "G3oportail" --androidreleasetype "APK" android` +- `zipalign 4 ./android/app/build/outputs/apk/release/app-release-signed.apk ./android/app/build/outputs/apk/release/app-release-aligned.apk` +- `apksigner sign --ks //ign.keystore --v1-signing-enabled true --v2-signing-enabled true ./android/app/build/outputs/apk/release/app-release-aligned.apk` ## Android