kodevu
v0.1.51
Published
Poll SVN revisions or Git commits, send each change diff to a reviewer CLI, and write configurable review reports.
Downloads
4,562
Readme
Kodevu
A Node.js tool that fetches Git commits or SVN revisions, sends the diff to a supported AI reviewer CLI, and writes review results to report files.
Pure & Zero Config
Kodevu is designed to be stateless and requires no configuration files. It relies entirely on command-line arguments and environment variables.
- Automatic Detection: Detects repository type (Git/SVN), language, and available reviewers.
- Stateless: Does not track history; reviews exactly what you ask for.
- Flexible: Every setting can be overridden via CLI flags or ENV vars.
Quick Start
Get a review of your latest commit in seconds:
npx kodevu .Review reports are saved to ~/.kodevu/ by default.
Usage
npx kodevu [target] [options]Options
target: Repository path (Git) or SVN URL/Working copy (default:.).--reviewer, -r:codex,gemini,copilot,openai, orauto(default:auto).--rev, -v: A specific revision or commit hash to review.--last, -n: Number of latest revisions to review (default: 1). Use negative values (e.g.,-3) to review only the 3rd commit from the top.--lang, -l: Output language (e.g.,zh,en,auto).--prompt, -p: Additional instructions for the reviewer. Use@file.txtto read from a file.--output, -o: Report output directory (default:~/.kodevu).--format, -f: Output formats (e.g.,markdown,json, ormarkdown,json).--openai-api-key: API key used when--reviewer openai.--openai-base-url: Base URL used when--reviewer openai(default:https://api.openai.com/v1).--openai-model: Model used when--reviewer openai(default:gpt-5-mini).--openai-org: Optional OpenAI organization ID.--openai-project: Optional OpenAI project ID.--debug, -d: Print debug information.--version, -V: Print the current version and exit.
[!IMPORTANT]
--revand--lastare mutually exclusive. Specifying both will result in an error.
Environment Variables
You can set these in your shell to change default behavior without typing flags every time:
KODEVU_REVIEWER: Default reviewer.KODEVU_LANG: Default language.KODEVU_OUTPUT_DIR: Default output directory.KODEVU_PROMPT: Default prompt instructions.KODEVU_TIMEOUT: Reviewer execution timeout in milliseconds.KODEVU_OPENAI_API_KEY: API key foropenai.KODEVU_OPENAI_BASE_URL: Base URL foropenai.KODEVU_OPENAI_MODEL: Model foropenai.KODEVU_OPENAI_ORG: Optional organization ID foropenai.KODEVU_OPENAI_PROJECT: Optional project ID foropenai.
Examples
Selecting Revisions
Review the latest 3 commits:
npx kodevu . --last 3Review only the 3rd latest commit:
npx kodevu . --last -3Review a specific commit hash:
npx kodevu . --rev abc1234Options & Formatting
Review using custom instructions from a file:
npx kodevu . --prompt @my-rules.txtGenerate JSON reports in a local folder:
npx kodevu . --format json --output ./reportsEnvironment Variables
Set a persistent reviewer for your shell session:
export KODEVU_REVIEWER=gemini
npx kodevu .Use the OpenAI API directly with a small set of extra settings:
export KODEVU_REVIEWER=openai
export KODEVU_OPENAI_API_KEY=sk-...
export KODEVU_OPENAI_MODEL=gpt-5-mini
npx kodevu .Use a custom OpenAI-compatible endpoint:
npx kodevu . \
--reviewer openai \
--openai-api-key sk-... \
--openai-base-url https://your-gateway.example.com/v1 \
--openai-model gpt-5-miniHow it Works
- Git Targets:
targetmust be a local repository or subdirectory. - SVN Targets:
targetcan be a working copy path or repository URL. - Reviewer "auto": Probes
codex,gemini, andcopilotin yourPATHand selects one. - Reviewer "openai": Calls the OpenAI Chat Completions API directly.
autodoes not selectopenai, so API-based use stays explicit. - Contextual Review: For local repositories, the reviewer can inspect related files beyond the diff to provide deeper insights.
License
MIT
