78 test functions across 5 test files: - FrameCodecTests.swift (24): BinaryFrame.decode, ClientToServer encoding, ServerToClient decoding, round-trip — full IC-1 field name verification - ResumeCursorTests.swift (12): save/load, overwrite, UInt64.max, clear, multi-session isolation — each test uses isolated UserDefaults suite - PairingTests.swift (18): parseQR happy-path, missing params, wrong scheme, missing port, error type assertions - KeychainTests.swift (7): round-trip SidecarCredential, upsert, notFound, delete, production key guard, generic Codable - ThemeTests.swift (17): ansiColors count, color range, dark≠github, SwiftTerm conversion, ThemeStore select, Codable round-trip Review notes: Tests/CoreTests/REVIEW_NOTES.md - feat/p2-t2-2-pairing branch was EMPTY; Auth/Pairing code on t2-3-terminal - IC-1 compliance: all JSON field names correct including 'awaiting-input' - Minor: Keychain.encodingFailed used for decode failure (misleading name) - Merge order: t2-1 → t2-3 → t2-2 (empty) → p2-tests |
||
|---|---|---|
| Sources/App | ||
| Tests/CoreTests | ||
| piRemote.xcodeproj | ||
| .gitignore | ||
| README.md | ||
| project.yml | ||
README.md
pi-remote iOS
Native iOS app for the pi-remote-control sidecar.
Requirements
- Xcode 16.4+
- iOS 17.0+ device
- pi-remote-control sidecar running (Phase 1)
Building
# Open in Xcode (first time: Xcode downloads device support files automatically)
open piRemote.xcodeproj
# Or via CLI (after first Xcode open with device connected):
xcodebuild build -project piRemote.xcodeproj -scheme piRemote \
-destination "platform=iOS,name=<YourPhone>" \
CODE_SIGNING_STYLE=Automatic DEVELOPMENT_TEAM=KNXX8R3648
Project structure
Sources/
├── App/ — @main entry, ContentView, Assets
├── Core/
│ ├── Network/ — WebSocketClient, FrameCodec, ResumeCursor, TLS pinning
│ ├── Auth/ — Keychain, Pairing (QR exchange)
│ ├── Sessions/ — SessionRegistry, SessionConnection, PreConnectPool
│ ├── Push/ — APNs NotificationDelegate, DeviceTokenRegistrar
│ └── Persistence/ — ScrollbackCache, Preferences
└── UI/
├── Terminal/ — SwiftTerm wrapper, themes, fonts
├── Input/ — ModifierBar, sticky Ctrl, paste sheet
├── Status/ — StatusBar (pi state)
├── Sessions/ — SessionSwitcher
├── Pairing/ — QR scanner flow
└── Settings/ — Face-ID gate, sidecar info
Dependencies (via SPM)
- SwiftTerm — terminal emulator
- Starscream — WebSocket client
Apple Developer setup (one-time)
- In Apple Developer Portal:
- Create App ID:
de.vpsj.pi-remote, enable Push Notifications - Generate an APNs Auth Key (
.p8) — download once, keep safe - Note your Key ID and Team ID (
KNXX8R3648)
- Create App ID:
- Copy
.p8key to~/.local/share/pi-remote/apns/AuthKey_<KeyID>.p8 - Update
[apns]section in pi-remote-control config
Status
Phase 2 — in development. See pi-remote-control/docs/PHASE-2-ios-mvp.md.