guard

Warn before destructive commands and restrict edits to a specified directory.

Updated Jun 12, 2026
One-click install
npx skills add https://github.com/Kushal9889/claude-plugins --skill guard-kushal9889
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: guard
Source: https://github.com/Kushal9889/claude-plugins/tree/main/gstack/skills/guard
Command: npx skills add https://github.com/Kushal9889/claude-plugins --skill guard-kushal9889

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This Skill ensures safety during system operations by providing warnings for destructive commands and restricting edits to a specified directory, preventing accidental damage.

Core Features & Use Cases

  • Destructive Command Warnings: Warns before executing commands like rm -rf, DROP TABLE, and force-pushes.
  • Directory-Scope Edits: Blocks edits outside a specified directory, maintaining data integrity.
  • Use Case: When working on production systems or debugging live environments, this Skill helps avoid critical mistakes.

Quick Start

Set up guard mode by specifying the directory to restrict edits to and enable full safety mode.

Frequently Asked Questions about guard

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

FAQPage Schema
How do I prevent accidental destructive commands in production environments?

To prevent destructive commands in production environments, use safety scripts that monitor system operations and trigger warnings before executing actions like rm -rf or DROP TABLE. This ensures command checking and avoids critical mistakes.

How can I restrict file edits to a specific directory during live system debugging?

You can restrict file edits to a specific directory by enforcing directory boundary rules via Bash scripts. This directory-scope enforcement blocks unauthorized edits outside the permitted path, maintaining data integrity during live debugging.

Does this command checking tool require any external dependencies to run?

No, this command checking tool requires no external dependencies. It operates using built-in Bash scripts to enforce directory boundaries and provide destructive command warnings without needing additional software packages.

What is the best way to warn against force-pushes and database drops during system administration?

The best way to warn against force-pushes and database drops is to implement a safety monitoring script that intercepts these destructive commands. It alerts administrators before execution, preventing unauthorized system modifications.

Can I use directory protection scripts for general software development tasks?

Yes, you can use directory protection scripts for general software development tasks. The tool applies to scenarios requiring enhanced safety measures, restricting edits and checking commands to maintain integrity across live systems.

When should I not rely on directory-scope edits for system protection?

You should not rely solely on directory-scope edits when your operations require modifying files outside the specified boundary. The tool strictly blocks external edits, meaning global system updates will fail unless the boundary is reconfigured.