Skip to main content
skill CX Codex

hook — Claude Code skill: edit guard and installation

hook is a Claude Code skill that toggles a repository edit guard. When enabled, it rejects large edits and a third edit to one file in a turn, then redirects them to a delegate.

MIT ★ 341 updated 2026-11-16

Install into Claude Code · Plugin marketplace All methods and platforms ↓
/plugin marketplace add muaaz9329/cheap-ag
/plugin install cheapag@cheap-agent
Open on GitHub

What hook does

hook turns the repository edit guard on with on and off with off. With the guard enabled, large edits and the third change to one file during a turn are denied and sent to a delegate.

It runs npx -y [email protected] hook with the supplied argument. npx needs network access.

What it helps with

  • enable an edit guard for a repository
  • turn off the guard before editing
  • send a large edit to a delegate

Example prompts for the agent

  • Turn on the repository edit guard with /hook on.
  • Turn off the edit guard with /hook off.
  • Run hook with the on argument.

How to install hook

1Plugin marketplace

/plugin marketplace add muaaz9329/cheap-ag
/plugin install cheapag@cheap-agent

This installs the whole cheapag plugin with all its skills

2Skills CLI (Vercel)

npx skills add muaaz9329/cheap-ag --skill hook -a claude-code

3Manually: put the files in place

~/.claude/skills/hook/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/hook/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about hook

How do I install hook in Claude Code?

Run /plugin marketplace add muaaz9329/cheap-ag, then /plugin install cheapag@cheap-agent. An alternative is npx skills add muaaz9329/cheap-ag --skill hook -a claude-code.

What does hook do?

It switches the repository edit guard on or off. With the guard on, large edits and a third edit to one file in a turn are rejected and redirected to a delegate.

What does hook need to run?

It runs npx -y [email protected] hook, and npx requires network access.

Source text

SKILL.md · MIT
---
name: hook
description: Turn Cheap Agent's edit guard on or off for this repo - when on, Claude's large edits (or a 3rd edit to one file in a turn) are denied and redirected to delegate.
argument-hint: "[on | off]"
disable-model-invocation: true
allowed-tools: Bash(npx -y [email protected] hook) Bash(npx -y [email protected] hook *)
---

!`npx -y [email protected] hook $ARGUMENTS`

The developer ran this command themselves; its output is above. Report it in one line.

Only because the user invoked this skill: If no output appears above (Codex): run that command yourself once, exactly as written, with `$ARGUMENTS` replaced by whatever the user typed after the skill name (or nothing). It needs network for npx; ask for that if the sandbox blocks it. Do not turn the edit guard on or off again or in any other way.

© muaaz9329 · MIT · muaaz9329/cheap-ag

Similar skills

All skills for Agent setup: memory, context, orchestration →

From the same set8

Project sponsors

Companies that keep this analytics open