Find any article in my blog

In this blog I talk about all things Apple and Swift development but my main area of focus is on tooling and automation.

Building a Swift package using the Swift 6 language mode

How to download and install a development version of the Swift 6 compiler and enable the Swift 6 language mode when building your Swift package.

How to profile your app's performance and Main Thread usage with Instruments and os_signposts

Learn how to use Instruments to understand the root cause of app hangs and high Main Thread usage and identify areas where you can optimize your app's performance.

Safely unwrap optional values in SwiftUI bindings

How to use one of SwiftUI's Binding's initializers to safely unwrap its optional value.

Creating an App Store Connect-like picker for macOS with SwiftUI

Learn how to use SwiftUI components such as Menus and Buttons and modifiers like onHover and overlay to create a picker component for macOS similar to the beta group picker in App Store Connect's TestFlight.

Swift 6: Access level on import statements

How to get ready for Swift 6's new import access level feature and make sure that you are not caught by surprise by the breaking changes that come with it.

Use Swift to recursively search for content in a directory's files with Glob patterns and Regular Expressions

How to find content specified by a Regular Expression in a directory's set of files defined by a Glob pattern using Swift.

Master the reduce operator in Swift and make your code more performant

Learn all about Sequence's reduce operator in Swift through a series of real-world examples.

Multi-platform Swift Package releases with GitHub Actions

How to automatically create and release a multi-platform Swift Package library with GitHub Actions whenever you push a new tag.

Generate and read analytics reports from the App Store Connect API

Apple has recently introduced over 50 new analytics reports to help developers understand how their apps are performing. These are only available through the App Store Connect API and in this post, I'll show you how to generate and read them.

Core Data staged migrations

As announced in WWDC23, and very similarly to the way you perform migrations across Swift Data models, you can now define Core Data migrations programmatically using an NSStagedMigrationManager instance.This method works by defining a series of migration steps (called stages) that describe how to migrate across different versions of your model.

How to generate Swift interfaces from Pkl configuration files using SPM plugins

Pkl (pronounced Pickle) is a new programming language from Apple designed specifically for configuration. It allows developers to design data models richly and expressively through the use of types and then validate them to catch errors early on. A feature that sets it apart for Apple developers and, as it couldn't be any other way with Pkl being an Apple language, is that it has a suite of tools available for generating Swift interfaces from `.pkl` configuration files.

Validate your XCTest utilities and extensions with unit tests

Make sure no regressions occur in your custom XCTestCase extensions and helper methods with unit tests and XCTExpectFailure.