Skip to content

cronxco/spark-ios

Repository files navigation

Spark iOS

The native iOS companion app for Spark. Phase 1 delivers the app skeleton, OAuth round-trip, and a read-only Today view backed by stale-while-revalidate against /api/v1/mobile/briefing/today.

Requirements

  • Xcode 26.0 (or Xcode 26 beta at /Applications/Xcode-beta.app)
  • macOS 15+
  • tuist 4.x — brew install tuist
  • A Sanctum-backed Spark backend running on spark.cronx.co (or a LAN address you expose via App Group defaults — see Environment overrides below)

First-time setup

git clone [email protected]:willscottuk/spark-ios.git
cd spark-ios
tuist generate

tuist generate creates Spark.xcworkspace. Open it in Xcode 26.

Provisioning

Every target uses the William Scott development team declared in Project.swift, and shares the App Group group.co.cronx.sparkapp, the Keychain access group $(AppIdentifierPrefix)co.cronx.spark, and the associated domain applinks:spark.cronx.co.

After tuist generate, Xcode should keep the team selection automatically. The App Group, Keychain Sharing, Associated Domains, Push Notifications, and HealthKit capabilities are already declared in the generated targets.

Environment overrides

The default build points at https://spark.cronx.co. To swap in a local Sail instance, write two strings into the shared App Group UserDefaults (e.g. from a debug build):

let defaults = UserDefaults(suiteName: "group.co.cronx.spark")!
defaults.set("http://192.168.1.42:8000/api/v1/mobile", forKey: "spark.env.baseURL")
defaults.set("http://192.168.1.42:8000/oauth/authorize", forKey: "spark.env.oauthURL")
defaults.set("lan", forKey: "spark.env.name")

Erase the keys to restore production.

Running

# Tests — SparkKit SPM layer
cd Packages/SparkKit && swift test

# Tests — full app (requires iOS 26 simulator)
xcodebuild \
    -workspace Spark.xcworkspace \
    -scheme SparkApp \
    -destination 'platform=iOS Simulator,name=iPhone 17 Pro,OS=26.4.1' \
    -skipPackagePluginValidation \
    -skipMacroValidation \
    test

In Xcode: select the SparkApp scheme + an iOS 26 simulator + ⌘R.

Layout

SparkApp/         # @main app target
Extensions/       # Widgets, Controls, LiveActivities, Share, Intents, NotificationService stubs
Watch/            # Phase 5 watchOS stubs
Packages/
  SparkKit/       # Domain, networking, persistence, OAuth, deep-links
  SparkUI/        # Theme tokens + Liquid Glass components
  SparkSync/      # (empty — Phase 3)
  SparkIntelligence/
  SparkHealth/
  SparkLocation/
Tests/            # Cross-target app tests

Release

Versioning follows gitmoji on the commit subject. CI (.github/workflows/ios.yml) runs xcodebuild test on every push to main / dev and every PR. Phase 1 ships as tag v0.1.0-phase1 to internal TestFlight.

Sentry

Crash + performance telemetry uses the Sentry project cronx/spark-ios. DSN is committed (project-scoped, not a secret); upload auth token is read from SENTRY_AUTH_TOKEN at release time. See .sentryclirc.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages