ok/jj
1
0
Fork 0
forked from mirrors/jj

Update the documentation for jj next

This is to match the recent changes made to the docs for `jj prev`.
This commit is contained in:
Evan Mesterhazy 2024-04-05 15:05:45 -04:00 committed by Evan Mesterhazy
parent 506392703b
commit f4fb8f18a7
2 changed files with 40 additions and 34 deletions

View file

@ -25,31 +25,34 @@ use crate::ui::Ui;
/// Move the working-copy commit to the child revision
///
/// The command moves you to the next child in a linear fashion.
/// The command creates a new empty working copy revision that is the child of a
/// descendant `offset` revisions ahead of the parent of the current working
/// copy.
///
/// For example, when the offset is 1:
///
/// ```text
/// D D @
/// | |/
/// C @ => C
/// |/ |
/// B B
/// D D @
/// | |/
/// C @ => C
/// |/ |
/// B B
/// ```
///
/// If `--edit` is passed, it will move you directly to the child
/// revision.
/// If `--edit` is passed, the working copy revision is changed to the child of
/// the current working copy revision.
///
/// ```text
/// D D
/// | |
/// C C
/// | |
/// B => @
/// | |
/// @ A
///
/// D D
/// | |
/// C C
/// | |
/// B => @
/// | |
/// @ A
/// ```
/// If your working-copy commit already has visible children, then `--edit` is
/// implied.
/// ```
#[derive(clap::Args, Clone, Debug)]
#[command(verbatim_doc_comment)]
pub(crate) struct NextArgs {

View file

@ -1148,31 +1148,34 @@ For more information, see https://github.com/martinvonz/jj/blob/main/docs/workin
Move the working-copy commit to the child revision
The command moves you to the next child in a linear fashion.
The command creates a new empty working copy revision that is the child of a
descendant `offset` revisions ahead of the parent of the current working
copy.
For example, when the offset is 1:
```text
D D @
| |/
C @ => C
|/ |
B B
D D @
| |/
C @ => C
|/ |
B B
```
If `--edit` is passed, it will move you directly to the child
revision.
If `--edit` is passed, the working copy revision is changed to the child of
the current working copy revision.
```text
D D
| |
C C
| |
B => @
| |
@ A
D D
| |
C C
| |
B => @
| |
@ A
```
If your working-copy commit already has visible children, then `--edit` is
implied.
```
**Usage:** `jj next [OPTIONS] [OFFSET]`