--- source: cli/tests/test_generate_md_cli_help.rs description: "AUTO-GENERATED FILE, DO NOT EDIT. This cli reference is generated by a test as an `insta` snapshot. MkDocs includes this snapshot from docs/cli-reference.md." --- # Command-Line Help for `jj` This document contains the help content for the `jj` command-line program. **Command Overview:** * [`jj`↴](#jj) * [`jj abandon`↴](#jj-abandon) * [`jj absorb`↴](#jj-absorb) * [`jj bookmark`↴](#jj-bookmark) * [`jj bookmark create`↴](#jj-bookmark-create) * [`jj bookmark delete`↴](#jj-bookmark-delete) * [`jj bookmark forget`↴](#jj-bookmark-forget) * [`jj bookmark list`↴](#jj-bookmark-list) * [`jj bookmark move`↴](#jj-bookmark-move) * [`jj bookmark rename`↴](#jj-bookmark-rename) * [`jj bookmark set`↴](#jj-bookmark-set) * [`jj bookmark track`↴](#jj-bookmark-track) * [`jj bookmark untrack`↴](#jj-bookmark-untrack) * [`jj commit`↴](#jj-commit) * [`jj config`↴](#jj-config) * [`jj config edit`↴](#jj-config-edit) * [`jj config get`↴](#jj-config-get) * [`jj config list`↴](#jj-config-list) * [`jj config path`↴](#jj-config-path) * [`jj config set`↴](#jj-config-set) * [`jj config unset`↴](#jj-config-unset) * [`jj describe`↴](#jj-describe) * [`jj diff`↴](#jj-diff) * [`jj diffedit`↴](#jj-diffedit) * [`jj duplicate`↴](#jj-duplicate) * [`jj edit`↴](#jj-edit) * [`jj evolog`↴](#jj-evolog) * [`jj file`↴](#jj-file) * [`jj file annotate`↴](#jj-file-annotate) * [`jj file chmod`↴](#jj-file-chmod) * [`jj file list`↴](#jj-file-list) * [`jj file show`↴](#jj-file-show) * [`jj file track`↴](#jj-file-track) * [`jj file untrack`↴](#jj-file-untrack) * [`jj fix`↴](#jj-fix) * [`jj git`↴](#jj-git) * [`jj git clone`↴](#jj-git-clone) * [`jj git export`↴](#jj-git-export) * [`jj git fetch`↴](#jj-git-fetch) * [`jj git import`↴](#jj-git-import) * [`jj git init`↴](#jj-git-init) * [`jj git push`↴](#jj-git-push) * [`jj git remote`↴](#jj-git-remote) * [`jj git remote add`↴](#jj-git-remote-add) * [`jj git remote list`↴](#jj-git-remote-list) * [`jj git remote remove`↴](#jj-git-remote-remove) * [`jj git remote rename`↴](#jj-git-remote-rename) * [`jj git remote set-url`↴](#jj-git-remote-set-url) * [`jj git root`↴](#jj-git-root) * [`jj help`↴](#jj-help) * [`jj interdiff`↴](#jj-interdiff) * [`jj log`↴](#jj-log) * [`jj new`↴](#jj-new) * [`jj next`↴](#jj-next) * [`jj operation`↴](#jj-operation) * [`jj operation abandon`↴](#jj-operation-abandon) * [`jj operation diff`↴](#jj-operation-diff) * [`jj operation log`↴](#jj-operation-log) * [`jj operation restore`↴](#jj-operation-restore) * [`jj operation show`↴](#jj-operation-show) * [`jj operation undo`↴](#jj-operation-undo) * [`jj parallelize`↴](#jj-parallelize) * [`jj prev`↴](#jj-prev) * [`jj rebase`↴](#jj-rebase) * [`jj resolve`↴](#jj-resolve) * [`jj restore`↴](#jj-restore) * [`jj revert`↴](#jj-revert) * [`jj root`↴](#jj-root) * [`jj show`↴](#jj-show) * [`jj sign`↴](#jj-sign) * [`jj simplify-parents`↴](#jj-simplify-parents) * [`jj sparse`↴](#jj-sparse) * [`jj sparse edit`↴](#jj-sparse-edit) * [`jj sparse list`↴](#jj-sparse-list) * [`jj sparse reset`↴](#jj-sparse-reset) * [`jj sparse set`↴](#jj-sparse-set) * [`jj split`↴](#jj-split) * [`jj squash`↴](#jj-squash) * [`jj status`↴](#jj-status) * [`jj tag`↴](#jj-tag) * [`jj tag list`↴](#jj-tag-list) * [`jj util`↴](#jj-util) * [`jj util completion`↴](#jj-util-completion) * [`jj util config-schema`↴](#jj-util-config-schema) * [`jj util exec`↴](#jj-util-exec) * [`jj util gc`↴](#jj-util-gc) * [`jj util install-man-pages`↴](#jj-util-install-man-pages) * [`jj util markdown-help`↴](#jj-util-markdown-help) * [`jj undo`↴](#jj-undo) * [`jj unsign`↴](#jj-unsign) * [`jj version`↴](#jj-version) * [`jj workspace`↴](#jj-workspace) * [`jj workspace add`↴](#jj-workspace-add) * [`jj workspace forget`↴](#jj-workspace-forget) * [`jj workspace list`↴](#jj-workspace-list) * [`jj workspace rename`↴](#jj-workspace-rename) * [`jj workspace root`↴](#jj-workspace-root) * [`jj workspace update-stale`↴](#jj-workspace-update-stale) ## `jj` Jujutsu (An experimental VCS) To get started, see the tutorial [`jj help -k tutorial`]. [`jj help -k tutorial`]: https://jj-vcs.github.io/jj/latest/tutorial/ **Usage:** `jj [OPTIONS] [COMMAND]` 'jj help --help' lists available keywords. Use 'jj help -k' to show help for one of these keywords. ###### **Subcommands:** * `abandon` — Abandon a revision * `absorb` — Move changes from a revision into the stack of mutable revisions * `bookmark` — Manage bookmarks [default alias: b] * `commit` — Update the description and create a new change on top * `config` — Manage config options * `describe` — Update the change description or other metadata * `diff` — Compare file contents between two revisions * `diffedit` — Touch up the content changes in a revision with a diff editor * `duplicate` — Create new changes with the same content as existing ones * `edit` — Sets the specified revision as the working-copy revision * `evolog` — Show how a change has evolved over time * `file` — File operations * `fix` — Update files with formatting fixes or other changes * `git` — Commands for working with Git remotes and the underlying Git repo * `help` — Print this message or the help of the given subcommand(s) * `interdiff` — Compare the changes of two commits * `log` — Show revision history * `new` — Create a new, empty change and (by default) edit it in the working copy * `next` — Move the working-copy commit to the child revision * `operation` — Commands for working with the operation log * `parallelize` — Parallelize revisions by making them siblings * `prev` — Change the working copy revision relative to the parent revision * `rebase` — Move revisions to different parent(s) * `resolve` — Resolve conflicted files with an external merge tool * `restore` — Restore paths from another revision * `revert` — Apply the reverse of the given revision(s) * `root` — Show the current workspace root directory (shortcut for `jj workspace root`) * `show` — Show commit description and changes in a revision * `sign` — Cryptographically sign a revision * `simplify-parents` — Simplify parent edges for the specified revision(s) * `sparse` — Manage which paths from the working-copy commit are present in the working copy * `split` — Split a revision in two * `squash` — Move changes from a revision into another revision * `status` — Show high-level repo status * `tag` — Manage tags * `util` — Infrequently used commands such as for generating shell completions * `undo` — Undo an operation (shortcut for `jj op undo`) * `unsign` — Drop a cryptographic signature * `version` — Display version information * `workspace` — Commands for working with workspaces ###### **Options:** * `-R`, `--repository ` — Path to repository to operate on By default, Jujutsu searches for the closest .jj/ directory in an ancestor of the current working directory. * `--ignore-working-copy` — Don't snapshot the working copy, and don't update it By default, Jujutsu snapshots the working copy at the beginning of every command. The working copy is also updated at the end of the command, if the command modified the working-copy commit (`@`). If you want to avoid snapshotting the working copy and instead see a possibly stale working-copy commit, you can use `--ignore-working-copy`. This may be useful e.g. in a command prompt, especially if you have another process that commits the working copy. Loading the repository at a specific operation with `--at-operation` implies `--ignore-working-copy`. * `--ignore-immutable` — Allow rewriting immutable commits By default, Jujutsu prevents rewriting commits in the configured set of immutable commits. This option disables that check and lets you rewrite any commit but the root commit. This option only affects the check. It does not affect the `immutable_heads()` revset or the `immutable` template keyword. * `--at-operation ` — Operation to load the repo at Operation to load the repo at. By default, Jujutsu loads the repo at the most recent operation, or at the merge of the divergent operations if any. You can use `--at-op=` to see what the repo looked like at an earlier operation. For example `jj --at-op= st` will show you what `jj st` would have shown you when the given operation had just finished. `--at-op=@` is pretty much the same as the default except that divergent operations will never be merged. Use `jj op log` to find the operation ID you want. Any unambiguous prefix of the operation ID is enough. When loading the repo at an earlier operation, the working copy will be ignored, as if `--ignore-working-copy` had been specified. It is possible to run mutating commands when loading the repo at an earlier operation. Doing that is equivalent to having run concurrent commands starting at the earlier operation. There's rarely a reason to do that, but it is possible. * `--debug` — Enable debug logging * `--color ` — When to colorize output Possible values: `always`, `never`, `debug`, `auto` * `--quiet` — Silence non-primary command output For example, `jj file list` will still list files, but it won't tell you if the working copy was snapshotted or if descendants were rebased. Warnings and errors will still be printed. * `--no-pager` — Disable the pager * `--config ` — Additional configuration options (can be repeated) The name should be specified as TOML dotted keys. The value should be specified as a TOML expression. If string value isn't enclosed by any TOML constructs (such as array notation), quotes can be omitted. * `--config-file ` — Additional configuration files (can be repeated) ## `jj abandon` Abandon a revision Abandon a revision, rebasing descendants onto its parent(s). The behavior is similar to `jj restore --changes-in`; the difference is that `jj abandon` gives you a new change, while `jj restore` updates the existing change. If a working-copy commit gets abandoned, it will be given a new, empty commit. This is true in general; it is not specific to this command. **Usage:** `jj abandon [OPTIONS] [REVSETS]...` ###### **Arguments:** * `` — The revision(s) to abandon (default: @) ###### **Options:** * `--retain-bookmarks` — Do not delete bookmarks pointing to the revisions to abandon Bookmarks will be moved to the parent revisions instead. * `--restore-descendants` — Do not modify the content of the children of the abandoned commits ## `jj absorb` Move changes from a revision into the stack of mutable revisions This command splits changes in the source revision and moves each change to the closest mutable ancestor where the corresponding lines were modified last. If the destination revision cannot be determined unambiguously, the change will be left in the source revision. The source revision will be abandoned if all changes are absorbed into the destination revisions, and if the source revision has no description. The modification made by `jj absorb` can be reviewed by `jj op show -p`. **Usage:** `jj absorb [OPTIONS] [FILESETS]...` ###### **Arguments:** * `` — Move only changes to these paths (instead of all paths) ###### **Options:** * `-f`, `--from ` — Source revision to absorb from Default value: `@` * `-t`, `--into ` — Destination revisions to absorb into Only ancestors of the source revision will be considered. Default value: `mutable()` ## `jj bookmark` Manage bookmarks [default alias: b] See [`jj help -k bookmarks`] for more information. [`jj help -k bookmarks`]: https://jj-vcs.github.io/jj/latest/bookmarks **Usage:** `jj bookmark ` ###### **Subcommands:** * `create` — Create a new bookmark * `delete` — Delete an existing bookmark and propagate the deletion to remotes on the next push * `forget` — Forget a bookmark without marking it as a deletion to be pushed * `list` — List bookmarks and their targets * `move` — Move existing bookmarks to target revision * `rename` — Rename `old` bookmark name to `new` bookmark name * `set` — Create or update a bookmark to point to a certain commit * `track` — Start tracking given remote bookmarks * `untrack` — Stop tracking given remote bookmarks ## `jj bookmark create` Create a new bookmark **Usage:** `jj bookmark create [OPTIONS] ...` ###### **Arguments:** * `` — The bookmarks to create ###### **Options:** * `-r`, `--revision ` — The bookmark's target revision ## `jj bookmark delete` Delete an existing bookmark and propagate the deletion to remotes on the next push Revisions referred to by the deleted bookmarks are not abandoned. To delete revisions as well as bookmarks, use `jj abandon`. For example, `jj abandon main..` will abandon revisions belonging to the `` branch (relative to the `main` branch.) If you don't want the deletion of the local bookmark to propagate to any tracked remote bookmarks, use `jj bookmark forget` instead. **Usage:** `jj bookmark delete ...` ###### **Arguments:** * `` — The bookmarks to delete By default, the specified name matches exactly. Use `glob:` prefix to select bookmarks by [wildcard pattern]. [wildcard pattern]: https://jj-vcs.github.io/jj/latest/revsets/#string-patterns ## `jj bookmark forget` Forget a bookmark without marking it as a deletion to be pushed If a local bookmark is forgotten, any corresponding remote bookmarks will become untracked to ensure that the forgotten bookmark will not impact remotes on future pushes. **Usage:** `jj bookmark forget [OPTIONS] ...` ###### **Arguments:** * `` — The bookmarks to forget By default, the specified name matches exactly. Use `glob:` prefix to select bookmarks by [wildcard pattern]. [wildcard pattern]: https://jj-vcs.github.io/jj/latest/revsets/#string-patterns ###### **Options:** * `--include-remotes` — When forgetting a local bookmark, also forget any corresponding remote bookmarks A forgotten remote bookmark will not impact remotes on future pushes. It will be recreated on future fetches if it still exists on the remote. If there is a corresponding Git-tracking remote bookmark, it will also be forgotten. ## `jj bookmark list` List bookmarks and their targets By default, a tracking remote bookmark will be included only if its target is different from the local target. A non-tracking remote bookmark won't be listed. For a conflicted bookmark (both local and remote), old target revisions are preceded by a "-" and new target revisions are preceded by a "+". See [`jj help -k bookmarks`] for more information. [`jj help -k bookmarks`]: https://jj-vcs.github.io/jj/latest/bookmarks **Usage:** `jj bookmark list [OPTIONS] [NAMES]...` ###### **Arguments:** * `` — Show bookmarks whose local name matches By default, the specified name matches exactly. Use `glob:` prefix to select bookmarks by [wildcard pattern]. [wildcard pattern]: https://jj-vcs.github.io/jj/latest/revsets/#string-patterns ###### **Options:** * `-a`, `--all-remotes` — Show all tracking and non-tracking remote bookmarks including the ones whose targets are synchronized with the local bookmarks * `--remote ` — Show all tracking and non-tracking remote bookmarks belonging to this remote Can be combined with `--tracked` or `--conflicted` to filter the bookmarks shown (can be repeated.) By default, the specified remote name matches exactly. Use `glob:` prefix to select remotes by [wildcard pattern]. [wildcard pattern]: https://jj-vcs.github.io/jj/latest/revsets/#string-patterns * `-t`, `--tracked` — Show remote tracked bookmarks only. Omits local Git-tracking bookmarks by default * `-c`, `--conflicted` — Show conflicted bookmarks only * `-r`, `--revisions ` — Show bookmarks whose local targets are in the given revisions Note that `-r deleted_bookmark` will not work since `deleted_bookmark` wouldn't have a local target. * `-T`, `--template