Iterable / swift-sdk

Iterable's iOS SDK. Receive and track pushes to Iterable from your iOS app.
https://iterable.com/
MIT License
86 stars 67 forks source link

[MOB-7322] automate ios sdk release with fastlane #701

Closed jyu115 closed 6 months ago

jyu115 commented 7 months ago

🔹 Jira Ticket(s)

Description

Implemented https://fastlane.tools/ to automate iOS SDK release. Also uses a fastlane plugin create_xcframework.

Steps to release in the new process:

  1. Update CHANGELOG.md
  2. Update new version number for sdkVersion variable in IterableAPI.swift
  3. Push CHANGELOG.md and IterableAPI.swift changes to the branch
  4. Run: fastlane ios release_sdk It will prompt you to enter release version number (e.g. 6.5.0-beta) and output directory (e.g. build2)

That's it! When release_sdk lane is run, it will run these lanes in subsequent order:

  1. bump_release_version
  2. clean_and_lint
  3. build_xcframework
  4. tag_version
  5. pod_trunk_push

Github release created with assets uploaded:

Finished success status:

Screen Shot 2023-11-29 at 1 46 31 PM

See available lanes:

Screen Shot 2023-11-29 at 2 38 46 PM
Ayyanchira commented 7 months ago

So from Step 1 to Step 3 will be on a separate branch -> which will be reviewed by the team. Once the branch is merged into master, thats when we run fastlane ios release_sdk right? Does it also take care of uploading the zip files? Or will that need to be uploaded from build folder to tags?

jyu115 commented 6 months ago

So from Step 1 to Step 3 will be on a separate branch -> which will be reviewed by the team. Once the branch is merged into master, thats when we run fastlane ios release_sdk right? Does it also take care of uploading the zip files? Or will that need to be uploaded from build folder to tags?

Yes I think the best process would be: 1) Step 1 to Step 3 on a separate branch and merge to master. 2) Run a github actions workflow -- this takes care of uploading zip files and creating a release