git_reset

Reset Git HEAD to a specified commit using soft, mixed, or hard modes.

8|Updated Mar 16, 2026
One-click install
npx skills add https://github.com/OpenAuthority/clawthority --skill git-reset-openauthority
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: git_reset
Source: https://github.com/OpenAuthority/clawthority/tree/main/examples/skills/git_reset
Command: npx skills add https://github.com/OpenAuthority/clawthority --skill git-reset-openauthority

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Resets the current branch's HEAD to a specific commit by applying a chosen reset mode, enabling you to undo recent work, reframe changes, or discard unwanted commits.

Core Features & Use Cases

  • Reset modes: supports soft, mixed, and hard resets to control HEAD, index, and working tree.
  • Targeted resets: accepts a commit reference to reset to, enabling precise rollback.
  • Return data & warnings: on success returns mode, ref, and message; hard resets include an additional warning about discarded changes.

Quick Start

Reset HEAD to a specific commit in your repository using mode soft, mixed, or hard.

Frequently Asked Questions about git_reset

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I undo the last git commit without losing my changes?▼

A soft git reset moves HEAD to a specified commit while retaining your changes in the index, allowing you to undo commits without losing your modifications.

What is the difference between soft, mixed, and hard git reset modes?▼

Git reset modes control what is discarded: soft moves HEAD only, mixed resets the index but preserves the working tree, and hard discards all uncommitted changes from both the index and working directory.

How do I reset my branch HEAD to a specific commit hash?▼

You can reset your branch HEAD to a specific commit by specifying the commit reference and the desired reset mode, which precisely rolls back the branch pointer to that targeted state.

Does a hard git reset permanently delete uncommitted work?▼

Yes, a hard git reset permanently discards uncommitted changes from both the index and working tree, and the system explicitly returns a warning about discarded changes to caution you.

When should I use a mixed git reset instead of a soft reset?▼

Use a mixed git reset when you want to unstage changes while keeping them in your working directory, whereas a soft reset keeps changes fully staged for immediate recommitting.