搜狐做网站,wordpress 分页制作,做微商做什么网站比较好,校园网络方案设计该脚本会自动打包iios ipa 并自动上传#xff0c;中间自动flutter clean ,自动 pod install 里面需要填写自己应用的 apiKey和apiIssuer 如我的例子中apiKey 为 1234 apiIssuer 为5678#xff0c; 首先flutter 工程目录 新建 shell目录#xff0c;目录下新建ipa.sh文件…该脚本会自动打包iios ipa 并自动上传中间自动flutter clean ,自动 pod install 里面需要填写自己应用的 apiKey和apiIssuer 如我的例子中apiKey 为 1234 apiIssuer 为5678 首先flutter 工程目录 新建 shell目录目录下新建ipa.sh文件拷贝如下代码
#!/bin/bash
#### author: wds# description: # LastEditTime: 2024-09-04 17:42:02
### echo iOS 打包AppStore渠道包# Stop on errors
cd ..
set -e # Save current directory
current_dir$(pwd)# Clean the Flutter project
echo Cleaning Flutter project...
flutter clean# Get all the dependencies
echo Getting dependencies...
flutter pub get# Navigate to the iOS directory
echo Navigating to the iOS directory...if [ -d ios ]; thencd ios# Install CocoaPods dependenciesecho Installing CocoaPods dependencies...pod install# Go back to the original directorycd $current_direcho CocoaPods setup completed successfully.# Build the iOS appecho Building the iOS app...flutter build ipa --release --targetlib/main.dartecho iOS app build completed successfully.# 上传echo Upload ipa...xcrun altool --upload-app --type ios -f build/ios/ipa/*.ipa --apiKey 1234 --apiIssuer 5678echo Upload ipa successfully.elseecho Error: ios directory does not exist.exit 1
fi# Optional: Open the iOS project in Xcode (uncomment if needed)
# echo Opening iOS project in Xcode...
# open ios/Runner.xcworkspaceecho All tasks completed successfully.
运行
cd shell
执行 ./ipa.sh