| name | description |
|---|---|
jj |
Use Jujutsu (jj) version control system. Git-compatible VCS with auto-committed working copy, first-class conflicts, operation log, and revset language. Use when working with repos that use jj instead of (or alongside) git, for commits, rebases, bookmarks, PRs, workspace management, and version control operations. |
- No staging area — working copy is auto-committed as a new change
- Change IDs vs commit IDs — changes have stable IDs across rebases; use change IDs (short form like
yrym) over commit hashes - First-class conflicts — conflicts are stored in commits, not blocking; resolve at any time
- Operation log — every operation recorded and undoable (
jj undo,jj op log) - Automatic rebase — descendants rebase automatically when ancestors are modified
- Revsets — expression language for selecting commits (e.g.
trunk()..@,ancestors(@, 5)) - Bookmarks — jj's equivalent of git branches; can be tracked/untracked from remotes
# Start new work
jj new main # create new change on top of main
jj describe -m "message" # describe the change
# Iterate
# (just edit files — working copy auto-commits)
jj diff # see what changed
jj log # view history
# Commit and continue
jj commit -m "message" # snapshot current change, create new empty one on top
# Stack management
jj new # new empty change on top of current
jj squash # squash current into parent
jj split # interactively split current change
jj rebase -d main # rebase current onto main
# Bookmarks (branches)
jj bookmark create name # create bookmark at current change
jj bookmark set name # move bookmark to current change
jj bookmark track name@origin
# Sync
jj git fetch # fetch from remotes
jj git push # push bookmarks to remote- jj repos can be colocated with git (
.jj/+.git/side by side) jj git fetch/jj git pushinteract with git remotes- Git branches appear as bookmarks in jj
trunk()revset typically resolves tomain@origin
- No
git add/git stage— everything is automatic jj describeedits the current change's message (likegit commit --amendfor the message)jj commit= snapshot + create new empty change (not likegit commit)jj new= create new empty change (not likegit checkout -b)- Rewriting history is the norm, not the exception
- Multiple changes can be in-progress simultaneously without stashing