Use built-in help to look up flags, aliases, and examples:

jj-stack --help
jj-stack <command> --help
jj-stack help --all

jj-stack help --all includes advanced commands and global options. The complete CLI reference combines the help for every command on one page.

Core workflow

CommandUse it to
viewShow a local stack and the status of its pull requests.
listList tracked stacks and orphaned PRs in this repo.
submitCreate or update PR branches and pull requests.
mergeAsk GitHub to merge ready pull requests from the bottom of a stack.
syncUpdate local history after GitHub merges or rebases, then refresh remaining PRs.

Running jj-stack without a subcommand is equivalent to jj-stack view without arguments.

Connect or repair pull requests

CommandUse it to
checkoutFetch an existing PR stack, link it to local changes, and edit the chosen change.
relinkResume updating PRs after unstack --local or a push from another checkout.
doctorCheck repo setup, GitHub access, and leftovers from interrupted commands.
in-useSilently check whether this repo has jj-stack tracking data.

Separate a stack or close pull requests

CommandUse it to
unstackTell GitHub that a set of open pull requests is no longer one stack.
cleanupRemove unused PR branches, managed comments, and saved pull request links.

Supporting tools

CommandUse it to
completionGenerate shell completion for jj-stack or a jj stack alias.
help --allInclude advanced commands and global options in top-level help.

Choose a stack

Pass a head change ID to view, submit, merge, or sync to select a stack explicitly. Where supported, use --pull-request to select by PR number or URL.

After a failed or interrupted command, use the head change ID printed by jj-stack view when you retry. It still identifies the change if the working copy moves or you rewrite the stack.

See Bookmarks and stack selection for how bookmark names, change IDs, and other revision expressions choose a stack.