skills/engineering/patch/SKILL.md
Language-agnostic code generation and change propagation. Use this skill when adding fields to entities, renaming symbols across files, or propagating changes that affect multiple files. Use when: "add field", "rename everywhere", "propagate change", "generate migration", "update all references". This is the CODE MUTATION counterpart to wicked-garden:search (which is read-only).
npx skillsauth add mikeparcewski/wicked-garden patchInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Generate and propagate code changes across your entire codebase using the symbol graph.
# 1. Index your codebase (if not already done)
/wicked-garden:search:index /path/to/project
# 2. Add a field to an entity
/wicked-garden:engineering:add-field "Entity.java::User" --name email --type String
# 3. Rename a field everywhere
/wicked-garden:engineering:rename "Entity.java::User" --old status --new state
# 4. See propagation plan
/wicked-garden:engineering:plan "Entity.java::User" --change add_field
| Command | Purpose |
|---------|---------|
| /wicked-garden:engineering:plan | Show what would be affected |
| /wicked-garden:engineering:add-field | Add field with propagation |
| /wicked-garden:engineering:rename | Rename across all usages |
| /wicked-garden:engineering:remove | Remove field everywhere |
| /wicked-garden:engineering:apply | Apply saved patches |
| Extension | Features |
|-----------|----------|
| .java | JPA @Column, getters/setters, validation |
| .py | SQLAlchemy, Pydantic, dataclass |
| .ts, .js | TypeORM, interfaces, types |
| .jsp | Spring form tags, EL expressions |
| .sql | ALTER TABLE (PostgreSQL, Oracle, MySQL, SQL Server) |
ChangeSpec (add field "email" to User)
│
▼
┌───────────────────┐
│ Propagation Engine │ ← Uses wicked-garden:search lineage graph
└───────────────────┘
│
┌──────┼──────┬──────────┐
▼ ▼ ▼ ▼
Java Python SQL JSP
│ │ │ │
▼ ▼ ▼ ▼
Patches Patches Patches Patches
/wicked-garden:engineering:add-field "User.java::User" \
--name email \
--type String \
--column USER_EMAIL \
--required
Generates:
// User.java
@Column(name = "USER_EMAIL")
@NotNull
private String email;
public String getEmail() { return this.email; }
public void setEmail(String email) { this.email = email; }
-- migration.sql
ALTER TABLE USERS ADD COLUMN USER_EMAIL VARCHAR(255) NOT NULL;
/wicked-garden:engineering:rename "Order.java::Order" --old status --new orderStatus
Updates:
${order.status} → ${order.orderStatus})# Generate patches without applying
/wicked-garden:engineering:add-field SYMBOL --name foo --type String --output patches.json
# Review the patches file
cat patches.json
# Apply when ready
/wicked-garden:engineering:apply patches.json
Generic types are automatically mapped per language:
| Generic | Java | Python | TypeScript | SQL |
|---------|------|--------|------------|-----|
| string | String | str | string | VARCHAR(255) |
| integer | Integer | int | number | INTEGER |
| boolean | boolean | bool | boolean | BOOLEAN |
| date | LocalDate | date | Date | DATE |
| datetime | LocalDateTime | datetime | Date | TIMESTAMP |
| decimal | BigDecimal | Decimal | number | DECIMAL(18,2) |
Auto-detected or specify via --dialect:
-- PostgreSQL (default)
ALTER TABLE users ADD COLUMN email VARCHAR(255);
-- Oracle
ALTER TABLE users ADD (email VARCHAR2(255));
-- MySQL
ALTER TABLE users ADD COLUMN email VARCHAR(255);
-- SQL Server
ALTER TABLE users ADD email NVARCHAR(255);
wicked-patch reads from the wicked-garden:search symbol database:
# 1. wicked-garden:search creates the graph
/wicked-garden:search:index /project --derive-all
# 2. wicked-patch uses it for propagation
/wicked-garden:engineering:add-field SYMBOL --name foo --type String
cd "${CLAUDE_PLUGIN_ROOT}/scripts"
sh "${CLAUDE_PLUGIN_ROOT}/scripts/_python.sh" "${CLAUDE_PLUGIN_ROOT}/scripts/patch.py" --help
sh "${CLAUDE_PLUGIN_ROOT}/scripts/_python.sh" "${CLAUDE_PLUGIN_ROOT}/scripts/patch.py" generators # List supported languages
development
--- name: large-scale-migration description: How to execute a LARGE MECHANICAL change across any codebase with LEVERAGE instead of an agent-grind or hand-edits — a cross-cutting migration, refactor, rename, dialect/framework/DB port, library adoption, or bulk transform. The map→transform→gate pattern: a deterministic transform driven by a source-of-truth map, proven by a differential-equivalence gate. Use when the work is "migrate all X to Y", "rename Z everywhere", "port to a new DB/dialect/fra
testing
v11 LLM-based work-shape classifier. Replaces the regex archetype detector with the model's own reasoning. Reads the user's prompt, picks the right archetype(s) from the catalog, identifies signals (blast_radius, novelty, reversibility, etc.), and persists to SessionState so subsequent turns steer correctly. Use when: the prompt_submit hook emitted a `<wg classify-due />` directive, OR explicitly invoked at session start, OR when re-classifying after the user changes scope mid-session.
tools
v11 work-shape archetype runner. When a prompt has been routed to one of the 9 archetypes (triage, explore, specify, decide, ship, review, incident, build, migrate), this skill is the entry point. It picks the right per-archetype playbook from refs/ and executes the phase shape declared in `.claude-plugin/archetypes.json`. Use when: a `<wg archetype="X">` or `<wg archetypes>` system-reminder tag appears, an explicit "let's run the X archetype" request, or when one of the per-archetype slash commands resolves to this skill.
development
Show or set the session intent variable. Intent gates how loud the framework is — simple-edit (silent), feature/research (synthesis directive), rigor (full crew context). Auto-detected on turn 1; this skill overrides explicitly. Sticky for the session. Use when: "set intent", "intent override", "/wicked-garden:intent", "make the framework quiet", "force rigor", "what's my intent".