# Dicklesworthstone/destructive_command_guard

The Destructive Command Guard (dcg) is for blocking dangerous git and shell commands from being executed by agents.

Repository: https://github.com/Dicklesworthstone/destructive_command_guard
Canonical: https://ross.abutalabs.com/products/destructive_command_guard
Language: Rust
License: NOASSERTION
License Family: other
Topics: ai-agents, cli, developer-tools, rust, safety, git
Last push: 2026-08-26T23:00:15+00:00

## Health v2 (maintenance only)
Score: 83/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 99, longevity 17
- inputs: {"age_days": 238, "days_push": 7, "days_rel": 9, "gap_med": 0, "n_releases_24m": 56}
- flags: no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 5840, forks 238 (observed 2026-08-28T04:09:31.461316+00:00)

## What it is
A high-performance Rust CLI hook that intercepts and blocks destructive git and shell commands before AI coding agents execute them. It integrates with tools like Claude Code, Codex CLI, Gemini CLI, Cursor, and Copilot CLI to protect against accidental deletion.

## Use cases
- prevent AI agents from running destructive shell commands
- block dangerous git commands from Claude Code
- protect my repo from accidental deletion by coding agents
- add a safety guard to Codex CLI or Gemini CLI
- stop an AI agent from running rm -rf
- sandbox dangerous commands executed by AI coding assistants

## When to choose
- you use AI coding agents (Claude Code, Codex, Gemini CLI, Cursor, etc.) and want automatic protection from destructive commands
- you want a fast, lightweight Rust-based hook that installs across many agent tools
- you need per-command blocking before execution rather than after-the-fact recovery

## When to avoid
- you need full sandboxing or OS-level isolation of agent processes rather than command filtering
- you don't use AI coding agents and just want general shell safety aliases
- you require a permissively licensed dependency (license is custom)

## Facets
- artifact type: cli-tool
- maturity: active
- function: security, cli, developer-tools
- domain: developer-tools, security
- platform: windows, cli, rust
- tags: ai-agent-hooks, safety, git-protection, claude-code, command-blocking, ai-agents, command-line, linux, macos

## Member repositories
- Dicklesworthstone/destructive_command_guard (main) score 83

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:09:31.461316+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:51:55.351109+00:00, confidence not recorded.
  - readme: https://github.com/Dicklesworthstone/destructive_command_guard (fetched 2026-08-28T04:09:31.461316+00:00, sha 007dc4e2df2d)
  - registry_crates: https://crates.io/api/v1/crates/destructive_command_guard (fetched 2026-08-29T08:47:22.432824+00:00, sha c749e11a97b0)
- Data as of 2026-08-30T08:39:29.467469+00:00.
