From a7587f1d5046e1a4cc05bbe15adfe5834b22484e Mon Sep 17 00:00:00 2001 From: Aji Anaz Date: Sat, 13 Jun 2026 22:15:30 +0700 Subject: [PATCH] =?UTF-8?q?docs:=20pre-release=20sync=20=E2=80=94=20cora?= =?UTF-8?q?=20commit=20across=20all=20docs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - docs/changelog.md: sync [Unreleased] from root CHANGELOG.md - docs/roadmap.md: add #262 to v0.5 section (✓ Done) - docs/getting-started.md: add Daily Workflow section with cora commit - docs/examples.md: new section 06 — Auto-Commit (HITL/YOLO/no-review/force) - AGENT.md: fix test count 506→517 in pre-release checklist --- .gitignore | 1 + AGENT.md | 2 +- docs/changelog.md | 15 +++++++++++++++ docs/examples.md | 37 +++++++++++++++++++++++++++++++++++++ docs/getting-started.md | 15 +++++++++++++++ docs/roadmap.md | 1 + 6 files changed, 70 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index f7638aaa..8bb96b58 100644 --- a/.gitignore +++ b/.gitignore @@ -43,3 +43,4 @@ coverage/ dist/ *.tar.gz *.zip +.cora/history/ diff --git a/AGENT.md b/AGENT.md index 68b8375b..24817d79 100644 --- a/AGENT.md +++ b/AGENT.md @@ -234,7 +234,7 @@ Missing any = release blocker. ### 1. Code - [ ] All target issues merged to `develop` -- [ ] `cargo test` — all 506+ tests pass +- [ ] `cargo test` — all 517+ tests pass - [ ] `cargo clippy --all-targets -- -D warnings` — clean - [ ] `cargo fmt --all -- --check` — clean - [ ] `cargo build --release` — no errors diff --git a/docs/changelog.md b/docs/changelog.md index 95c26f4a..1491d2f6 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -7,6 +7,21 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Added + +- **`cora commit`** — review staged diff + generate commit message + commit (#262) + - HITL mode (default): interactive `[Y]es / [E]dit / [N]o` prompt + - YOLO mode (`--yolo`): auto-commit without prompts + - `--force`: commit even if quality gate fails + - `--no-review`: skip review, only generate commit message + - `--edit`: always open `$EDITOR` + - Conventional commit format (feat/fix/refactor/perf/docs/test/chore/style/build/ci) + - Auto-truncates subjects to 72 chars + - Quality gate integration (block on FAIL unless `--force`) + - Debt snapshot saved after commit + - `chat_completion_raw()` + `chat_completion_stream_raw()` in `engine/llm.rs` + - 22 unit tests + ## [0.5.0] - 2026-06-10 ### Added diff --git a/docs/examples.md b/docs/examples.md index ce6f02de..cb5ccfcf 100644 --- a/docs/examples.md +++ b/docs/examples.md @@ -50,6 +50,43 @@ Stream results as they come in from the LLM. $ cora review --staged --stream ``` +## 06 — Auto-Commit (Review + Message + Commit) + +Review staged changes, generate a conventional commit message, and commit in one step. + +### HITL mode (default — interactive prompt) + +```bash +$ git add -A +$ cora commit +🔍 Reviewing staged changes (3 files, 247 lines)... +✅ No issues found (quality score: 9.2/10) + +📝 Generated commit message: + feat(auth): add session expiry validation + +Accept commit message? [Y]es / [E]dit / [N]o › y +✅ Committed: feat(auth): add session expiry validation +``` + +### YOLO mode (CI / trusted workflows) + +```bash +$ cora commit --yolo +``` + +### Skip review (message only) + +```bash +$ cora commit --no-review +``` + +### Force commit past quality gate + +```bash +$ cora commit --force +``` + ## 06 — GitHub Actions CI (Recommended) The easiest way to add cora to your PR workflow. This reusable action installs cora, runs the review, posts a PR comment with findings, and optionally uploads SARIF to GitHub Code Scanning. diff --git a/docs/getting-started.md b/docs/getting-started.md index 998f782a..e1161650 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -135,6 +135,21 @@ Now that you have cora running, explore these topics to get the most out of it: - [CLI Reference](./cli-reference) — full command documentation - [Examples](./examples) — CI/CD setup for GitHub, GitLab, Gitea, Bitbucket +### Daily Workflow + +Once set up, your daily workflow becomes: + +```bash +git add -A +cora commit # review + generate commit message + commit +``` + +Or skip the prompt in CI/trusted workflows: + +```bash +cora commit --yolo # auto-commit, no prompts +``` + ## AI Agent Integration cora includes a built-in MCP server for AI coding agents. After installation: diff --git a/docs/roadmap.md b/docs/roadmap.md index e0985485..34a03b39 100644 --- a/docs/roadmap.md +++ b/docs/roadmap.md @@ -73,6 +73,7 @@ Demand-gated — we build what people actually need. Track progress on [GitHub I - [#188](https://github.com/codecoradev/cora-cli/issues/188) Auto-chunking for large diffs — ✓ Done - [#206](https://github.com/codecoradev/cora-cli/issues/206) Tech debt metrics — review history — ✓ Done - [#232](https://github.com/codecoradev/cora-cli/issues/232) Uteke memory integration — recall + learn — ✓ Done +- [#262](https://github.com/codecoradev/cora-cli/issues/262) `cora commit` — review + auto commit message + quality gate — ✓ Done ## v0.6 — Growth & Marketplace