Help us improve
Share bugs, ideas, or general feedback.
Share bugs, ideas, or general feedback.
Share bugs, ideas, or general feedback.
By choam2426
Displays project-specific prompts and risk-level assessments before executing bash commands, automating safety checks for command-line workflows
npx claudepluginhub choam2426/CmdLens --plugin cmdlensA Claude Code plugin that automatically explains commands before execution.
Every Bash command is displayed with risk level and recovery instructions. 한국어
| Before | After |
|---|---|
![]() | ![]() |
| Before | After |
|---|---|
![]() | ![]() |
# Add marketplace
/plugin marketplace add choam2426/CmdLens
# Install plugin
/plugin install cmdlens@cmdlens-marketplace
git clone https://github.com/choam2426/CmdLens.git
cp -r CmdLens/plugins/cmdlens ~/.claude/plugins/
Session Start
↓
SessionStart Hook → Inject description guide to Claude
↓
User requests task
↓
Claude prepares Bash command with description
↓
PreToolUse Hook → Display risk/recovery via systemMessage
↓
Command executes
Hybrid Approach: Combines SessionStart (behavior modification) and PreToolUse (display) for consistent, reliable output.
| Level | Icon | Description | Examples |
|---|---|---|---|
| Safe | 🟢 | Read-only, info query | ls, cat, pwd, git status |
| Caution | 🟡 | File modification | mv, cp, chmod, git commit |
| Danger | 🔴 | Deletion, system change | rm -rf, sudo, git push --force |
CmdLens/
├── .claude-plugin/
│ └── marketplace.json
├── plugins/
│ └── cmdlens/
│ ├── .claude-plugin/
│ │ └── plugin.json
│ ├── hooks/
│ │ ├── hooks.json
│ │ ├── session_start.py
│ │ └── pre_tool_use.py
│ └── prompts/
│ └── description_guide.md
├── docs/
│ └── PRD.md
└── README.md
Executes bash commands
Hook triggers when Bash tool is used
Share bugs, ideas, or general feedback.
Based on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Smart command safety filter for Claude Code — parses shell pipelines and evaluates per-command safety rules to auto-approve safe commands and block dangerous ones
Intelligent command history tracking with automatic failure detection. Tracks all bash commands Claude runs (successful and failed) with semantic directory aliasing and command mapping.
5 essential safety hooks for Claude Code. Blocks rm -rf, force-push, hard-reset, .env overwrites, and package publish. The minimum viable safety net from 800+ hours of autonomous operation.
Achieve flow state safely with Claude Code. Auto-approves routine work, gates risky actions, hard-blocks dangerous patterns. Dual enforcement (skill + hooks), token cap for cost governance, full audit trail. Zero dependencies.
Safety hooks to block or require user approval for dangerous commands (rm, git operations, .env access, file size limits)
PreToolUse hook that auto-approves safe Bash commands by parsing them into an AST and matching against configurable patterns
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge.
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge.
Sign in to claim