feat(ai): subscription-first commit message suggestions#17
Merged
Conversation
Wire Codex CLI and Claude Code CLI for AI-generated commit messages from staged diffs. Adds Settings → AI sign-in, CommitBar Suggest button, and ⌘⇧M / palette action. Auth stays in vendor CLIs; Strand orchestrates subprocess calls and parses JSON responses. Co-authored-by: Daniels <danielss-dev@users.noreply.github.com>
CI runs `cargo clippy -- -D warnings`, which promoted the `redundant_closure` lint to a hard error at 6 call sites wrapping the zero-arg `not_installed()` in a needless closure. Pass the function directly to `ok_or_else`; behavior is unchanged. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
While a commit-message suggestion is generating, swap the sparkle icon for a spinning refresh icon and mark the button aria-busy. Keep the disabled button fully visible and accented with a progress cursor so the spinner reads as "working" rather than an inert, greyed-out control, and update the tooltip to reflect the in-progress state.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds AI-generated commit message suggestions from staged changes, using subscriptions developers already pay for instead of separate API keys.
codex login/codex exec, read-only sandbox)claude auth login/claude -p, tools disabled)UI
Backend
crates/strand-tauri/src/ai/module (prompt builder, JSON parse, CLI subprocess runners)ai_provider_status,ai_provider_login,ai_provider_logout,repo_suggest_commit_messageVerification
cargo test -p strand-tauri(9 unit tests)cargo check -p strand-core -p strand-tauripnpm --filter ./ui exec tsc --noEmitDocs
docs/learnings.md— vendor CLI delegation policyManual test