careful

Warn before destructive commands via a PreToolUse hook.

Updated Apr 1, 2026
One-click install
npx skills add https://github.com/whd4/gstack --skill careful-whd4
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: careful
Source: https://github.com/whd4/gstack/tree/main/careful
Command: npx skills add https://github.com/whd4/gstack --skill careful-whd4

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Safety guardrails for destructive commands. Warns before rm -rf, DROP TABLE, force-push, git reset --hard, kubectl delete, and similar destructive operations. User can override each warning. Use when touching prod, debugging live systems, or working in a shared environment. Use when asked to "be careful", "safety mode", "prod mode", or "careful mode".

Core Features & Use Cases

  • Destructive-command detection and warning before execution.
  • Granular allow/override controls per command.
  • Auditable usage analytics and session safety.

Quick Start

Enable careful mode before running potentially destructive commands to see warnings and decide whether to proceed.

Frequently Asked Questions about careful

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

FAQPage Schema
How do I get a warning before running destructive bash commands like rm -rf?▼

Careful mode intercepts destructive bash commands like rm -rf via a PreToolUse hook, returning a warning and prompt instead of executing. It prevents accidental data loss during production maintenance and debugging in shared environments.

Can I override the safety warning if I need to force push or reset git?▼

Yes, you can override the safety warning on a per-command basis. When careful mode intercepts a destructive action like git reset --hard, it prompts you, providing granular allow controls to proceed if you decide the operation is safe.

What destructive operations does careful mode detect in production environments?▼

Careful mode detects destructive operations including rm -rf, DROP TABLE, force-push, git reset --hard, and kubectl delete. It scans for these patterns during production maintenance to prevent accidental data loss.

Does this safety guardrail work for database commands like DROP TABLE?▼

Yes, the safety guardrail works for database commands like DROP TABLE. It implements guardrails via a PreToolUse hook that scans for destructive SQL patterns, returning a warning and prompt to prevent accidental data loss.

How do I enable safety mode when debugging live systems?▼

Enable safety mode before running potentially destructive commands when debugging live systems. The guardrail activates via a PreToolUse hook to scan for destructive actions, ensuring you receive warnings and can decide whether to proceed.

When should I not use destructive command guardrails in bash?▼

You should not use destructive command guardrails if you require fully automated, uninterrupted execution of scripts containing operations like kubectl delete. The per-command override prompt requires manual intervention, halting automated workflows.