Skip to content
cccskills
FreePublished on GitHub

git-safety

Stops an agent from destroying uncommitted work with git. Requires git status and git diff before any command that discards changes, treats "revert" and "undo" as manual edits, and never runs reset, checkout, clean, stash drop, or force push without explicit approval. Use when a task involves reverting, undoing, resetting, cleaning, rebasing, or force pushing, or before any git command in a repo with uncommitted changes.

The English summary is being prepared. Showing the original description.

See how to install

Files included (4)

  • SKILL.md3.6 KB
  • agents/openai.yaml91 B
  • assets/large-logo.png3.2 KB
  • assets/small-logo.svg1.2 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

Git safety

These rules exist because one git checkout -- . erased two days of work. Follow them every time, not only when it feels risky.

Before any git command

  1. git status. Read it.
  2. If anything is modified or untracked, stop. Say what is there. Ask before proceeding with anything that could touch those files.
  3. Suggest git stash push -m "<why>" if the user needs a clean tree and wants the work kept.

Commands that need explicit approval

Never run these on your own. Show the exact command, say what it will destroy, and wait for a yes.

CommandWhat it destroys
git reset --hardevery uncommitted change
git checkout -- <file> or git restore <file>uncommitted changes in that file
git checkout -- . or git restore .uncommitted changes in every file
git clean -fdevery untracked file and folder
git stash drop or git stash clearstashed work
git push --force or --force-with-leaseremote history other people may have
git branch -Da branch and any commits only it holds
git rebase on a shared branchcommit ids other people have

"Explicit approval" means the user saw the command and said yes to it. A general "go ahead" from earlier in the conversation does not count.

Revert and undo mean edit

When the user says "revert that", "undo that", or "go back":

  1. Ask which change. Committed or uncommitted? All of it or one part?
  2. git diff <file> to see exactly what would be lost.
  3. Read the current file.
  4. Edit the file by hand to remove the specific lines that are wrong. Keep everything else.
  5. Show the result.

Do not reach for git checkout or git restore. They remove everything in the file, including the parts the user liked.

For committed changes, git revert <sha> is safe because it creates a new commit. Still show the sha and the commit message first.

Diff before discard

Any time a change is about to be thrown away, the user sees git diff output for it first. No exceptions. If the diff is long, show git diff --stat and offer the full diff.

Commits, pushes, deploys

Do not commit, push, tag, publish, or deploy unless the user asks in the current message. When the work is done, print a suggested commit message and stop.

Suggested commit:
fix: dedupe heartbeat writes within 10s window

Safe defaults

These are fine to run without asking:

  • git status, git log, git diff, git show, git blame
  • git stash push -m "<message>" when the user asked for a clean tree
  • git add <specific files> when the user asked to commit
  • git checkout -b <new-branch> from a clean tree
  • git revert <sha> after showing the commit

Checklist

Before a git command:

  • git status ran and I read it
  • no uncommitted work is in the blast radius, or the user approved
  • I showed git diff for anything being discarded
  • the command is not in the approval table, or the user said yes to this exact command

When asked to revert or undo:

  • I know which change and whether it is committed
  • I am editing the file, not checking it out
  • everything the user did not mention stays

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

Keeps a change scoped to what was asked. Flags extra features, refactors, and 'while we are here' edits, and moves them to a suggestions list instead of the diff. Use when a request is small and the agent is about to expand it, when a PRD grows beyond its problem statement, or when the user says 'just do what I asked'.

The English summary is being prepared. Showing the original description.

waynesutton/builder-skills406Updated Sep 28, 2026

convex

Free

Routes Convex work to the right builder skill and covers the handful of rules that apply everywhere: validators on every function, withIndex over filter, idempotent mutations, internal functions for scheduling. Use when a task mentions Convex and no more specific skill matches, or as the first stop before picking one.

The English summary is being prepared. Showing the original description.

waynesutton/builder-skills406Updated Sep 28, 2026

Builds AI agents on the Convex agent component: threads, messages, tools that call queries and mutations, streaming, RAG with vector search, and workflows for multi step jobs. Use when adding a chat assistant, tool calling agent, or retrieval feature to a Convex app.

The English summary is being prepared. Showing the original description.

waynesutton/builder-skills406Updated Sep 28, 2026

Production patterns for Convex apps and the rules the @convex-dev/eslint-plugin enforces: validators, indexes, idempotent mutations, avoiding OCC conflicts, thin function wrappers, error handling. Use when reviewing Convex code, asking whether a pattern is right, setting up ESLint, or fixing write conflicts and slow queries.

The English summary is being prepared. Showing the original description.

waynesutton/builder-skills406Updated Sep 28, 2026

Creates reusable Convex components with defineComponent, a clean client wrapper, their own schema, and an npm publish setup. Use when extracting a feature into a package, building something for the Convex component directory, or when a component's functions are not showing up in the parent app.

The English summary is being prepared. Showing the original description.

waynesutton/builder-skills406Updated Sep 28, 2026

Schedules work in Convex: cron jobs in convex/crons.ts, one off scheduled functions with runAfter and runAt, batching large jobs, and cancelling or inspecting the queue. Use when something needs to run on a timer, later, or in the background, or when a cron is not firing.

The English summary is being prepared. Showing the original description.

waynesutton/builder-skills406Updated Sep 28, 2026

See all skills by waynesutton

Report a problem with this skill