repositories / termux-janitor
termux-janitor
Interactive cleanup assistant for Termux: transparent, safe, confirmed disk reclamation.
owned by admin
spec/model/cli.zon
Raw.{
.executable = "termux-janitor",
.description =
\\Review package and filesystem cleanup candidates, then execute only a confirmed plan.
,
.default_mode = "Scan and open the interactive TUI.",
.long_options_only = true,
.option_terminator = true,
.operands_allowed = false,
.duplicate_options_allowed = false,
.unattended_cleanup = false,
.informational_stream = .stdout,
.usage_stream = .stderr,
.diagnostic_stream = .stderr,
.options = .{
.{
.id = "dry_run",
.spelling = "--dry-run",
.argument = .none,
.summary = "Open the TUI and prohibit cleanup mutation except the run log.",
.must_appear_alone = false,
.bypasses_startup = .{},
.requires_terminal = true,
},
.{
.id = "config",
.spelling = "--config",
.argument = .path,
.summary = "Use one explicit nonempty configuration path.",
.must_appear_alone = false,
.bypasses_startup = .{},
.requires_terminal = true,
},
.{
.id = "no_color",
.spelling = "--no-color",
.argument = .none,
.summary = "Disable color semantics.",
.must_appear_alone = false,
.bypasses_startup = .{},
.requires_terminal = true,
},
.{
.id = "ascii",
.spelling = "--ascii",
.argument = .none,
.summary = "Disable Unicode UI elements independently of color.",
.must_appear_alone = false,
.bypasses_startup = .{},
.requires_terminal = true,
},
.{
.id = "help",
.spelling = "--help",
.argument = .none,
.summary = "Write help to stdout.",
.must_appear_alone = true,
.bypasses_startup = .{ .configuration, .logging, .terminal_initialization, .scanning },
.requires_terminal = false,
},
.{
.id = "version",
.spelling = "--version",
.argument = .none,
.summary = "Write the version to stdout.",
.must_appear_alone = true,
.bypasses_startup = .{ .configuration, .logging, .terminal_initialization, .scanning },
.requires_terminal = false,
},
},
.argument_rules = .{
.{
.option = "config",
.argument = "PATH",
.arity = 1,
.syntax = .separate,
.nonempty = true,
.relative_base = .initial_working_directory,
},
},
.exit_statuses = .{
.{
.id = "success",
.code = 0,
.condition = "Normal quit, help, or version.",
},
.{
.id = "failure",
.code = 1,
.condition = "Failure, or cancellation after an observed or uncertain mutation.",
},
.{
.id = "usage",
.code = 2,
.condition = "Unknown option, missing value, duplicate option, conflict, or operand.",
},
.{
.id = "cancelled",
.code = 130,
.condition = "Cancellation before any observed mutation.",
},
},
}