Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
* The `CryptographicSignature.key()` template method now also works for SSH
signatures and returns the corresponding public key fingerprint.

* `jj diff` now accepts `-o` as a shorthand for `--name-only`.

### Fixed bugs

* `jj metaedit --author-timestamp` twice with the same value no longer
Expand Down
2 changes: 1 addition & 1 deletion cli/src/diff_util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ pub struct DiffFormatArgs {
///
/// Typically useful for shell commands like:
/// `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
#[arg(long)]
#[arg(long, short = 'o')]
pub name_only: bool,
/// Show a Git-format diff
#[arg(long)]
Expand Down
16 changes: 8 additions & 8 deletions cli/tests/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -840,7 +840,7 @@ If no option is specified, it defaults to `-r @`.
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down Expand Up @@ -969,7 +969,7 @@ Lists the previous commits which a change has pointed to. The current commit of
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down Expand Up @@ -1604,7 +1604,7 @@ This excludes changes from other commits by temporarily rebasing `--from` onto `
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down Expand Up @@ -1667,7 +1667,7 @@ The working-copy commit is indicated by a `@` symbol in the graph. [Immutable re
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down Expand Up @@ -1915,7 +1915,7 @@ Compare changes to the repository between two operations
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down Expand Up @@ -1960,7 +1960,7 @@ Like other commands, `jj op log` snapshots the current working-copy changes and
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down Expand Up @@ -2069,7 +2069,7 @@ Show changes to the repository in an operation
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down Expand Up @@ -2543,7 +2543,7 @@ Show commit description and changes in a revision
* `--types` — For each path, show only its type before and after

The diff is shown as two letters. The first letter indicates the type before and the second letter indicates the type after. '-' indicates that the path was not present, 'F' represents a regular file, `L' represents a symlink, 'C' represents a conflict, and 'G' represents a Git submodule.
* `--name-only` — For each path, show only its path
* `-o`, `--name-only` — For each path, show only its path

Typically useful for shell commands like: `jj diff -r @- --name-only | xargs perl -pi -e's/OLD/NEW/g`
* `--git` — Show a Git-format diff
Expand Down