Agent skill

scope

Hard-block edits outside declared frozen directories via PreToolUse hook.

majiayu000534★ · 1 repos on radarProfile →
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill scope-boshu2-agentops-3 --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 6 KB
Bundled scripts: none
Requires: []
Path: skills/agent/scope-boshu2-agentops-3/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# /scope — Edit Scope Guard > **Purpose:** Declare which directories are in scope for the current work session. Edits outside the declared scope are hard-blocked by a PreToolUse hook. **YOU MUST EXECUTE THIS WORKFLOW. Do not just describe it.** --- ## Quick Start ```bash /scope freeze cli/cmd/ao/ # Freeze a single directory /scope freeze cli/cmd/ao/ skills/scope/ # Freeze multiple (additive) /scope unfreeze cli/cmd/ao/ # Remove one frozen directory /scope unfreeze # Clear ALL frozen directories /scope status # Show current lock state /scope status --json # JSON output ``` --- ## Behavior Contract When `.agents/scope.lock` declares one or more `frozen_dirs`: - Any `Edit`, `Write`, or `Bash` tool call whose target path is **outside** every frozen directory is **rejected** by `hooks/edit-scope-guard.sh` with a structured stderr reason and a non-zero exit code (Claude Code converts that into a tool-use refusal). - Edits to paths **under** any frozen directory are allowed. - When the lock file is missing OR `frozen_dirs` is empty, the hook short-circuits with exit 0 (no enforcement; allow everything). - The hook fails **open** on malformed JSON or missing target-path fields — do not blo

What's inside
Steps it walks through
  1. Quick Start
  2. Behavior Contract
  3. Subcommands
  4. /scope freeze <dir>...
  5. /scope unfreeze [<dir>]
  6. /scope status [--json]
  7. /scope guard (future combo skill)
  8. Lock File Format
  9. Examples
  10. Freezing scope before a swarm wave
  11. Releasing scope at the end of a wave
  12. Notes
  13. References
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the scope skill do?

Hard-block edits outside declared frozen directories via PreToolUse hook.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill scope-boshu2-agentops-3 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going