diff --git a/cli/src/commands/util/gc.rs b/cli/src/commands/util/gc.rs index 4903356bc..eef16ce00 100644 --- a/cli/src/commands/util/gc.rs +++ b/cli/src/commands/util/gc.rs @@ -24,6 +24,9 @@ use crate::command_error::CommandError; use crate::ui::Ui; /// Run backend-dependent garbage collection. +/// +/// To garbage-collect old operations and the commits/objects referenced by +/// then, run `jj op abandon ..` before `jj util gc`. #[derive(clap::Args, Clone, Debug)] pub struct UtilGcArgs { /// Time threshold diff --git a/cli/tests/cli-reference@.md.snap b/cli/tests/cli-reference@.md.snap index 65f7a86ca..997cda9a3 100644 --- a/cli/tests/cli-reference@.md.snap +++ b/cli/tests/cli-reference@.md.snap @@ -2264,7 +2264,9 @@ echo "args: $@" ## `jj util gc` -Run backend-dependent garbage collection +Run backend-dependent garbage collection. + +To garbage-collect old operations and the commits/objects referenced by then, run `jj op abandon ..` before `jj util gc`. **Usage:** `jj util gc [OPTIONS]`