Default mode: gga run
Reviews files currently staged with git add. This is the mode invoked by the pre-commit hook installed with gga install.Smart caching is enabled by default. Files that haven’t changed since their last passed review are skipped automatically.Terminal output:ℹ️ Provider: claude
ℹ️ Rules file: AGENTS.md
ℹ️ File patterns: *.ts,*.tsx,*.js,*.jsx
ℹ️ Cache: enabled
Files to review:
- src/components/Button.tsx
# ...AI review output...
✅ CODE REVIEW PASSED
If all staged files are already cached:✅ 3 file(s) passed from cache
Files to review:
All files passed from cache!
✅ CODE REVIEW PASSED (cached)
To force a review of all staged files regardless of cache, use gga run --no-cache.
PR diff-only mode: gga run --pr-mode --diff-only
Like PR mode, but sends only the unified diff to the AI instead of full file contents. This is faster and cheaper for large pull requests with many changed files.gga run --pr-mode --diff-only
Terminal output:ℹ️ Provider: claude
ℹ️ Rules file: AGENTS.md
ℹ️ File patterns: *.ts,*.tsx,*.js,*.jsx
ℹ️ Mode: PR (diff-only review)
ℹ️ Cache: disabled (PR mode)
ℹ️ PR range: main...feature/my-branch
--diff-only is only valid when combined with --pr-mode. Using --diff-only without --pr-mode will result in an error.
Use this when you want to minimize token usage on large PRs where the AI only needs to see what changed, not the full context of every file.Commit-msg mode
When the commit-msg hook is installed with gga install --commit-msg, git passes the path to the commit message file as the first argument to the hook. The hook invokes:GGA reads the commit message file and includes the message in the AI review prompt. This lets you enforce commit message conventions — such as conventional commits format or required issue references — alongside your code standards.Install the commit-msg hook
Commit as normal
git add src/feature.ts
git commit -m "feat: add new feature"
GGA reviews both the staged files and the commit message together.The commit message is included automatically when gga run receives a file path argument that resolves to an existing file. No extra flags are needed — the hook handles this.