zsh-manager

April 19, 2026 · View on GitHub

Visiteurs Platform Shell OMZ License Version

zsh-manager

Unified dispatcher hub for btrfs snapshot and filesystem management on openSUSE Tumbleweed. Central entry point coordinating the snapshot and maintenance plugin ecosystem.


Architecture

⚠️ If the diagram is not visible, refresh the page — Mermaid rendering may take a moment.

flowchart TD
    classDef hub     fill:#1e3a5f,stroke:#93c5fd,stroke-width:2px,color:#ffffff
    classDef native  fill:#14532d,stroke:#86efac,stroke-width:2px,color:#ffffff
    classDef plugin  fill:#78350f,stroke:#fcd34d,stroke-width:2px,color:#ffffff
    classDef stub    fill:#374151,stroke:#9ca3af,stroke-width:1px,color:#d1d5db

    HUB[zsh-manager\nHub — unified dispatcher]:::hub

    HUB --> SNAPMAN[snap-man\nunified menu]:::native
    HUB --> SNAPHELP[snap-help\nall commands]:::native
    HUB --> SNAPDEL[snap-del\ndelete snapshot]:::native
    HUB --> SNAPCMP[snap-compare\ndiff two snapshots]:::native
    HUB --> SNAPIMP[snap-important\nfiltered view]:::native
    HUB --> SNAPMAN2[snap-manual\nfiltered view]:::native

    HUB -->|stub| SL[snap-list\nzsh-snap-list]:::plugin
    HUB -->|stub| SN[snap-new\nzsh-snap-new]:::plugin
    HUB -->|stub| SR[snap-rollback\nzsh-snap-rollback]:::plugin
    HUB -->|stub| BS[btrfs-scrub\nzsh-btrfs-scrub]:::plugin
    HUB -->|stub| BB[btrfs-balance\nzsh-btrfs-balance]:::plugin
    HUB -->|stub| BH[btrfs-health\nzsh-btrfs-health]:::plugin

Requirements

  • openSUSE Tumbleweed
  • zsh 5.9+
  • Oh My Zsh
  • snappersudo zypper install snapper
  • btrfs-progssudo zypper install btrfs-progs

PluginRole
zsh-snap-newguided snapshot creation
zsh-snap-listcolorized snapshot listing
zsh-snap-rollbackinteractive rollback
zsh-btrfs-scrubbtrfs scrub management
zsh-btrfs-balancebtrfs balance management
zsh-btrfs-healthbtrfs health report

Installation

git clone https://github.com/crisis1er/zsh-manager \
  ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-manager

Add zsh-manager to the plugins list in ~/.zshrc:

plugins=(... zsh-manager)

Reload:

source ~/.zshrc

Native commands

CommandDescription
snap-manOpen the unified interactive dispatcher menu
snap-helpList all available commands across the hub and its plugins
snap-del <id>Delete snapshot — displays list if no ID given
snap-compare <id1> <id2>Show files changed between two snapshots
snap-importantDisplay only important=yes snapshots
snap-manualDisplay only manually created snapshots (excludes zypper/timeline)

Multi-config aliases

CommandDescription
snap-list-rootList snapshots for config root
snap-list-homeList snapshots for config home
snap-create-root "desc"Create snapshot in config root
snap-create-home "desc"Create snapshot in config home
snap-cleanupRun snapper cleanup (number algorithm)
snap-cleanup-allRun snapper cleanup all
rollback-lastFast rollback to last snapshot — no confirmation, expert use

Delegated commands (stubs)

If a plugin is not loaded, these functions display an install hint rather than failing silently.

CommandPlugin required
snap-listzsh-snap-list
snap-newzsh-snap-new
snap-rollbackzsh-snap-rollback
btrfs-scrubzsh-btrfs-scrub
btrfs-balancezsh-btrfs-balance
btrfs-balance-thresholdzsh-btrfs-balance
btrfs-snap-sizezsh-btrfs-health
btrfs-healthzsh-btrfs-health

Short aliases

AliasCommand
man-ssnap-man
snap-lsnap-list
snap-nsnap-new
snap-rsnap-rollback
snap-dsnap-del
snap-csnap-compare
snap-hsnap-help

Manual

man zsh-manager

The man page (man/zsh-manager.1) documents all commands, aliases, stubs, and requirements.