Mac Catalyst Migration

Date: 2024-12-12

Summary

Converted from separate iOS + macOS targets to a single iOS app with Mac Catalyst support.

Changes

Project Configuration

  • Removed TimeTracker-macOS target from project.yml
  • Renamed TimeTracker-iOS to TimeTracker
  • Added SUPPORTS_MACCATALYST: YES build setting
  • Single scheme runs on iOS devices/simulators and “My Mac (Mac Catalyst)”

Code Changes

  • Removed all #if os(macOS) / #if os(iOS) conditionals
  • Unified UI - single NavigationStack with List-based sections
  • iOS-style navigation (NavigationStack, sheets)
  • Removed AppKit/NSWorkspace references

Benefits

  • Single codebase, no platform conditionals
  • Identical UI on iPhone, iPad, and Mac
  • Simpler maintenance
  • Uses UIKit on Mac via Catalyst

Running the App

open TimeTracker/TimeTracker.xcodeproj
# Select destination:
# - iPhone/iPad simulator
# - iOS device
# - My Mac (Mac Catalyst)

Related