Skip to content
Back to skills

Git.Delete

ASecurity

Remove a function, file, or directory from the repo and clean up all references

  • 158 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added November 7, 2026
testinggogit

Security analysis

A100/100

Scanned November 7, 2026

npx -y skills add gpsaggese/helpers --skill git.delete --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Git.Delete?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Git.Delete
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/gpsaggese-git-delete/badge)](https://www.skillsdirectory.com/skills/gpsaggese-git-delete)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
description: Remove a function, file, or directory from the repo and clean up all references
model: haiku
---

# Goal
- Given a target `<SRC>` (function, file, or directory), remove it cleanly, with no
  dangling references or dead code
- Identify what `<SRC>` is before proceeding

# If `<SRC>` Is a Function
- **Remove the function definition** from its source file
- **Find all callers** across the codebase and remove or refactor them
- **Remove orphaned helpers**: recursively remove functions now called only by
  `<SRC>` (or each other)
- **Remove tests** that exclusively test `<SRC>` or its orphaned helpers
- **Clean up imports** that were only needed by the deleted code

# If `<SRC>` Is a File or Directory
- **Remove the file/directory** from the repo
- **Find all references**: any `import`, `from ... import`, `require`, or path
  string pointing to `<SRC>`
- **Remove or refactor each reference**: delete the import and any dependent code,
  or replace it with a substitute if one exists
- **Remove related tests** that exclusively test the removed file/directory
- **Update configs** (e.g. `pyproject.toml`, `setup.py`, `__init__.py`,
  `MANIFEST.in`) that reference `<SRC>`

# After Removal (all Cases)
- Summarize the changes
- Do not commit any change

# Verification
- [ ] Run the test suite to confirm nothing is broken
- [ ] Run a final grep for the removed name to catch remaining references
- [ ] The file `plan.md` says that it was generated by
      `.claude/skills/git.delete/SKILL.md`

# Ask for Help If Unsure How to Do
- If the task is not perfectly clear, you MUST not perform it, but ask for
  clarifications
  - For a complex task, create a `plan.md` with 5 bullet points explaining the plan
  - Say in `plan.md` how it was generated, with this line as the first bullet:
    ```markdown
    - Generated by `.claude/skills/git.delete/SKILL.md`
    ```

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in testing →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.