🥷 Migrating workflows from TeamCity to Xcode Cloud ☁️
Welcome to the 18th issue of the iOS Coffee Break Newsletter 📬.
Last week, I have been migrating our CI/CD pipelines from TeamCity to Xcode Cloud. Xcode Cloud is a Continuous Integration and Continuous Delivery (CI/CD) platform provided by Apple. It automates away the hard work of building your apps, testing them, signing them, and pushing them to a destination.
With all project external dependencies now managed through SPM, the transition to Xcode Cloud was seamless. I had just encountered some few minor issues, but they were quickly resolved.
Workflow 1: Changes to the main branch
The first workflow was set up to run unit tests on every push to the main branch and on pull requests (PRs) targeting main. Additionally, it alerts the team once all tests pass, confirming it is safe to merge into main.
Workflow 2: Releases
The second workflow migration triggers on every push to the release/XXX/qa
branch, archiving the app and distributing it to TestFlight for external testing.
To keep versioning clear, we append the version number to the branch name, formatted as release/XXX/qa/Y.Y.Y
.
A similar workflow was also created for archiving and uploading to production.
The
XXX
indicates the client brand but can be replaced by any identifier that makes sense for your project setup.
I am currently focused on migrating the remaining workflows and looking for ways to extend the existing ones. Wish me luck 🤞!
Now it's time to dive into some iOS development topics submitted by the community. Here are this week's highlighted resources. Hope you enjoy 🙌.
🛠️ A Different Approach Using the Swift Argument Parser
Using Swift Argument Parser is quite intuitive, but sometimes you might need added flexibility for custom output or workflows.
In this post by Swift Toolkit, Natan explores advanced techniques like custom output styles and flows with protocol-driven commands. If you are into tooling and scripting, all using the Swift programming language, Swift Toolkit is the website you should bookmark!
🕶 Improve your app's UX with SwiftUI's task view modifier
SwiftUI's .task
modifier acts as an asynchronous combination of .onAppear
and .onDisappear
, starting a task when a view appears and canceling it if the view exits first.
Recently, Peter needed to add a delay before running specific code and created a reusable DelayTaskViewModifier
, inspired by Combine's functionality.
This modifier allows tasks to run after a short delay, enhancing control within SwiftUI workflows.
🚫 Nitpicking during code review is just a waste of time. Invest in tooling instead.
Nitpicking can be subjective and often leads to unnecessary debates that sidetrack higher-impact issues. The true is that the line between necessary changes and nitpicking can be blurry!
Christopher suggests that nitpicking often stems from gaps in tools, automation, and conventions — a point I fully agree with! The key is to replace nitpicking with effective tooling.
For those interested in streamlining their review process, this article offers practical recommendations on tools to support your team and keep feedback productive!
Nitpicking stands as the finding or pointing out of minor faults in a fussy or pedantic way.