Loading...
Loading...
Jujutsu (jj) version control, load skill when hook output shows vcs=jj-colocated or vcs=jj in the system-reminder.
npx skill4agent add trevors/dot-claude jj-workflow-m# WRONG - opens editor, blocks AI
jj new
jj describe
jj squash
# CORRECT - non-interactive
jj new -m "message"
jj describe -m "message"
jj squash -m "message"jj split@@-| Situation | Do This |
|---|---|
| Starting new work | |
| Forgot to start with jj new | |
| Work is done, move on | |
| Annotate what you did | |
| Broke something | |
| Undo one file | |
| Combine messy commits | |
| Try something risky | |
# BEFORE starting work - declare intent
jj new -m "feat: add user logout button"
# Now implement... jj tracks everything automatically
# FORGOT to start with jj new? Describe immediately
jj describe -m "feat: what I'm working on"jj log# Checkpoint before risky changes
jj describe -m "checkpoint: auth works"
jj new -m "trying OAuth integration"
# If it breaks
jj op log # Find good state
jj op restore <id> # Go back
# When done, curate history
jj squash -m "feat: OAuth support"# 1. Abandon empty checkpoint commits cluttering history
jj log -r '::@' # Find checkpoints
jj abandon <change-ids> # Remove empty ones
# 2. Describe your work (don't try to squash into immutable parent)
jj describe -m "feat: what you did"
# 3. Move bookmark to your commit and push
jj bookmark set master -r @
jj git pushjj bookmark create feature-x -r @
jj git push --bookmark feature-x
# If refused, configure auto-tracking once:
jj config set --user 'remotes.origin.auto-track-bookmarks' 'glob:*'
# Then retry: jj git push --bookmark feature-xjj bookmark set feature-x -r @
jj git pushjj op log # See all operations
jj undo # Undo last operation
jj op restore <id> # Jump to any past staterm -rf .jj # Delete jj, keep git unchanged