Add Kiro CLI as third coding agent with hooks and CLI skill (#245)
* Add Kiro CLI as third coding agent with hooks and CLI skill
- KiroHookSettings: progress (userPromptSubmit/stop) and notification (stop) payloads in Kiro's flat format
- KiroHookSettingsFileInstaller: thin wrapper for Kiro's flat hook JSON format
- KiroSettingsInstaller: targets ~/.kiro/agents/kiro_default.json, creates default agent config when absent
- KiroSettingsClient: TCA dependency for install/uninstall/check
- AgentHookSlot: add .kiroProgress/.kiroNotifications
- SkillAgent: add .kiro
- SettingsFeature: wire Kiro hook checks, install/uninstall, skill install
- CLISkillContent: add Kiro skill (SKILL.md with frontmatter)
- AgentHookPayload: decode assistant_response for Kiro stop events
- DeveloperSettingsView: add Kiro section with progress, notifications, CLI skill rows
- kiro-mark asset from kiro.dev/icon.svg
* Address PR #245 review comments
- Move KiroSettingsClient to SupacodeSettingsShared/Clients/CodingAgents/ with public access
- Collapse Kiro section in DeveloperSettingsView (isExpanded: false by default)
- Update KiroSettingsInstaller comment with Kiro version (1.x, 2026-04)
- Remove KiroHookPayloadSupport; reuse AgentHookPayloadSupport.extractHookGroups
- Add tests: KiroSettingsInstallerTests, KiroHookSettingsFileInstallerTests
- Extend SettingsFeatureAgentHookTests with kiro hook install/uninstall cases
- Update taskChecksAllFourHookSlotsOnStartup → All Six (includes kiro slots)
- Update receiveStartupHookChecks to assert kiro{Progress,Notifications,Skill}State
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* Address PR feedback: assistant_response tests, full config assertions, fix skill:// URIs
- Add decode test for Kiro's assistant_response fallback field
- Add precedence test (message > lastAssistantMessage > assistantResponse)
- Assert full JSON config contents in KiroSettingsInstallerTests (name,
tools, useLegacyMcpJson, resources, hooks) instead of just fileExists
- Fix firstWrite/secondWrite comparison in does-not-overwrite test
- Fix skill:// URIs to use ~/ prefix for home-directory resolution
(skill://.kiro/... is project-relative, skill://~/.kiro/... is global)
* Add nil-body warning log + uninstall-only-matching test
- Log warning when all notification body fields are nil so field
renames surface in make log-stream instead of silently delivering
empty notifications
- Add comment explaining the body fallback chain across agents
- Add uninstallRemovesOnlyMatchingCommands test for Kiro's flat hook
format, matching the existing Claude/Codex grouped-format coverage
* Harden Kiro version gate, hook file installer, and body decoder
- KiroSettingsInstaller: gate `ensureDefaultAgentConfig` on a version probe
(`kiro --version` via login shell) so future Kiro releases cannot be silently
overridden by our hardcoded defaults; 5s watchdog + `process.terminate()` on
hang; concurrent stdout/stderr drain to avoid pipe-buffer deadlock; parse
stdout before stderr; log non-UTF8 output; differentiate 127 vs. other
non-zero exits; `isSupportedVersion` compares the first dot-delimited
component so `10.x` is rejected.
- KiroHookSettingsFileInstaller: throw `invalidHooksObject` when existing
`"hooks"` is non-nil but not a JSON object (previously silently overwrote
user data); drop WHAT-narration comment.
- KiroHookSettings: extract `defaultTimeoutMs`; `KiroHookEntry` init guards
empty command / non-positive timeout via `assertionFailure` + `max(1, _)`.
- AgentHookSocketServer: collapse `message` / `last_assistant_message` /
`assistant_response` into a single `body` via custom `init(from:)`; each
field decoded through a tolerant helper that logs on type mismatch; skip
empty strings so an empty Claude `message` still yields to Codex/Kiro
fallbacks.
- CLISkillContent: document `-c` script UUID flag + `worktree run/stop/script
list` in `kiroSkillMd`.
- Tests: error paths (malformed JSON, array root, non-object hooks,
non-array event, legacy pruning), version-gate matrix (missing binary,
command-throw, unsupported version, unparseable output, 10.x rejection,
stderr-banner precedence, file-exists short-circuit), and body-decoder
edge cases (null, empty string, type mismatch, all-precedence chains).
---------
Co-authored-by: Benjamin <1159333+benjaminburzan@users.noreply.github.com>
Co-authored-by: Stefano Bertagno <stefano@bertagno.com>
authored by