From superpowers-sage
Executes safe WordPress data migrations to Sage/Acorn via 7-phase process: snapshot-before, dry-run, human approval, gates, apply, verify, idempotency checks.
npx claudepluginhub codigodoleo/superpowers-sage --plugin superpowers-sageThis skill uses the workspace's default tool permissions.
Execute data migrations with full safety harness: snapshot, dry-run, gate, apply, verify, confirm idempotency. Never destructive-first.
Guides safe database schema changes and code migrations with zero-downtime strategies including backfills, dual-writes, feature flags, and Strangler Fig pattern.
Orchestrates complete migration workflows for frameworks (e.g., Vue 2→3, Express→Fastify), databases (MySQL→PostgreSQL), and architectures (REST→GraphQL, monolith→microservices) with analysis, incremental execution, and rollback.
Guides WP-CLI operations for WordPress: safe search-replace, DB export/import, plugin/theme/user/content management, cron events, cache flushing, multisite handling, and wp-cli.yml scripting.
Share bugs, ideas, or general feedback.
Execute data migrations with full safety harness: snapshot, dry-run, gate, apply, verify, confirm idempotency. Never destructive-first.
Announce at start: "I'm using the migrating skill for a safe data migration with snapshot/dry-run/gate/apply/verify/idempotency checks."
post_content rewrites (injecting blocks, replacing shortcodes, updating markup)wp_postmeta cleanup (orphan keys, schema changes, re-computing derived values)/building or direct editslando wp directlyacorn-eloquentacorn-queues with jobs$ARGUMENTS
Resolve to a migration name (used for snapshot filenames and logs) and target scope.
┌─────────────────────────────────────────────────────────┐
│ 1. SNAPSHOT BEFORE → /tmp/<migration>-before.xml │
├─────────────────────────────────────────────────────────┤
│ 2. DRY-RUN COMPUTE → list affected rows + new shape │
├─────────────────────────────────────────────────────────┤
│ 3. HUMAN APPROVAL → show diff, pause, await 'y' │
├─────────────────────────────────────────────────────────┤
│ 4. PREFLIGHT CHECKS → orphan meta, template validity │
├─────────────────────────────────────────────────────────┤
│ 5. APPLY → loop, log progress, wp_slash() │
├─────────────────────────────────────────────────────────┤
│ 6. SNAPSHOT AFTER → /tmp/<migration>-after.xml │
│ + VERIFY → count + shape + spot-check │
├─────────────────────────────────────────────────────────┤
│ 7. IDEMPOTENCY CHECK → re-run, assert 0 rows changed │
└─────────────────────────────────────────────────────────┘
Full phase procedures (commands, scripts, validation criteria):
skills/migrating/references/phase-detail.md
Rollback procedures for all 3 tiers:
skills/migrating/references/rollback-playbook.md
If post-verification anything is wrong, use the lowest-impact tier:
lando wp post list --post_type=revision --post_parent=<ID> then lando wp post update <ID> --post_content="$(lando wp post get <REVISION-ID> --field=post_content)" (single post, revisions enabled)lando wp db import /tmp/<migration>-postmeta-before.sql (table-level)lando wp db import /tmp/<migration>-full-before.sql (nuclear, last resort)Always have the Tier 3 snapshot before applying.
| Wrong | Correct |
|---|---|
| Apply first, snapshot after | Snapshot BEFORE apply, always |
| Skip dry-run ("trust me") | Dry-run + diff always — no autonomous apply |
| Approve on silence | Explicit 'y' required; silence is not consent |
Bulk $wpdb->update() without wp_slash() | wp_slash() for user content |
| One-shot script with no idempotency check | Re-run after apply, assert 0 updates |
| Delete target rows before apply | Never; update in place, rollback via snapshot |
Skip _wp_page_template preflight | Check orphan meta before wp_update_post |
| Apply without Tier-3 snapshot | lando wp db export full DB before any destructive op |