saferm v0.8.1 /saferm CLI Reference
On this page

Complete CLI reference for saferm — all available commands, subcommands, flags, arguments, and usage examples with detailed descriptions.

#saferm CLI Reference

AI-first safe rm replacement

Version: 0.8.1

#Commands

  • delete -- Move files to the saferm archive with metadata tracking
  • info -- Display full metadata and context for an archived deletion
  • list -- Show all items currently held in the saferm archive
  • purge -- Permanently destroy archived items and free disk space
  • undelete -- Restore a previously archived file back to its original path

#Command Groups

  • config -- Manage persistent configuration values stored in the config file

#Global flags

Global flags
NameShortTypeDefaultEnvDescription
--archive-dirstr{"relative_to_root": {"env_var": "SAFERM_HOME", "parts": ["archive"]}}Path to the archive directory
--db-pathstr{"relative_to_root": {"env_var": "SAFERM_HOME", "parts": ["db", "saferm.db"]}}Path to the SQLite database
--exclude-env-patternsstr["(?i)token", "(?i)secret", "(?i)password", "(?i)key", "(?i)credential"]Regex patterns for env vars to exclude from metadata

#Framework flags

These flags are owned by the strictcli framework, not by the app. No command may declare a flag with one of these names, and each is recognized anywhere on the command line.

Framework flags
FlagEffect
--dry-runPreview mode: no mutation runs. The framework prints a log of every effect the command would have performed.
--approve-consequentialSkips the confirmation prompt a consequential command shows before it runs.
--quietHides informational output. Warnings, errors, structured data and the dry-run log are never suppressed.
--verboseShows debug output. --quiet wins when both are passed.

#Infrastructure

#Roots

Roots
Env varDefault
SAFERM_HOME~/.saferm
Search