workflows:
ios-project-debug: # Workflow ID
name: iOS Debug # Workflow name
environment:
xcode: latest
cocoapods: default
vars:
BUNDLE_ID: "com.example.id" # replace with your app bundle
XCODE_PROJECT: "App.xcodeproj" # Replace with your xcodeproj name
XCODE_SCHEME: "App" # Replace with your project name
ios_signing:
distribution_type: app_store # or: ad_hoc | development | enterprise
bundle_identifier: com.example.id # replace with your app bundle
scripts:
- name: Run tests
script: |
xcodebuild \
-project "$XCODE_PROJECT" \
-scheme "$XCODE_SCHEME" \
-sdk iphonesimulator \
-destination 'platform=iOS Simulator,name=iPhone 14,OS=16.2' \
clean build test CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
- name: Build debug app
script: |
xcodebuild build -project "$XCODE_PROJECT" \
-scheme "$XCODE_SCHEME" \
CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO - name: Build ipa for distribution
- name: Increment build number
script: |
#!/bin/sh
cd $CM_BUILD_DIR
LATEST_BUILD_NUMBER=$(app-store-connect get-latest-app-store-build-number "$APP_STORE_APPLE_ID")
agvtool new-version -all $(($LATEST_BUILD_NUMBER + 1))
- name: Build ipa for distribution
script: |
xcode-project build-ipa \
--workspace "$CM_BUILD_DIR/$XCODE_WORKSPACE" \
--scheme "$XCODE_SCHEME"
artifacts:
- build/ios/ipa
Build*.app
- $HOME/Library/Developer/Xcode/DerivedDataBuild*.dSYM
publishing:
email:
recipients:
- username@mail.com # Replace with your email
notify:
success: true
failure: true