guard

Monitor and restrict destructive commands and directory-scoped edits in Bash scripts.

Updated May 28, 2026
One-click install
npx skills add https://github.com/limzivector/SEO --skill guard-limzivector
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: guard
Source: https://github.com/limzivector/SEO/tree/main/gstack/guard
Command: npx skills add https://github.com/limzivector/SEO --skill guard-limzivector

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires bash, and includes scripts (resource) components.

What problem does it solve?

This Skill provides an additional layer of safety by warning about potentially destructive commands and restricting edits to a specified directory, reducing the risk of accidental damage to files or systems.

Core Features & Use Cases

  • Destructive Command Warnings: Alerts before executing harmful commands like 'rm -rf' or 'DROP TABLE'.
  • Directory-Scope Edits: Blocks file edits outside of a specified directory.
  • Use Case: When performing sensitive operations on a production server or working with critical data, this Skill can help prevent unintended data loss or corruption.

Quick Start

Enter 'guard' followed by the directory you want to restrict edits to, like 'guard /path/to/directory'.

Frequently Asked Questions about guard

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

FAQPage Schema
How do I prevent accidental execution of destructive bash commands?

To prevent accidental execution of destructive bash commands, you need a validation mechanism that monitors operations and alerts you before executing harmful commands like 'rm -rf' or 'DROP TABLE'. This adds a safety layer to reduce unintended system damage.

Can I restrict file edits to a specific directory in bash?

Yes, you can restrict file edits to a specific directory in bash by enforcing directory-scoped restrictions. This blocks any file modifications occurring outside your specified target path, ensuring sensitive files remain untouched during operations.

What is directory-scoped edit restriction for sensitive operations?

Directory-scoped edit restriction is a safety mechanism that confines file modifications to a single approved path. It prevents unintended changes to critical data by blocking write operations outside the defined directory boundary during sensitive tasks.

How do I set up command validation for a production server?

To set up command validation for a production server, apply a safety mode that warns about destructive commands and restricts edits to a specified directory. Enter your restriction command followed by the target directory path to activate it.

Does the guard skill require bash to run?

Yes, the guard skill requires bash to run because it relies on bash scripts to perform command validation and enforce directory restrictions. You must have a bash environment available to execute its safety protocols.

What are the limitations of using bash scripts for command validation?

A limitation of using bash scripts for command validation is that safety enforcement depends strictly on the bash environment. It acts as an additional safety layer rather than a root-level system lock, meaning it cannot prevent damage from commands executed outside its monitored scope.