Skip to main content
On this page

Kater CLI Delete and restore trash

kater trash fix

Fixes each object that reads a deleted object, in one change, as Fix in the Trash does.

With no options, Kater’s fix applies: what Kater selected reads in its place where a part can read it, a part that stands on its own goes, and the rest keeps showing Not available.

Examples

Terminal window
# See Kater's fix: the verdict, and each part's code before and after. Nothing changes.
kater trash fix 3f1c9a20-5b7e-4d21-9a0e-1c2d3e4f5a6b --dry-run
# Apply Kater's fix
kater trash fix 3f1c9a20-5b7e-4d21-9a0e-1c2d3e4f5a6b
# Put engaged_sessions in its place
kater trash fix 3f1c9a20-5b7e-4d21-9a0e-1c2d3e4f5a6b --with engaged_sessions
# Remove each part in place of a replace
kater trash fix 3f1c9a20-5b7e-4d21-9a0e-1c2d3e4f5a6b --with none
# Apply Kater's fix, but leave the dashboard's tile as it is
kater trash fix 3f1c9a20-5b7e-4d21-9a0e-1c2d3e4f5a6b --part connections/duckdb_sample/workspaces/shop/dashboard.yaml#connections/duckdb_sample/workspaces/shop/dashboard.yaml:95=keep

Arguments

ArgumentDescription
<id>The deleted object’s id in the Trash, as kater trash list --fix gives it.

Options

OptionDescription
--with <name>What reads in the deleted object’s place, by its name, or none. Without it, the object that Kater selected.
--part <id>=<fix>One part’s fix: ID=remove, ID=replace or ID=keep, with the part’s id as --dry-run prints it. keep leaves the part showing Not available. You can give it more than one time.
--dry-runShow the fix, as Review Kater’s fix shows it, with each part’s code before and after, and change nothing.

It also takes the global options --json and --help.

What it answers

It gives the number of objects that it fixed, what Kater replaced and removed, and the number of parts that still show Not available. The last line is the kater undo command that takes the change back. When a part has no fix yet, nothing changes, and the command names the part to give a --part.

  • Agents ask first. An agent runs --dry-run first, tells you what will change, and runs the fix with kater_apply only after you say yes.

See also