Agent skill
cfn-edit-safety
Pre-edit backup and post-edit validation for safe file modifications. Use when you need to capture file state before edits, validate changes after modifications, revert files to previous state, or ensure edit safety with automatic backup and validation hooks.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/data/cfn-edit-safety
SKILL.md
Edit Safety Skill (Mega-Skill)
Version: 1.0.0 Purpose: Pre-edit backup and post-edit validation Status: Production Consolidates: cfn-hook-pipeline, pre-edit-backup Confidence: 8.5/10 (mandatory paired workflow in CLAUDE.md)
Overview
This mega-skill provides complete edit safety:
- Backup - Pre-edit file state capture for revert capability
- Hooks - Post-edit validation and feedback pipeline
Directory Structure
edit-safety/
├── SKILL.md
├── lib/
│ ├── backup/ # From pre-edit-backup
│ └── hooks/ # From cfn-hook-pipeline
└── cli/
Workflow
- Pre-edit:
edit-safety/lib/backup/captures file state - Edit occurs
- Post-edit:
edit-safety/lib/hooks/validates changes - If needed: Revert via backup
Migration Paths
| Old Path | New Path |
|---|---|
| pre-edit-backup/ | edit-safety/lib/backup/ |
| cfn-hook-pipeline/ | edit-safety/lib/hooks/ |
Version History
1.0.0 (2025-12-02)
- Consolidated backup + hooks into unified edit safety skill
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?