Skip to content

Instantly share code, notes, and snippets.

@alandipert
Created October 9, 2025 02:25
Show Gist options
  • Save alandipert/ef62a01a10cbedff8498f74ca753629b to your computer and use it in GitHub Desktop.
Save alandipert/ef62a01a10cbedff8498f74ca753629b to your computer and use it in GitHub Desktop.

Local Async Pull Request Workflow with Codex + git-appraise

Problem

Most code review systems (GitHub, GitLab, etc.) depend on hosted web services.
They’re slow, require accounts and internet access, and scatter review metadata outside the repo.
For solo work, private code, or AI collaboration, that’s unnecessary friction.


Constraints

  • Single local Git repository — no external servers or SaaS
  • Asynchronous workflow — human and AI reviewers act independently
  • Pull-request-style features — open requests, threaded comments, approvals
  • Everything versioned — reviews and comments stored directly in Git

Solution

Use git-appraise to emulate pull requests locally.
It records review requests, comments, and approvals as Git notes.

Then run a lightweight Codex bot (cron or systemd job) that:

  1. Detects new or updated reviews (git appraise list --json)
  2. Builds diffs between branches
  3. Sends diffs to Codex for analysis and feedback
  4. Posts inline comments back via git appraise comment
  5. Reads follow-up comments and edits code accordingly, committing fixes

Result: a self-contained async PR loop

git appraise request ↓ Codex review + comments ↓ Human feedback ↓ Codex revisions + commits ↓ git appraise accept


Pros

  • Fully Git-native: no external accounts; all data lives in the repo
  • Private/offline: works via local files or simple SSH remotes
  • Automation-friendly: Codex can comment and patch automatically
  • Composable: integrate with any local build/test scripts
  • Async by design: reviewers and bots act on their own time

Cons

  • No fancy UI: review threads are plain text in terminal
  • AI accuracy varies: vague comments can yield off-target patches
  • Manual orchestration: must schedule the bot yourself
  • Limited visibility: collaborators need to pull/push notes to see updates

Summary:
A self-hosted, Git-native pull-request system that enables AI-assisted reviews and revisions entirely offline — no GitHub, no servers, just Git, git-appraise, and Codex.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment