Skip to content
Development
Command

/undo

Preview only — no mutation.

From plugin
nyann
641 skills41 commands3 hooks
Install
> /plugin marketplace add thettwe/nyann
> /plugin install nyann@nyann-plugins

How it fires

How this command gets triggered: by you, by Claude, or both.

  • Fires itselfClaude auto-loads it when your prompt matches the work.
  • You can call itInvoke it directly when you want it.
  • Slash command/undo

Context preview

What this command does when you run it.

Preview only — no mutation.

Command definition

undo.md
name: nyann:undo
description: >
  Safely undo the last commit (or last N commits) on a feature branch.
  Always previews first. Refuses main/master/develop, merge commits,
  and pushed commits (override with `--allow-pushed`).
arguments:
  - name: count
    description: Number of commits to undo. Default 1. >3 requires user confirmation.
    optional: true
  - name: strategy
    description: One of `soft` (default; stays staged), `mixed` (unstages), `hard` (discards).
    optional: true
  - name: allow-pushed
    description: Permit undoing a commit already on upstream (force-push required after).
    optional: true
  - name: dry-run
    description: Preview only — no mutation.
    optional: true

**Plugin root:** This is a Claude Code plugin, NOT a CLI tool. Do NOT search via `which`, `npm list`, `pip list`, or `brew list`. This file is at `<plugin_root>/commands/`. All scripts: `<plugin_root>/bin/`. Read the matching `skills/*/SKILL.md` for the full flow.

/nyann:undo

Wraps `bin/undo.sh`. Flow:

1. Dry-run preview. Report which commits will be undone. 2. Confirm (always for non-soft or multi-commit). 3. Reset via `--strategy` (soft/mixed/hard). 4. Report new HEAD + where changes live.

See `skills/undo/SKILL.md` for DISAMBIGUATION against `git revert` (pushed commits) and merge-commit refusal.

Ships withnyann

ငြမ်း is Burmese for scaffolding. Nyann is the Claude Code plugin that picks expert git defaults for your stack — branching, working hooks (Husky / pre-commit.com / lefthook), commits, releases, CI, docs — then keeps the repo on those rails through every PR

Get the whole plugin

Other commands on nyann.