Skip to content
Development
Command

/undo

Undo last commit safely. Use for undo commit, revert, uncommit, cancel commit.

From plugin
fusengine-claude-plugins
3434 skills40 agents34 commands
$ npx -y skills add fusengine/claude-plugins --agent claude-code

Command definition

undo.md
description: Undo last commit safely. Use for undo commit, revert, uncommit, cancel commit.
argument-hint: --soft | --mixed | (empty for soft reset)
allowed-tools: Bash(git status:*), Bash(git log:*), Bash(git reset:*), Bash(git revert:*)
disable-model-invocation: false

Undo Last Commit

Current State

!`git status`

Last Commit

!`git log -1 --pretty=format:'%h %s'`

Remote Status

!`git log origin/HEAD..HEAD --oneline 2>/dev/null || echo "No remote tracking"`

Instructions

Safely undo the last commit while keeping changes.

Security Check (MANDATORY)

IF the last commit is already pushed to remote:

  • **REFUSE** to reset
  • Explain: "Cannot undo pushed commits with reset."
  • Suggest: `git revert HEAD` to create a reverting commit
  • Ask confirmation before executing revert

IF the last commit is NOT pushed: 1. Ask confirmation: "Undo last commit? Changes will be kept." 2. Determine mode:

  • `--soft` (default): Keep changes staged
  • `--mixed`: Keep changes unstaged

3. Execute: `git reset $ARGUMENTS HEAD~1` 4. Show result with `git status`

Options

| Flag | Effect | |------|--------| | `--soft` | Keep changes staged (default) | | `--mixed` | Keep changes unstaged |

@fusengine
Ships withfusengine-claude-plugins

A plugin ecosystem that turns Claude Code into a supervised, multi-agent development environment.

34200 skills40 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
34
Star history of fusengine/agents on GitHub, a chart by star-history.com

Other commands on fusengine-claude-plugins.

apex

apex

Command

APEX Methodology - The systematic Analyze-Plan-Execute-eLicit-eXamine approach for intelligent development. Reduces hallucination…

More commands from other plugins.

build
Auto-invoked

build

Command

Implement tasks incrementally — build, test, verify, commit. Add "auto" to run the whole plan in one approved pass.

@addyosmani@addyosmaniInstall Command