Skip to content

Instantly share code, notes, and snippets.

@AlexV525
Created August 17, 2020 03:37
Show Gist options
  • Select an option

  • Save AlexV525/8260ea04c22c866a48592f02ab2571fb to your computer and use it in GitHub Desktop.

Select an option

Save AlexV525/8260ea04c22c866a48592f02ab2571fb to your computer and use it in GitHub Desktop.
Flutter iOS build/archive without BitCode
# Build
flutter build ios
cd build/ios/iphoneos/Runner.app/Frameworks
cd App.framework
xcrun bitcode_strip -r app -o app
cd ..
cd Flutter.framework
xcrun bitcode_strip -r Flutter -o Flutter
cd ../../../../../../
# Archive
flutter build ios
rm -rf build/export
mkdir -p build/export
cd build/ios/iphoneos/Runner.app/Frameworks
cd App.framework
xcrun bitcode_strip -r app -o app
cd ..
cd Flutter.framework
xcrun bitcode_strip -r Flutter -o Flutter
cd ../../../../../../ios
xcodebuild -workspace Runner.xcworkspace -scheme Runner -sdk iphoneos -configuration Release archive -archivePath $PWD/build/Runner.xcarchive
xcodebuild -exportArchive -archivePath $PWD/build/Runner.xcarchive -exportOptionsPlist ExportOptions.plist -exportPath $PWD/build/Runner.ipa -allowProvisioningUpdates
cd ..
cp ios/build/Runner.ipa/Runner.ipa build/export
open build/export
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment