-
Notifications
You must be signed in to change notification settings - Fork 0
Jujutsu (jj) version control support #20
Description
Summary
Add first-class support for projects using Jujutsu (jj) as their version control system. jj has several properties that make it a better fit than git for AI-assisted development workflows.
Motivation
Agent-scale commit volume
AI agents produce code at machine speed — frequent commits, parallel changes, lots of rebasing. Git's merge conflict model treats conflicts as blocking errors. jj treats conflicts as first-class data that can be committed and resolved later, keeping agents unblocked.
Better undo and safety
jj's operation log records every VCS operation and makes them all undoable. When an agent makes autonomous code changes, every action can be cleanly rolled back — not just commits, but rebases, branch moves, and merges. This is a much stronger safety net than git's reflog.
Simpler mental model for agents
jj has no staging area — the working copy is always a commit. This eliminates an entire class of agent mistakes ("forgot to git add", "committed wrong files", "staged partial changes"). The agent just edits files and jj tracks everything automatically.
Stable change IDs
Changes keep their identity across rebases and amends. This makes it possible to track "this deploy came from change XYZ" reliably, even after the history has been rewritten — connecting deploys to specific code changes.
Proposed scope
Phase 1: Detection and compatibility
- Detect
.jj/directory alongside or instead of.git/ - Adapt
jack ship/jack syncto work with jj repos (jj has git interop, so this may mostly work already) - Use jj's operation log to enrich session transcripts with VCS context
Phase 2: Agent-aware features
- Leverage conflict-as-data: let agents commit WIP with conflicts without blocking deploys
- Surface jj operation log in
jack deploysfor full auditability - Map jj change IDs to deployment IDs for traceability
Phase 3: Workflow integration
- Auto-rebase dependent branches when an agent finishes work
- Branch-aware preview deploys (each jj change gets its own preview URL)
Acceptance criteria (Phase 1)
-
jack shipworks in a jj-managed repo without errors -
jack synchandles jj repos (or clearly errors with guidance) - Session transcripts include jj operation context when available
- No regression for git-based projects