From ffec862333b032b9db4bda446c51f1e8b07249a6 Mon Sep 17 00:00:00 2001 From: Aashish Dhakal <85501584+dhakalaashish@users.noreply.github.com> Date: Wed, 28 Feb 2024 17:09:11 +0545 Subject: [PATCH 1/6] Fixes .apk build Fixes react-native-auth0 v3 build error update ios podfile Configure APK build keys --- apps/nativeapp/android/app/build.gradle | 6 +++--- apps/nativeapp/android/gradle.properties | 5 +++++ apps/nativeapp/ios/Podfile | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/apps/nativeapp/android/app/build.gradle b/apps/nativeapp/android/app/build.gradle index 874ef12a1..591a3dcfb 100644 --- a/apps/nativeapp/android/app/build.gradle +++ b/apps/nativeapp/android/app/build.gradle @@ -2,7 +2,7 @@ apply plugin: "com.android.application" apply plugin: "com.facebook.react" project.ext.envConfigFiles = [ staging : ".env.staging", - release: ".env.production", + release: ".env", develop : ".env", ] apply from: project(':react-native-config').projectDir.getPath() + "/dotenv.gradle" @@ -114,7 +114,7 @@ android { targetSdkVersion rootProject.ext.targetSdkVersion versionCode 4 versionName "1.2" - manifestPlaceholders = [auth0Domain: "@string/AUTH0_DOMAIN", auth0Scheme: "${applicationId}"] + manifestPlaceholders = [auth0Domain: "accounts.plant-for-the-planet.org", auth0Scheme: "${applicationId}.auth0"] } splits { @@ -154,7 +154,7 @@ android { } } flavorDimensions "env" - + productFlavors { staging { dimension "env" diff --git a/apps/nativeapp/android/gradle.properties b/apps/nativeapp/android/gradle.properties index e4af465e8..0ab34c21d 100644 --- a/apps/nativeapp/android/gradle.properties +++ b/apps/nativeapp/android/gradle.properties @@ -39,6 +39,11 @@ reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64 # are providing them. newArchEnabled=false +MYAPP_RELEASE_STORE_FILE=my-release-key.keystore +MYAPP_RELEASE_KEY_ALIAS=my-key-alias +MYAPP_RELEASE_STORE_PASSWORD=fire-alert +MYAPP_RELEASE_KEY_PASSWORD=fire-alert + # Use this property to enable or disable the Hermes JS engine. # If set to false, you will be using JSC instead. hermesEnabled=true diff --git a/apps/nativeapp/ios/Podfile b/apps/nativeapp/ios/Podfile index d9e88aa5e..02eb9904e 100644 --- a/apps/nativeapp/ios/Podfile +++ b/apps/nativeapp/ios/Podfile @@ -4,7 +4,7 @@ require_relative '../../../node_modules/react-native/scripts/react_native_pods' require_relative '../../../node_modules/@react-native-community/cli-platform-ios/native_modules' $RNMapboxMapsImpl = 'mapbox' -platform :ios, min_ios_version_supported +platform :ios, '13.0' prepare_react_native_project! # If you are using a `react-native-flipper` your iOS build will fail when `NO_FLIPPER=1` is set. From 91369600e07f20bd59b675840a8c9b2383599272 Mon Sep 17 00:00:00 2001 From: shyambhongle Date: Mon, 4 Mar 2024 08:26:33 +0530 Subject: [PATCH 2/6] Updated podfile.lock for new auth0 version --- apps/nativeapp/ios/Podfile.lock | 38 ++++++++++++++++----------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/apps/nativeapp/ios/Podfile.lock b/apps/nativeapp/ios/Podfile.lock index d3842228f..ca9e7d578 100644 --- a/apps/nativeapp/ios/Podfile.lock +++ b/apps/nativeapp/ios/Podfile.lock @@ -1,12 +1,12 @@ PODS: - - A0Auth0 (2.17.4): - - Auth0 (= 2.3.2) - - JWTDecode (= 3.0.1) + - A0Auth0 (3.1.0): + - Auth0 (= 2.5.0) + - JWTDecode (= 3.1.0) - React-Core - - SimpleKeychain (= 1.0.1) - - Auth0 (2.3.2): - - JWTDecode (~> 3.0) - - SimpleKeychain (~> 1.0) + - SimpleKeychain (= 1.1.0) + - Auth0 (2.5.0): + - JWTDecode (~> 3.1) + - SimpleKeychain (~> 1.1) - boost (1.76.0) - BVLinearGradient (2.7.3): - React-Core @@ -82,7 +82,7 @@ PODS: - FlipperKit/FlipperKitNetworkPlugin - fmt (6.2.1) - glog (0.3.5) - - JWTDecode (3.0.1) + - JWTDecode (3.1.0) - libevent (2.1.12) - lottie-ios (4.2.0) - lottie-react-native (6.0.0-rc.7): @@ -441,11 +441,11 @@ PODS: - React-RCTImage - RNSVG (13.9.0): - React-Core - - SimpleKeychain (1.0.1) - - SocketRocket (0.6.0) + - SimpleKeychain (1.1.0) + - SocketRocket (0.6.1) - SRSRadialGradient (1.1.2): - React - - Turf (2.6.1) + - Turf (2.8.0) - Yoga (1.14.0) - YogaKit (1.18.1): - Yoga (~> 1.14) @@ -661,8 +661,8 @@ EXTERNAL SOURCES: :path: "../../../node_modules/react-native/ReactCommon/yoga" SPEC CHECKSUMS: - A0Auth0: 5ae918d2f043395f83ac26d6eb85b249bcb54634 - Auth0: 64da28fdc5cd499aa516dc4bfd0ace8efae2c1da + A0Auth0: d6fa13c9daf99f5fb17a412837ea37f8db38a562 + Auth0: 72f19ad566fdf57f07bf37f828afd0c1570769a5 boost: 57d2868c099736d80fcd648bf211b4431e51a558 BVLinearGradient: fbe308a1d19a8133f69e033abc85d8008644f5e3 CocoaAsyncSocket: 065fd1e645c7abab64f7a6a2007a48038fdc6a99 @@ -680,7 +680,7 @@ SPEC CHECKSUMS: FlipperKit: 0674bb0e923016a5296838ae2aa9a10e7efc6b91 fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9 glog: 04b94705f318337d7ead9e6d17c019bd9b1f6b1b - JWTDecode: 2eed97c2fa46ccaf3049a787004eedf0be474a87 + JWTDecode: 3eaab1e06b6f4dcbdd6716aff09ba4c2104ca8b7 libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913 lottie-ios: 809ecf2d460ed650a6aed7aa88b2ec45fab4779c lottie-react-native: a7341509cbc0bf01dff9889d1f7e17e8e745cf9e @@ -731,13 +731,13 @@ SPEC CHECKSUMS: rnmapbox-maps: 3e48c433d2165dbb5cf277f277d58a4c50bbbd05 RNScreens: 68fd1060f57dd1023880bf4c05d74784b5392789 RNSVG: 53c661b76829783cdaf9b7a57258f3d3b4c28315 - SimpleKeychain: 130211269f88f038d7dc5254cf0b1b9ce978c398 - SocketRocket: fccef3f9c5cedea1353a9ef6ada904fde10d6608 + SimpleKeychain: f8707c8e97b38c6a6e687b17732afc9bcef06439 + SocketRocket: f32cd54efbe0f095c4d7594881e52619cfe80b17 SRSRadialGradient: f88dfa41215854bfb721dfe926bd9bf09338a602 - Turf: 469ce2c3d22e5e8e4818d5a3b254699a5c89efa4 + Turf: aa2ede4298009639d10db36aba1a7ebaad072a5e Yoga: 921eb014669cf9c718ada68b08d362517d564e0c YogaKit: f782866e155069a2cca2517aafea43200b01fd5a -PODFILE CHECKSUM: 11ec416dbddd07f960bbf1f1bf517643b1a8ff2c +PODFILE CHECKSUM: 2c09c5ee0bf38237d63fc2449d3005d3ddf9b654 -COCOAPODS: 1.11.3 +COCOAPODS: 1.14.3 From 8673680a13abb36929d2b5364ed28bb4e55edd80 Mon Sep 17 00:00:00 2001 From: shyambhongle Date: Mon, 4 Mar 2024 08:27:31 +0530 Subject: [PATCH 3/6] Android auth0 schema fix --- apps/nativeapp/android/app/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/nativeapp/android/app/build.gradle b/apps/nativeapp/android/app/build.gradle index 591a3dcfb..be9f2ccdf 100644 --- a/apps/nativeapp/android/app/build.gradle +++ b/apps/nativeapp/android/app/build.gradle @@ -114,7 +114,7 @@ android { targetSdkVersion rootProject.ext.targetSdkVersion versionCode 4 versionName "1.2" - manifestPlaceholders = [auth0Domain: "accounts.plant-for-the-planet.org", auth0Scheme: "${applicationId}.auth0"] + manifestPlaceholders = [auth0Domain: "accounts.plant-for-the-planet.org", auth0Scheme: "${applicationId}"] } splits { From acb8c4998c87a34d3a00825eb414ff8fa71cbc51 Mon Sep 17 00:00:00 2001 From: Aashish Dhakal <85501584+dhakalaashish@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:55:41 +0545 Subject: [PATCH 4/6] Add auth0_domain in strings.xml and use .env.production --- apps/nativeapp/android/app/build.gradle | 4 ++-- apps/nativeapp/android/app/src/debug/res/values/strings.xml | 6 ++++++ apps/nativeapp/android/app/src/main/res/values/strings.xml | 3 +++ .../release/java/eco/pp/firealert/res/values/strings.xml | 6 ++++++ 4 files changed, 17 insertions(+), 2 deletions(-) create mode 100644 apps/nativeapp/android/app/src/debug/res/values/strings.xml create mode 100644 apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml diff --git a/apps/nativeapp/android/app/build.gradle b/apps/nativeapp/android/app/build.gradle index be9f2ccdf..edb7e926d 100644 --- a/apps/nativeapp/android/app/build.gradle +++ b/apps/nativeapp/android/app/build.gradle @@ -2,7 +2,7 @@ apply plugin: "com.android.application" apply plugin: "com.facebook.react" project.ext.envConfigFiles = [ staging : ".env.staging", - release: ".env", + release: ".env.production", develop : ".env", ] apply from: project(':react-native-config').projectDir.getPath() + "/dotenv.gradle" @@ -114,7 +114,7 @@ android { targetSdkVersion rootProject.ext.targetSdkVersion versionCode 4 versionName "1.2" - manifestPlaceholders = [auth0Domain: "accounts.plant-for-the-planet.org", auth0Scheme: "${applicationId}"] + manifestPlaceholders = [auth0Domain: "@string/AUTH0_DOMAIN", auth0Scheme: "${applicationId}"] } splits { diff --git a/apps/nativeapp/android/app/src/debug/res/values/strings.xml b/apps/nativeapp/android/app/src/debug/res/values/strings.xml new file mode 100644 index 000000000..b2d2b13ed --- /dev/null +++ b/apps/nativeapp/android/app/src/debug/res/values/strings.xml @@ -0,0 +1,6 @@ + + + FireAlert + + accounts.plant-for-the-planet.org + diff --git a/apps/nativeapp/android/app/src/main/res/values/strings.xml b/apps/nativeapp/android/app/src/main/res/values/strings.xml index 635bc5097..b2d2b13ed 100644 --- a/apps/nativeapp/android/app/src/main/res/values/strings.xml +++ b/apps/nativeapp/android/app/src/main/res/values/strings.xml @@ -1,3 +1,6 @@ + FireAlert + + accounts.plant-for-the-planet.org diff --git a/apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml b/apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml new file mode 100644 index 000000000..b2d2b13ed --- /dev/null +++ b/apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml @@ -0,0 +1,6 @@ + + + FireAlert + + accounts.plant-for-the-planet.org + From 21e1ceed682b724c347297913c7d2971f259f645 Mon Sep 17 00:00:00 2001 From: Aashish Dhakal <85501584+dhakalaashish@users.noreply.github.com> Date: Mon, 4 Mar 2024 15:08:58 +0545 Subject: [PATCH 5/6] Remove AUTH0_DOMAIN from strings.xml --- apps/nativeapp/android/app/src/debug/res/values/strings.xml | 2 -- apps/nativeapp/android/app/src/main/res/values/strings.xml | 2 -- .../src/release/java/eco/pp/firealert/res/values/strings.xml | 2 -- 3 files changed, 6 deletions(-) diff --git a/apps/nativeapp/android/app/src/debug/res/values/strings.xml b/apps/nativeapp/android/app/src/debug/res/values/strings.xml index b2d2b13ed..1d69c1551 100644 --- a/apps/nativeapp/android/app/src/debug/res/values/strings.xml +++ b/apps/nativeapp/android/app/src/debug/res/values/strings.xml @@ -1,6 +1,4 @@ FireAlert - - accounts.plant-for-the-planet.org diff --git a/apps/nativeapp/android/app/src/main/res/values/strings.xml b/apps/nativeapp/android/app/src/main/res/values/strings.xml index b2d2b13ed..1d69c1551 100644 --- a/apps/nativeapp/android/app/src/main/res/values/strings.xml +++ b/apps/nativeapp/android/app/src/main/res/values/strings.xml @@ -1,6 +1,4 @@ FireAlert - - accounts.plant-for-the-planet.org diff --git a/apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml b/apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml index b2d2b13ed..1d69c1551 100644 --- a/apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml +++ b/apps/nativeapp/android/app/src/release/java/eco/pp/firealert/res/values/strings.xml @@ -1,6 +1,4 @@ FireAlert - - accounts.plant-for-the-planet.org From 51c049e82b5da95c5014f2fb194a479d6df88553 Mon Sep 17 00:00:00 2001 From: Aashish Dhakal <85501584+dhakalaashish@users.noreply.github.com> Date: Mon, 4 Mar 2024 15:57:38 +0545 Subject: [PATCH 6/6] Update build.gradle --- apps/nativeapp/android/app/build.gradle | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/nativeapp/android/app/build.gradle b/apps/nativeapp/android/app/build.gradle index edb7e926d..5e89252c7 100644 --- a/apps/nativeapp/android/app/build.gradle +++ b/apps/nativeapp/android/app/build.gradle @@ -112,8 +112,8 @@ android { multiDexEnabled true minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion - versionCode 4 - versionName "1.2" + versionCode 6 + versionName "1.3" manifestPlaceholders = [auth0Domain: "@string/AUTH0_DOMAIN", auth0Scheme: "${applicationId}"] }