The power tool for Jujutsu + GitHub workflows. Single PRs with amend support. Stacked PRs without the complexity.
A command-line tool that bridges Jujutsu's change-based workflow with GitHub's pull request model. Amend freely in your local repository while keeping reviewers happy with clean, incremental diffs.
⚠️ Important: Write Access RequiredDue to GitHub API limitations, SPR requires write access to the repository. You must be a collaborator or have write permissions to use SPR. This is a GitHub platform constraint - the API does not support creating PRs from forks without write access to the target repository.
If you're contributing to a project where you don't have write access, you'll need to use the standard fork + PR workflow through the GitHub web interface.
- Amend freely: Use Jujutsu's natural
jj squashandjj describeworkflow - Review cleanly: Reviewers see clear incremental diffs, not confusing force-push history
- Update naturally: Each update creates a new commit on GitHub, preserving review context
- Land cleanly: Everything squashes into one perfect commit on merge
- Stack with confidence: Create dependent or independent PRs with automatic rebase handling
- Land flexibly: Effortless cleanup and rebase with
jj spr syncafter landing on GitHub. - Rebase trivially: Jujutsu's stable change IDs survive rebases
- Review independently: Each PR shows only its changes, not the cumulative stack
The Problem SPR Solves: Jujutsu encourages amending changes. GitHub's review UI breaks with force pushes. SPR bridges this gap by maintaining an append-only PR branch on GitHub while you amend freely locally.
git clone https://github.com/Ongy/jj-spr.git
cd jj-spr
cargo install --path sprThis installs the jj-spr binary to your ~/.cargo/bin directory.
Configure jj spr as a subcommand:
jj config set --user aliases.spr '["util", "exec", "--", "jj-spr"]'-
Initialize in your repository:
cd your-jujutsu-repo jj spr init -
Provide your GitHub Personal Access Token when prompted.
# 1. Create a change
jj new main@origin
echo "new feature" > feature.txt
jj describe -m "Add new feature"
# 2. Submit for review (operates on @ and all its ancestors)
jj spr push
# 3. Amend based on feedback
echo "updated feature" > feature.txt
jj describe # Edit description if needed
jj spr push # Updates PR(s) in the stack
# 4. Land when approved via GitHub UI (e.g. Squash and Merge)
# 5. Sync after landing (cleans up the entire stack)
jj spr sync@= your working copy (where you make edits)jj spr pushtreatment: It treates specified revision(s) as heads and operates on them and all their mutable ancestors that have descriptions.- Change IDs remain stable through rebases, keeping PRs linked
-
jj spr push- Create or update pull requests for a stack of changes- Operates on ancestors:
@by default, or specified via-r - Updates create new commits on GitHub (reviewers see clean diffs)
- Operates on ancestors:
-
jj spr sync- Cleanup and rebase a stack after landing PRs on GitHub- Operates on ancestors:
@by default, or specified via-r - Abandons local commits for merged/closed PRs
- Rebases remaining work in the stack onto latest upstream main
- Operates on ancestors:
-
jj spr fetch- Update local commit messages in a stack from GitHub- Use
--pull-code-changesto also pull code updates from GitHub
- Use
-
jj spr list- List open pull requests and their status -
jj spr adopt- Pull an existing PR (and its chain) from GitHub into your local repo
Full documentation is available at luciofranco.github.io/jj-spr
Super Pull Requests builds on the foundation of:
- Original spr by the Cord team
- Jujutsu integration by sunshowers
- Jujutsu by Martin von Zweigbergk and contributors
MIT License - see LICENSE for details.