Skip to content

Commit a4c3caa

Browse files
Ethan MatejaAlex Risch
authored andcommitted
TestFlight Release Configurations
XCode Cloud CI Scripts XCode Cloud CI Scripts Increment Build Increment Build Updated App Icon Fix Test Target Compiler Setting This SWIFT_VERSION was set to unspecified which throws an Xcode error when the project is opened. Changing this to the latest Major release version fixes the problem. Add .env for testflight Added ci prebuild for xcode cloud to create .env file Update prebuild file modifiers Added yarn install to prebuild Added temporary debug output for env testing Updated CI Prebuild Comment out temp debug output Updated Encryption Compliance Information Updated Bundle ID Update BundleID + Project Settings Increment TestFlight Build Update prebuild ci script Add ruby update to post clone Update Pre-Build Script Force brew to tap core Fix entitlements Update Bundle ID Restore app icon
1 parent 8c3e054 commit a4c3caa

File tree

13 files changed

+203
-18
lines changed

13 files changed

+203
-18
lines changed

.github/workflows/ios-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: Release to TestFlight
22
on:
33
push:
4-
branches:
5-
- main
4+
# branches:
5+
# - main
66

77
jobs:
88
rebase:

ios/EphemeraMobileChat.xcodeproj/project.pbxproj

Lines changed: 21 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
1515
331A34C09CDF74F0FC0CF2E9 /* ExpoModulesProvider.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A92300ADBC27B47A39B6CF1 /* ExpoModulesProvider.swift */; };
1616
42683F2D9EA5DDC49A85CEC0 /* ExpoModulesProvider.swift in Sources */ = {isa = PBXBuildFile; fileRef = 78611DF31EED3FF745D00249 /* ExpoModulesProvider.swift */; };
17+
638ED9512B7D419B009F369B /* Assests.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 638ED9502B7D419B009F369B /* Assests.xcassets */; };
1718
7699B88040F8A987B510C191 /* libPods-EphemeraMobileChat-EphemeraMobileChatTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 19F6CBCC0A4E27FBF8BF4A61 /* libPods-EphemeraMobileChat-EphemeraMobileChatTests.a */; };
1819
81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; };
1920
/* End PBXBuildFile section */
@@ -43,6 +44,8 @@
4344
5709B34CF0A7D63546082F79 /* Pods-EphemeraMobileChat.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-EphemeraMobileChat.release.xcconfig"; path = "Target Support Files/Pods-EphemeraMobileChat/Pods-EphemeraMobileChat.release.xcconfig"; sourceTree = "<group>"; };
4445
5B7EB9410499542E8C5724F5 /* Pods-EphemeraMobileChat-EphemeraMobileChatTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-EphemeraMobileChat-EphemeraMobileChatTests.debug.xcconfig"; path = "Target Support Files/Pods-EphemeraMobileChat-EphemeraMobileChatTests/Pods-EphemeraMobileChat-EphemeraMobileChatTests.debug.xcconfig"; sourceTree = "<group>"; };
4546
5DCACB8F33CDC322A6C60F78 /* libPods-EphemeraMobileChat.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-EphemeraMobileChat.a"; sourceTree = BUILT_PRODUCTS_DIR; };
47+
638ED9502B7D419B009F369B /* Assests.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Assests.xcassets; path = XmtpMobileChat/Assests.xcassets; sourceTree = "<group>"; };
48+
638ED9522B7D4755009F369B /* XmtpMobileChat.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; name = XmtpMobileChat.entitlements; path = XmtpMobileChat/XmtpMobileChat.entitlements; sourceTree = "<group>"; };
4649
78611DF31EED3FF745D00249 /* ExpoModulesProvider.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ExpoModulesProvider.swift; path = "Pods/Target Support Files/Pods-EphemeraMobileChat/ExpoModulesProvider.swift"; sourceTree = "<group>"; };
4750
81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = EphemeraMobileChat/LaunchScreen.storyboard; sourceTree = "<group>"; };
4851
89C6BE57DB24E9ADA2F236DE /* Pods-EphemeraMobileChat-EphemeraMobileChatTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-EphemeraMobileChat-EphemeraMobileChatTests.release.xcconfig"; path = "Target Support Files/Pods-EphemeraMobileChat-EphemeraMobileChatTests/Pods-EphemeraMobileChat-EphemeraMobileChatTests.release.xcconfig"; sourceTree = "<group>"; };
@@ -90,12 +93,14 @@
9093
13B07FAE1A68108700A75B9A /* EphemeraMobileChat */ = {
9194
isa = PBXGroup;
9295
children = (
96+
638ED9522B7D4755009F369B /* XmtpMobileChat.entitlements */,
9397
13B07FAF1A68108700A75B9A /* AppDelegate.h */,
9498
13B07FB01A68108700A75B9A /* AppDelegate.mm */,
9599
13B07FB51A68108700A75B9A /* Images.xcassets */,
96100
13B07FB61A68108700A75B9A /* Info.plist */,
97101
81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */,
98102
13B07FB71A68108700A75B9A /* main.m */,
103+
638ED9502B7D419B009F369B /* Assests.xcassets */,
99104
);
100105
name = EphemeraMobileChat;
101106
sourceTree = "<group>";
@@ -275,6 +280,7 @@
275280
files = (
276281
81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */,
277282
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
283+
638ED9512B7D419B009F369B /* Assests.xcassets in Resources */,
278284
);
279285
runOnlyForDeploymentPostprocessing = 0;
280286
};
@@ -504,6 +510,7 @@
504510
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_DEBUG";
505511
PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
506512
PRODUCT_NAME = "$(TARGET_NAME)";
513+
SWIFT_VERSION = 5.0;
507514
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/EphemeraMobileChat.app/EphemeraMobileChat";
508515
};
509516
name = Debug;
@@ -529,6 +536,7 @@
529536
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_RELEASE";
530537
PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
531538
PRODUCT_NAME = "$(TARGET_NAME)";
539+
SWIFT_VERSION = 5.0;
532540
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/EphemeraMobileChat.app/EphemeraMobileChat";
533541
};
534542
name = Release;
@@ -539,10 +547,12 @@
539547
buildSettings = {
540548
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
541549
CLANG_ENABLE_MODULES = YES;
542-
CURRENT_PROJECT_VERSION = 1;
543-
DEVELOPMENT_TEAM = QB5WFHTRW9;
550+
CODE_SIGN_ENTITLEMENTS = XmtpMobileChat/XmtpMobileChat.entitlements;
551+
CURRENT_PROJECT_VERSION = 20;
552+
DEVELOPMENT_TEAM = FY4NZR34Z3;
544553
ENABLE_BITCODE = NO;
545554
INFOPLIST_FILE = EphemeraMobileChat/Info.plist;
555+
INFOPLIST_KEY_CFBundleDisplayName = "XMTP Inbox";
546556
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
547557
LD_RUNPATH_SEARCH_PATHS = (
548558
"$(inherited)",
@@ -555,7 +565,7 @@
555565
"-lc++",
556566
);
557567
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_DEBUG";
558-
PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
568+
PRODUCT_BUNDLE_IDENTIFIER = com.xmtplabs.inbox.ios;
559569
PRODUCT_NAME = EphemeraMobileChat;
560570
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
561571
SWIFT_VERSION = 5.0;
@@ -569,9 +579,11 @@
569579
buildSettings = {
570580
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
571581
CLANG_ENABLE_MODULES = YES;
582+
CODE_SIGN_ENTITLEMENTS = EphemeraMobileChat/XmtpMobileChat.entitlements;
572583
CURRENT_PROJECT_VERSION = 1;
573-
DEVELOPMENT_TEAM = QB5WFHTRW9;
584+
DEVELOPMENT_TEAM = FY4NZR34Z3;
574585
INFOPLIST_FILE = EphemeraMobileChat/Info.plist;
586+
INFOPLIST_KEY_CFBundleDisplayName = "XMTP Inbox";
575587
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
576588
LD_RUNPATH_SEARCH_PATHS = (
577589
"$(inherited)",
@@ -584,7 +596,7 @@
584596
"-lc++",
585597
);
586598
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_RELEASE";
587-
PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
599+
PRODUCT_BUNDLE_IDENTIFIER = com.xmtplabs.inbox.ios;
588600
PRODUCT_NAME = EphemeraMobileChat;
589601
SWIFT_VERSION = 5.0;
590602
VERSIONING_SYSTEM = "apple-generic";
@@ -660,13 +672,10 @@
660672
"-DFOLLY_USE_LIBCPP=1",
661673
"-DFOLLY_CFG_NO_COROUTINES=1",
662674
);
663-
OTHER_LDFLAGS = (
664-
"$(inherited)",
665-
"-Wl",
666-
"-ld_classic",
667-
);
675+
OTHER_LDFLAGS = "$(inherited)";
668676
REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
669677
SDKROOT = iphoneos;
678+
SWIFT_VERSION = 5.0;
670679
USE_HERMES = true;
671680
};
672681
name = Debug;
@@ -732,13 +741,10 @@
732741
"-DFOLLY_USE_LIBCPP=1",
733742
"-DFOLLY_CFG_NO_COROUTINES=1",
734743
);
735-
OTHER_LDFLAGS = (
736-
"$(inherited)",
737-
"-Wl",
738-
"-ld_classic",
739-
);
744+
OTHER_LDFLAGS = "$(inherited)";
740745
REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
741746
SDKROOT = iphoneos;
747+
SWIFT_VERSION = 5.0;
742748
USE_HERMES = true;
743749
VALIDATE_PRODUCT = YES;
744750
};
Loading
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "App Icon.png",
5+
"idiom" : "universal",
6+
"platform" : "ios",
7+
"size" : "1024x1024"
8+
}
9+
],
10+
"info" : {
11+
"author" : "xcode",
12+
"version" : 1
13+
}
14+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"info" : {
3+
"author" : "xcode",
4+
"version" : 1
5+
}
6+
}

ios/EphemeraMobileChat/Info.plist

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131
</array>
3232
<key>CFBundleVersion</key>
3333
<string>$(CURRENT_PROJECT_VERSION)</string>
34+
<key>ITSAppUsesNonExemptEncryption</key>
35+
<false/>
3436
<key>LSRequiresIPhoneOS</key>
3537
<true/>
3638
<key>NSAppTransportSecurity</key>
@@ -40,8 +42,12 @@
4042
<key>NSAllowsLocalNetworking</key>
4143
<true/>
4244
</dict>
45+
<key>NSCameraUsageDescription</key>
46+
<string>This application uses the camer to enable QR code scanning.</string>
4347
<key>NSLocationWhenInUseUsageDescription</key>
4448
<string></string>
49+
<key>NSPhotoLibraryUsageDescription</key>
50+
<string>This application uses the photo library to enable saving QR codes captured via the camera.</string>
4551
<key>UILaunchStoryboardName</key>
4652
<string>LaunchScreen</string>
4753
<key>UIRequiredDeviceCapabilities</key>
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>aps-environment</key>
6+
<string>development</string>
7+
</dict>
8+
</plist>

ios/Podfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1669,7 +1669,7 @@ SPEC CHECKSUMS:
16691669
web3.swift: 2263d1e12e121b2c42ffb63a5a7beb1acaf33959
16701670
XMTP: 00fe090825e6bc5991870c1925befc06b1a30b78
16711671
XMTPReactNative: cf4227bf733870dc0331f3925cea852cafd43928
1672-
Yoga: 2a16e58450c48e110211dae1159fb114bbcdcfc0
1672+
Yoga: e5b887426cee15d2a326bdd34afc0282fc0486ad
16731673

16741674
PODFILE CHECKSUM: 605f5beea10db7b4d01fe2949787bef356832da3
16751675

Loading
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "App Icon.png",
5+
"idiom" : "universal",
6+
"platform" : "ios",
7+
"size" : "1024x1024"
8+
}
9+
],
10+
"info" : {
11+
"author" : "xcode",
12+
"version" : 1
13+
}
14+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"info" : {
3+
"author" : "xcode",
4+
"version" : 1
5+
}
6+
}

ios/ci_scripts/ci_pre_xcodebuild.sh

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
#!/bin/sh
2+
3+
# include helpers
4+
source retry.sh
5+
6+
echo "####===== Stage: PRE-Xcode Build is activated .... "
7+
8+
cat > ../../.env <<EOF
9+
XMTP_ENV=${XMTP_ENV}
10+
THRID_WEB_CLIENT_ID=${THRID_WEB_CLIENT_ID}
11+
AWS_S3_REGION=${AWS_S3_REGION}
12+
AWS_S3_BUCKET=${AWS_S3_BUCKET}
13+
AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID}
14+
AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY}
15+
EOF
16+
17+
# Debug output for ENV variables
18+
# Note: Values are encrypted in CI host.
19+
# Output will result as: XMTP_ENV=****
20+
# echo "####===== Temporary ENV Debug"
21+
# cat ../../.env
22+
23+
echo "###===== Installing Ruby"
24+
retry 5 brew install ruby
25+
26+
echo "###===== Add Ruby to PATH"
27+
if [[ -d "/opt/homebrew" ]]; then
28+
HOMEBREW_PREFIX="/opt/homebrew"
29+
else
30+
HOMEBREW_PREFIX="/usr/local"
31+
fi
32+
33+
echo "export PATH=\"$HOMEBREW_PREFIX/opt/ruby/bin:\$PATH\"" >> ~/.zshrc
34+
35+
echo "verify path:" $PATH
36+
37+
source ~/.zshrc
38+
39+
echo "###===== Verify Ruby installation"
40+
ruby -v
41+
42+
# Ensure the gem bin directory is in the PATH
43+
echo "export PATH=\"$(ruby -e 'puts Gem.user_dir')/bin:\$PATH\"" >> ~/.zshrc
44+
source ~/.zshrc
45+
46+
echo "###===== Install bundler"
47+
which gem
48+
gem install bundler:2.1.4 --user-install
49+
50+
echo "###===== Checking bundler version"
51+
which bundler
52+
53+
echo "###===== Source the updated .zshrc to apply changes in the current script"
54+
source ~/.zshrc
55+
56+
echo "###===== Verify bundler installation"
57+
bundler -v
58+
59+
echo "####===== Change working directory"
60+
cd ../../
61+
62+
echo "###===== Installing Node"
63+
retry 5 brew install node
64+
65+
echo "###===== Installing Yarn"
66+
npm install --global yarn
67+
68+
echo "####===== Run: yarn install"
69+
yarn install
70+
71+
#echo "####===== Run bundle install"
72+
# bundle install // bundle installs the wrong version of Flipper
73+
74+
echo "####===== brew tap Cocoapods 1.14.3"
75+
brew tap-new $USER/local-tap
76+
brew tap homebrew/core --force
77+
brew extract --version=1.14.3 cocoapods $USER/local-tap
78+
brew install cocoapods@1.14.3
79+
80+
echo "####===== Check Cocoapods versions"
81+
pod --version
82+
83+
echo "####===== Change directory and run pod install"
84+
cd ios
85+
pod install
86+
87+
#echo "####===== Run bundle exec pod install"
88+
#bundle exec pod install --project-directory=ios // bundle installs the wrong version of Flipper
89+
90+
exit 0

ios/ci_scripts/retry.sh

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Retry a command up to a specific number of times until it exits successfully,
2+
# with exponential backoff.
3+
#
4+
# $ retry 5 echo Hello
5+
# Hello
6+
#
7+
# $ retry 5 false
8+
# Retry 1/5 exited 1, retrying in 1 seconds...
9+
# Retry 2/5 exited 1, retrying in 2 seconds...
10+
# Retry 3/5 exited 1, retrying in 4 seconds...
11+
# Retry 4/5 exited 1, retrying in 8 seconds...
12+
# Retry 5/5 exited 1, no more retries left.
13+
#
14+
function retry {
15+
local retries=$1
16+
shift
17+
18+
local count=0
19+
until "$@"; do
20+
exit=$?
21+
# Enable this following line if the backoff feature is needed.
22+
# Default behavior is to wait 5 seconds
23+
# wait=$((2 ** $count))
24+
wait=$((5))
25+
count=$(($count + 1))
26+
if [ $count -lt $retries ]; then
27+
echo "Retry $count/$retries exited $exit, retrying in $wait seconds..."
28+
sleep $wait
29+
else
30+
echo "Retry $count/$retries exited $exit, no more retries left."
31+
return $exit
32+
fi
33+
done
34+
return 0
35+
}

0 commit comments

Comments
 (0)