From 23ab172d81e414562f63a640a93670b9495a1e11 Mon Sep 17 00:00:00 2001 From: "Dawid Wyrkowski (Dawqss)" Date: Wed, 23 Oct 2024 15:54:52 +0200 Subject: [PATCH 1/5] chore(): trigger PR --- App.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/App.tsx b/App.tsx index 416e3a5..d40c517 100644 --- a/App.tsx +++ b/App.tsx @@ -1,6 +1,10 @@ import React, { ReactElement } from 'react'; import { MainRouterNavigation } from './app/navigation/MainRouter.tsx'; +/** + * This is main app point + * @constructor + */ function App(): ReactElement { return ; } From a81a29a485e4e4e56575bcf5e1c5c231a48ff04f Mon Sep 17 00:00:00 2001 From: "Dawid Wyrkowski (Dawqss)" Date: Wed, 23 Oct 2024 16:51:09 +0200 Subject: [PATCH 2/5] feat(): get build number from test flight and update it --- ios/Gemfile.lock | 2 +- ios/fastlane/Appfile | 8 +++---- ios/fastlane/Fastfile | 53 +++++++++++++++++++++++++++--------------- ios/fastlane/Matchfile | 2 ++ 4 files changed, 41 insertions(+), 24 deletions(-) diff --git a/ios/Gemfile.lock b/ios/Gemfile.lock index 41266b9..1739457 100644 --- a/ios/Gemfile.lock +++ b/ios/Gemfile.lock @@ -212,7 +212,7 @@ PLATFORMS DEPENDENCIES dotenv - fastlane + fastlane (~> 2.224.0) BUNDLED WITH 2.5.3 diff --git a/ios/fastlane/Appfile b/ios/fastlane/Appfile index 723b6e0..f8b27c1 100644 --- a/ios/fastlane/Appfile +++ b/ios/fastlane/Appfile @@ -3,7 +3,7 @@ #For more information about the Appfile, see: #https://docs.fastlane.tools/advanced/#appfile -team_name "Dawid Wyrkowski" -team_id "5G4M55X26F" -itc_team_name "Dawid Wyrkowski" -itc_team_id "127349639" +team_name ENV["TEAM_NAME"] +team_id ENV["TEAM_ID"] +itc_team_name ENV["ITC_TEAM_NAME"] +itc_team_id ENV["ITC_TEAM_ID"] diff --git a/ios/fastlane/Fastfile b/ios/fastlane/Fastfile index 85db692..d387f13 100644 --- a/ios/fastlane/Fastfile +++ b/ios/fastlane/Fastfile @@ -1,4 +1,8 @@ GIT_AUTHORIZATION = ENV["GIT_AUTHORIZATION"] +KEY_ID = ENV["APP_STORE_CONNECT_API_KEY_KEY_ID"] +ISSUER_ID = ENV["APP_STORE_CONNECT_API_KEY_ISSUER_ID"] +KEY_CONTENT = ENV["APP_STORE_CONNECT_API_KEY_KEY"] +APP_IDENTIFIER = ENV["APPLE_APP_IDENTIFIER"] default_platform(:ios) @@ -7,7 +11,7 @@ platform :ios do lane :certificates do sync_code_signing( type: "appstore", - app_identifier: "com.dawidcompany.simpleweatherapp", + app_identifier: APP_IDENTIFIER, git_basic_authorization: Base64.strict_encode64(GIT_AUTHORIZATION), force_for_new_devices: true, readonly: true @@ -19,7 +23,7 @@ platform :ios do lane :generate_new_certificates do sync_code_signing( type: "appstore", - app_identifier: "com.dawidcompany.simpleweatherapp", + app_identifier: APP_IDENTIFIER, git_basic_authorization: Base64.strict_encode64(GIT_AUTHORIZATION), force_for_new_devices: true, readonly: false @@ -28,24 +32,35 @@ platform :ios do end desc "deploy" - lane :deploy do - setup_ci + lane :deploy do + setup_ci + api_key = app_store_connect_api_key( + key_id: KEY_ID, + issuer_id: ISSUER_ID, + key_content: KEY_CONTENT, + is_key_content_base64: true + ) + build_num = app_store_build_number( + live: false, + api_key: api_key, + app_identifier: APP_IDENTIFIER + ) - increment_build_number(xcodeproj: "CkOnboardinApp.xcodeproj", build_number: latest_testflight_build_number + 1) + increment_build_number(xcodeproj: "CkOnboardinApp.xcodeproj", build_number: build_num + 1) - sync_code_signing( - type: "appstore", - app_identifier: 'com.dawidcompany.simpleweatherapp', - git_basic_authorization: Base64.strict_encode64(GIT_AUTHORIZATION), - force_for_new_devices: true, - readonly: true - ) + sync_code_signing( + type: "appstore", + app_identifier: APP_IDENTIFIER, + git_basic_authorization: Base64.strict_encode64(GIT_AUTHORIZATION), + force_for_new_devices: true, + readonly: true + ) - build_app(scheme: "CkOnboardinApp") - app_store_connect_api_key( - is_key_content_base64: true, - in_house: false, - ) - upload_to_testflight() - end + build_app(scheme: "CkOnboardinApp") + app_store_connect_api_key( + is_key_content_base64: true, + in_house: false, + ) + upload_to_testflight() + end end diff --git a/ios/fastlane/Matchfile b/ios/fastlane/Matchfile index 4f6c46d..a05c104 100644 --- a/ios/fastlane/Matchfile +++ b/ios/fastlane/Matchfile @@ -1,4 +1,6 @@ git_url("https://github.com/Dawqss/FastlaneCerts.git") +#git@github.com:Dawqss/FastlaneCerts.git +#https://github.com/Dawqss/FastlaneCerts.git storage_mode("git") From e1553c103387e56403dfd109265579797e28131b Mon Sep 17 00:00:00 2001 From: "Dawid Wyrkowski (Dawqss)" Date: Wed, 23 Oct 2024 16:59:46 +0200 Subject: [PATCH 3/5] chore(): trigger build --- App.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/App.tsx b/App.tsx index d40c517..c3611ab 100644 --- a/App.tsx +++ b/App.tsx @@ -3,6 +3,7 @@ import { MainRouterNavigation } from './app/navigation/MainRouter.tsx'; /** * This is main app point + * r * @constructor */ function App(): ReactElement { From 00e457ea521814288a0b9dbda3f7181e332775e5 Mon Sep 17 00:00:00 2001 From: "Dawid Wyrkowski (Dawqss)" Date: Wed, 23 Oct 2024 17:03:26 +0200 Subject: [PATCH 4/5] chore(): pass envs from CI --- .github/workflows/check-build-deploy-to-test-users.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/check-build-deploy-to-test-users.yml b/.github/workflows/check-build-deploy-to-test-users.yml index f42ec93..021f96c 100644 --- a/.github/workflows/check-build-deploy-to-test-users.yml +++ b/.github/workflows/check-build-deploy-to-test-users.yml @@ -61,3 +61,8 @@ jobs: APP_STORE_CONNECT_API_KEY_ISSUER_ID: ${{ secrets.APP_STORE_CONNECT_API_KEY_ISSUER_ID }} APP_STORE_CONNECT_API_KEY_KEY: ${{ secrets.APP_STORE_CONNECT_API_KEY_KEY }} GIT_AUTHORIZATION: ${{ secrets.GIT_AUTHORIZATION }} + APPLE_APP_IDENTIFIER: ${{ secrets.APPLE_APP_IDENTIFIER }} + TEAM_NAME: ${{ secrets.TEAM_NAME }} + TEAM_ID: ${{ secrets.TEAM_ID }} + ITC_TEAM_NAME: ${{ secrets.ITC_TEAM_NAME }} + ITC_TEAM_ID: ${{ secrets.ITC_TEAM_ID }} From a5c6962f0ee2a332a679079f29641d3a3d770e2f Mon Sep 17 00:00:00 2001 From: "Dawid Wyrkowski (Dawqss)" Date: Wed, 23 Oct 2024 17:22:54 +0200 Subject: [PATCH 5/5] chore(): unlock ci actions --- .github/workflows/check-build-deploy-to-test-users.yml | 6 +++--- .github/workflows/ci-pipeline.yml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/check-build-deploy-to-test-users.yml b/.github/workflows/check-build-deploy-to-test-users.yml index 021f96c..7e2f68e 100644 --- a/.github/workflows/check-build-deploy-to-test-users.yml +++ b/.github/workflows/check-build-deploy-to-test-users.yml @@ -4,12 +4,12 @@ on: pull_request: branches: - master -# types: -# - closed + types: + - closed jobs: tsc: -# if: github.event.pull_request.merged == true + if: github.event.pull_request.merged == true runs-on: ubuntu-latest steps: - name: Checkout code diff --git a/.github/workflows/ci-pipeline.yml b/.github/workflows/ci-pipeline.yml index 7491e14..d978703 100644 --- a/.github/workflows/ci-pipeline.yml +++ b/.github/workflows/ci-pipeline.yml @@ -3,7 +3,7 @@ name: CI Pipeline on: pull_request: branches: - - masterDontUseMe + - master jobs: tsc: