2.9 KiB
Repository rules for implementation agents
Read README.md, docs/ARCHITECTURE.md, docs/CONTRACTS.md, your brief in docs/agents/README.md, and relevant platform/security documents before editing. Work only in assigned paths. Use one branch/worktree per agent. The user requests parallel development; an integrating engineer owns coordination and may delegate bounded work.
Shared ownership
The integrating engineer owns all Package.swift manifests, RemoteCore, Xcode project/schemes, Config, Scripts, AGENTS.md, root docs and integration composition. Propose a contract change with migration and test impact; do not silently edit shared types or fork duplicate types locally. New source/test files inside an existing Swift package target are automatically included and may be added by the owning feature agent. New targets/dependencies or directly compiled app-source membership require the integrator's generator changes. Do not regenerate the Xcode project from another agent's branch. Never switch a checkout used by another running agent; use a separate worktree.
Engineering rules
- Native SwiftUI, Swift 6 concurrency, platform APIs. Pure algorithms in the package; OS adapters outside it. UI state is main-actor isolated. Serialize TV commands in one actor.
- No third-party runtime dependencies without license/provenance and integration review. Never copy community Samsung library code into this proprietary foundation.
- No private Apple APIs, fabricated workouts/audio/VoIP sessions, or inappropriate extended runtime categories to keep the watch awake. No direct watch WebSocket transport.
- No auto-replay of remote commands. Reject stale, duplicated, wrong-session, wrong-TV and unsupported-schema messages at the receiver and check expiry again immediately before sending.
- No hardcoded real IP addresses, credentials, pairing tokens, private certs, Apple team IDs, or motion recordings. No blanket TLS trust bypass or silent plaintext fallback.
- Demo is visibly labelled. A write to a socket is not evidence that a TV performed the command. Never invent hardware test results.
- Wrist gestures are opt-in, foreground, calibrated and disarmed on lifecycle interruptions. Keep accessible touch controls. Power and purchase actions are not gesture commands in v1.
- Do not push to main, publish a release, change repository visibility, create the remote before owner name agreement, or alter signing/distribution settings on your own. Normal development and checks are authorized.
Handoff
Every PR supplies: concrete behavior, owned paths, tests run with results, hardware evidence or explicit untested status, permissions/privacy changes, source/license changes, integration steps, and unresolved risks. Follow .gitea/pull_request_template.md. Run the appropriate package tests; the integrator runs both app builds on the combined commit. Do not add tests that merely repeat presentation text.