guard
Skill8 starsChanged 6 months agoMITView on GitHub
Full safety mode for prod work: warn before destructive commands and block edits outside one directory.
- Deletes or force-pushes
52 other projects use a version of this, 25 of them edited.
Adopted by
Most recently taken up by
- hiroqt/overdrivetheir own version, first seen Nov 1, 2026
- matthewdigiuseppe/MStacktheir own version, first seen Nov 1, 2026
- trungtm78/ClaudeSkillsedited, first seen Oct 25, 2026
- L1veSong/Canon-Mnemonic-Guardtheir own version, first seen Oct 19, 2026
- autonomous-ai/lampOStheir own version, first seen Oct 15, 2026
- rcelebrone/DotAgentstheir own version, first seen Oct 14, 2026
Used with
Projects with it also use ios-clean, ios-fix and 4 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
Saqlain-811Skillios-clean
Remove the DebugBridge SPM package and all #if DEBUG wiring from an iOS app. (gstack)
Also in 5 projects that use this
Saqlain-811Skillios-fix
Autonomous iOS bug fixer. (gstack)
Also in 5 projects that use this
seek888Skillopen-gstack-browser
Launch GStack Browser — AI-controlled Chromium with the sidebar extension baked in. Opens a visible browser window where you can watch every action in real time. The sidebar shows a live activity feed and chat. Anti-bot stealth built in. Use when asked to "open gstack browser", "launch browser", "connect chrome", "open chrome", "real browser", "launch chrome", "side panel", or "control my browser". Voice triggers (speech-to-text aliases): "show me the browser".
Also in 9 projects that use this
ShreyRaviSkillsetup-gbrain
Set up gbrain for this coding agent: install the CLI, initialize a local PGLite or Supabase brain, register MCP, capture per-remote trust policy. One command from zero to "gbrain is running, and this agent can call it." Use when: "setup gbrain", "connect gbrain", "start gbrain", "install gbrain", "configure gbrain for this machine". (gstack)
Also in 6 projects that use this
ShreyRaviSkillsync-gbrain
Keep gbrain current with this repo's code and refresh agent search guidance in CLAUDE.md. Wraps the gstack-gbrain-sync orchestrator with state probing, native code-surface registration, capability checks, and a verdict block. Re-runnable, idempotent. Use when: "sync gbrain", "refresh gbrain", "re-index this repo", "gbrain search isn't finding things". (gstack)
Also in 6 projects that use this
- +1 more from Saqlain-811
Other versions52 projects use a version of this.
Word for word · 0
None found.
Edited · 25
- garrytan/gstack★ 141k34% same
- mr-daedalium/ostack-saas★ 10836% same
- no-session/pstack★ 9633% same
- lucas-flatwhite/gstack-ko★ 4531% same
- CarbeneAI/Forge★ 933% same
- Samin12/skills★ 824% same
- GTMify/claude-skills-starter★ 233% same
- HanksChen0110/skills★ 233% same
- chloropine/cgstack★ 132% same
- IyedBecheikh/bstack★ 132% same
15 more not listed
Wrote their own version · 27
- DenchHQ/DenchClaw★ 1.7ksame name
- DenchHQ/ironclaw★ 1.7ksame name
- autonomous-ai/autonomous-os★ 552same name
- autonomous-ai/lampOS★ 552same name
- autonomous-ai/Physical-AI-Operating-System★ 552same name
- garagon/nanostack★ 206same name
- tranhieutt/software_development_department★ 71same name
- AICreator-Wind/gstack-openclaw-skills★ 44same name
- matthewdigiuseppe/MStack★ 17same name
- YehudaFrankel/clankbrain★ 16same name
17 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository62 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- address-pr-reviewSkill
- agent-evalSkill
- ai-cost-guardSkill
- autoplanSkill
- aws-costSkill
- bedrock-guardrailsSkill
- benchmarkSkill
- browseSkill
- canarySkill
- carefulSkill
- claudeSkill
- codexSkill
- connect-chromeSkill
- connect-reviewSkill
- context-restoreSkill
- context-saveSkill
- csoSkill
- design-consultationSkill
- design-htmlSkill
- design-reviewSkill
- design-shotgunSkill
- devex-reviewSkill
- diagramSkill
- document-generateSkill
- document-releaseSkill
- freezeSkill
- healthSkill
- iac-reviewSkill
- improve-archSkill
- investigateSkill
- kb-reviewSkill
- land-and-deploySkill
- landing-reportSkill
- learnSkill
- make-pdfSkill
- mcp-reviewSkill
- office-hoursSkill
- open-browserSkill
- pair-agentSkill
- plan-ceo-reviewSkill
- plan-design-reviewSkill
- plan-devex-reviewSkill
- plan-eng-reviewSkill
- plan-tuneSkill
- pr-summarySkill
- qa-onlySkill
- qaSkill
- retroSkill
- reviewSkill
- scrapeSkill
- setup-browser-cookiesSkill
- setup-deploySkill
- shipSkill
- skillifySkill
- specSkill
- telegramSkill
- unfreezeSkill
- unslopSkill
- vibe-gcSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
4 rules. 1 is common, 1 is distinctive, and 2 are very specific to this project.
1
Common
Most of the 41 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 50
If this session was compacted, the copy of this skill in context may be cut off.
- Very specific: line 51
Read ${CLAUDE_SKILL_DIR}/SKILL.md from disk and resume at the step you are on.
- Distinctive: line 55
Use when asked to "guard mode", "full safety", "lock it down", or "maximum safety".
- Common: line 80
Ask the user which directory to restrict edits to:
“Common” is measured: kept by at least 6 in 10 of the 41 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
If this session was compacted, the copy of this skill in context may be cut off.
Read ${CLAUDE_SKILL_DIR}/SKILL.md from disk and resume at the step you are on.
When to invoke
Use when asked to "guard mode", "full safety", "lock it down", or "maximum safety".
/guard — Full Safety Mode
Activates both destructive command warnings and directory-scoped edit restrictions.
This is /careful + /freeze in a single command.
Dependency note: This skill references hook scripts from the sibling /careful and /freeze skill directories. Both must be installed (they are installed together by the vibestack install script).
Where this is enforced. Both protections run as Claude Code PreToolUse
hooks. Cursor, Kiro and Codex install the same skill, but the hooks are not
guaranteed to run there; outside Claude Code /guard is instruction-only. On
those hosts, tell the user guard mode is advisory: you will confirm before a
destructive command and keep your own edits inside the boundary, but nothing
blocks a tool call you get wrong.
Copilot CLI is the exception. When the configuration payload is installed
(./install --with-config or --only=config), the user hook file
~/.copilot/hooks/vibestack.json (under $COPILOT_HOME when set) enforces
both halves: the destructive-command and gate-file check is always on, in every
session, and the edit boundary blocks while a freeze directory is set. Without
the configuration payload it is instruction-only there as well.
Setup
Ask the user which directory to restrict edits to:
"Guard mode: which directory should edits be restricted to? Destructive command warnings are always on. Files outside the chosen path will be blocked from editing."
Once the user provides a path, set it with the shared state writer (see
/freeze):
bash "${CLAUDE_SKILL_DIR:-$HOME/.claude/skills/guard}/../freeze/bin/freeze-state.sh" set "<user-provided-path>"Report guard mode active only if the command exits 0 and prints FREEZE_DIR=.
On FREEZE_ERROR (a mistyped or missing path, or /), tell the user no edit
boundary was set and ask for the path again. On FREEZE_BUSY, retry once the
other writer finishes; never write or delete the state file directly.
Tell the user:
- "Guard mode active. Two protections are now running:"
- "1. Destructive command guard — Bash and PowerShell: rm -rf, Remove-Item -Recurse, DROP TABLE, force-push, etc. warn before executing (you can override); catastrophic shapes (recursive delete of
/or~, force-push to the default branch) are blocked outright; an Edit or Write to a gate file (lint, type-check, CI or migration config) also warns" - "2. Edit boundary — Edit, Write and NotebookEdit restricted to
<FREEZE_DIR>/. Edits outside this directory are blocked." - "The edit boundary is saved in
~/.vibestack/freeze-dir.txtand outlives this session: any later session that loads the freeze hook (/freeze,/guard,/investigate) enforces it again. To remove it, run/unfreeze. Ending the session turns off the destructive command guard only."
What's protected
See /careful for the two decision tiers, the full pattern list, and the safe exceptions.
See /freeze for how edit boundary enforcement works.
Both hooks fail safe when they cannot read a tool payload — /careful asks,
/freeze denies. Guard mode runs both, so an unreadable Edit, Write or
NotebookEdit payload is blocked, not waved through.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

