diff --git a/cli/src/commands/squash.rs b/cli/src/commands/squash.rs index f9a54015fc..cef4712206 100644 --- a/cli/src/commands/squash.rs +++ b/cli/src/commands/squash.rs @@ -36,7 +36,6 @@ use crate::ui::Ui; /// 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. #[derive(clap::Args, Clone, Debug)] -#[command(visible_alias = "amend")] pub(crate) struct SquashArgs { #[arg(long, short, default_value = "@")] revision: RevisionArg, diff --git a/cli/src/commands/unsquash.rs b/cli/src/commands/unsquash.rs index 75ab0806e7..9cc7644747 100644 --- a/cli/src/commands/unsquash.rs +++ b/cli/src/commands/unsquash.rs @@ -36,7 +36,6 @@ use crate::ui::Ui; /// 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. #[derive(clap::Args, Clone, Debug)] -#[command(visible_alias = "unamend")] pub(crate) struct UnsquashArgs { #[arg(long, short, default_value = "@")] revision: RevisionArg, diff --git a/cli/src/config/misc.toml b/cli/src/config/misc.toml index 6802b92bca..94e0f9db4c 100644 --- a/cli/src/config/misc.toml +++ b/cli/src/config/misc.toml @@ -1,7 +1,10 @@ # The code assumes that this table exists, so don't delete it even if you remove # all aliases from here. [aliases] +amend = ["squash"] co = ["checkout"] +unamend = ["unsquash"] + [format] tree-level-conflicts = true diff --git a/docs/config.md b/docs/config.md index eaa074bcb9..5e9f3b05b6 100644 --- a/docs/config.md +++ b/docs/config.md @@ -389,7 +389,7 @@ Obviously, you would only set one line, don't copy them all in! ## Editing diffs The `ui.diff-editor` setting affects the tool used for editing diffs (e.g. `jj -split`, `jj amend -i`). The default is the special value `:builtin`, which +split`, `jj squash -i`). The default is the special value `:builtin`, which launches a built-in TUI tool (known as [scm-diff-editor]) to edit the diff in your terminal.