Skip to content
Skills Library
AI & agents · Automation

guard

/guard

Activate both careful mode and freeze mode together. Blocks destructive commands and scope-locks editing to the specified pattern. Use for production-critical debugging sessions.

Licence
MIT
Last repository change
14.10.2026

Assessment and security

100/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content35 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
1
Scripts
0
HTML comments
0
URLs in SKILL.md
0
Deprecation

No signals detected. Repository changed on 14.10.2026, without references to retired models or APIs.

Licence

MIT, open: use and modify while retaining author attribution.

What it does and when to use it

Activate both careful mode and freeze mode together. Blocks destructive commands and scope-locks editing to the specified pattern. Use for production-critical debugging sessions.

Arguments

/guard <glob-pattern>
Original author description

Activate both careful mode and freeze mode together. Blocks destructive commands and scope-locks editing to the specified pattern. Use for production-critical debugging sessions.

How it works

  1. Worker constraints
  2. Parse Arguments
  3. Steps
Original SKILL.md headings · 66 lines, 228 words
SKILL.md preview
---
name: guard
description: >-
  Activate both careful mode and freeze mode together. Blocks destructive
  commands and scope-locks editing to the specified pattern. Use for
  production-critical debugging sessions.
argument-hint: "<glob-pattern>"
user-invocable: true
allowed-tools: Write, Read
---

# Guard

Role: worker. Combined safety mode: careful + freeze.

You have been invoked with the `/guard` command.

## Worker constraints

1. Compose /careful + /freeze; introduce no new blocking behavior.
2. Do not edit source.
3. **Be concise.** Confirm both modes in one line each.

## Parse Arguments

Arguments: $ARGUMENTS

- Positional: `<glob-pattern>` (required) — glob pattern for files that ARE allowed to be edited

If no pattern is provided, display usage and exit:
> Usage: `/guard <glob-pattern>`
> Example: `/guard src/auth/**` — blocks destructive commands AND limits edits to `src/auth/`.
> Use `/careful off` and `/unfreeze` separately to disable, or pass `off` to disable both.

If argument is `off`:

1. Remove `.claude/hooks/careful-state.json` and `.claude/hooks/freeze-state.json`
2. Display: "Guard mode OFF. All safety restrictions lifted."

## Steps

### 1. Enable careful mode

Write to `.claude/hooks/careful-state.json` (repo-scoped — see the `/careful`
skill's Notes for why this is not `hooks/careful-state.json`; issue #1900):

```json
{
  "active": true,
  "enabled_at": "<ISO timestamp>"
}
```

### 2. Enable freeze mode

Write to `.claude/hooks/freeze-state.json` (repo-scoped — see the `/freeze`
skill's Notes for why this is not `hooks/freeze-state.json`; issue #1890):

```json
{
  "active": true,
  "allowed_patterns": ["<glob-pattern>"],
  "frozen_at": "<ISO timestamp>"
}
```

### 3. Confirm

Display:
> Guard mode ON.
>
> - Destructive commands: BLOCKED
> - File editing: Locked to `<pattern>`
>
> Use `/guard off` to disable both, or `/careful off` / `/unfreeze` individually.

Versions

RepositoryScoreLicence
This page · bdfinst/agentic-dev-team100MIT
frankxai/agentic-creator-os100Apache-2.0
darioabc/massimo100MIT
onlypfachi/chief100MIT
houseofmvps/ultraship100MIT
ruya-ai/cozempic100MIT
tranhieutt/software_development_department100MIT
sharpdeveye/maestro100MIT
frankxai/agentic-creator-os95Apache-2.0

Database snapshot: 13.11.2026 · package version 64a8b0be5a0b (SHA-256 digest of the entire package)

Downloads in the last 30 days: 4 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 100safety-guard
    Guard against destructive operations with three modes: Careful intercepts dangerous commands (rm -rf, git push --force, DROP TABLE) for confirmation, Freeze locks writes to one directory, and Guard combines both via PreToolUse hooks. Use when working on production systems,…
  • 100freeze
    Restrict file edits to a specific directory for the session. Blocks Edit and Write outside the allowed path. Use when debugging to prevent accidentally "fixing" unrelated code, or when you want to scope changes to one module. Use when asked to "freeze", "restrict edits", "only…
  • 100director
    Enters director mode: this session runs the board instead of the code. It shows open runs, their frontier, open decisions and rollups, answers decisions, and delegates every read or edit to background agents and coordinators. A guard hook blocks file reads, edits, foreground…
  • 100safety-guard
    Guard against destructive operations with three modes: Careful intercepts dangerous commands (rm -rf, git push --force, DROP TABLE) for confirmation, Freeze locks writes to one directory, and Guard combines both. Advisory: the agent applies these rules itself; no hook ships with…
  • 100low-token-mode
    Terse-response mode for the rest of the session. Use for "low token mode", "save tokens", "be concise". Not for a one-off "keep it short".
  • 100freeze
    Restrict file edits to a specific directory for the session. Blocks Edit and Write outside the allowed path. Use when debugging to prevent accidentally "fixing" unrelated code, or when you want to scope changes to one module. Use when asked to "freeze", "restrict edits", "only…

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.