guard

guard is a command for Claude Code from YuDefine/nuxt-supabase-starter. It costs 9 tokens per session (339 once invoked), scanned C, original, MIT.

A safety dashboard command for showing protected project paths, custom frozen paths, and commands that require extra confirmation. A frozen path is a file or folder that should not be changed without deliberate action.

In plain words
What is it for?
Use it to review repository safeguards, including database migrations, deployment settings, environment files, and dangerous Git or shell commands.
Why use it?
It makes sensitive files and risky operations visible before an agent changes or deletes something important.

Command for Claude Code

Written for Claude Code: installed under .claude/.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/yudefine/nuxt-supabase-starter/guard
Clone the repo
git clone --depth 1 https://github.com/YuDefine/nuxt-supabase-starter

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for guard

README.md
[![agentmods](https://agentmods.dev/badge/commands/yudefine/nuxt-supabase-starter/guard.svg)](https://agentmods.dev/commands/yudefine/nuxt-supabase-starter/guard)
Your own site
<a href="https://agentmods.dev/commands/yudefine/nuxt-supabase-starter/guard"><img src="https://agentmods.dev/badge/commands/yudefine/nuxt-supabase-starter/guard.svg" alt="Measured on agentmods" height="20"></a>
Per session 9 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 339 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00009 $0.00339
Opus 5 $0.00005 $0.00169
Sonnet 5 $0.00002 $0.00068
Haiku 4.5 $0.00001 $0.00034

Measured 6d ago against content hash 9d0b856b8e60, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade C, and why

guard scanned grade C with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

- `rm -rf`
template/.claude/commands/guard.md · 50 lines

What it actually says

/guard — 安全護欄 Dashboard

顯示內容

1. 永久保護路徑

這些路徑由 guard-check.mjs 硬編碼,無法解凍:

  • supabase/migrations/ — 已套用的 migration 不可修改
  • .github/workflows/ — CI/CD 配置需人工審查
  • .env / .env.* — 環境變數需人工管理
  • wrangler.jsonc / wrangler.toml — 部署配置需人工審查

2. 自訂凍結路徑

讀取 .claude/guard-state.json 並列出 frozen_paths

3. 危險指令警告

提醒以下指令需要額外確認:

  • git push --force
  • git reset --hard
  • rm -rf
  • supabase db push(production)

輸出格式

## 🛡️ Guard Status

### 永久保護
- 🔒 supabase/migrations/
- 🔒 .github/workflows/
- 🔒 .env / .env.*
- 🔒 wrangler.jsonc

### 自訂凍結
- 🧊 <path> (since <date>)
- (無)

### 管理
- 凍結: /freeze <path>
- 解凍: /unfreeze <path>
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 50 lines · 9 tokens per session scan C 9d0b856b8e60

Subscribe to this mod's changes

guard is a command published in the GitHub repository YuDefine/nuxt-supabase-starter (45 stars, last pushed today), licensed MIT. It adds 9 tokens to every session and 339 once invoked, about $0.0000 per session on Opus 5. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.