# WordPress workflow defaults When working on any of my WordPress sites — staging-courtneyr-dev, courtneyr.dev, future projects — Claude (and I) default in this order: ## 1. wp-cli is the first tool Not SFTP. Not the wp-admin UI. Not direct file edits. For: - wp-config constants → `wp config set CONST 'value' --type=constant` - Reading constants without leaking secrets → `wp eval 'echo defined("CONST") ? "set" : "MISSING";'` - Plugin/theme install/activate → `wp plugin install`, `wp theme activate` - Options + transients → `wp option`, `wp transient` - Posts/users/db → `wp post`, `wp user`, `wp db` - Search-replace → `wp search-replace --dry-run` first, then live - Cache flush → `wp cache flush`, `wp transient delete --all`, `wp rewrite flush` ### Aliases `~/projects/staging-courtneyr-dev/wp-cli.yml` defines: - `@staging` → SSH host `courtneyr-staging` (alias in `~/.ssh/config`), path `html` - `@prod` → equivalent for production Inside the staging repo, `wp <command>` automatically applies `@staging`. Outside it, use the explicit alias: `wp @staging post list`. ### Why - Faster (no leaving the terminal). - Auditable (lives in shell history). - No human typos in wp-config.php. - Composable (pipe-able with grep, jq, etc.). ### Caveats - The credential-write hook on this Mac blocks Claude from running `wp @staging config set` against secrets directly. When that hook fires, Claude hands me the exact command to paste — that's by design and shouldn't be worked around. - `wp eval` prints PHP warnings/errors to stderr. Pipe with `2>&1 | grep -v "Deprecated\|Warning"` for clean output, but read the full stream when debugging. ## 2. Ollie skill for theme paint `courtneyr-child` is the active theme on every Courtney site. Its parent is **Ollie** (1.6.0 as of 2026-05-06). For any work involving: - theme.json tokens (palette, fontFamilies, spacing scale) - FSE patterns and template parts - block style variations - Ollie-specific block extensions Claude invokes the Ollie skill via the Skill tool. No guessing at conventions. ### Skill install status Installed 2026-05-06 from `~/Downloads/ollie-design-system (1).md` to `~/.claude/skills/ollie/SKILL.md`. Frontmatter declares it triggers on Ollie/Ollie Pro styling, color, typography, button, spacing, Abilities tools, block markup, and pattern work. Treat Ollie work as theme paint that respects the **Outpost Hard Contract** (plugin owns layout, theme owns paint) — don't write color/font/spacing into Outpost's PHP/CSS; surface tokens via `var(--outpost-*, fallback)` and let Ollie / courtneyr-child paint them. ## Anti-patterns - Proposing SFTP edits to wp-config.php "for visibility." wp-cli does it cleaner. - Hardcoding theme colors into Outpost. Hard Contract violation. - Editing options/posts via the database directly. Use `wp option`/`wp post` so hooks fire. - Running `wp eval` against production without `--dry-run`-equivalent thinking first. ## Related - `outpost_hosting_gotchas` — eight managed-WP failure modes (memory) - `courtney_cache_layers` — flush order matters (memory) - `staging_submodules_drift` — bump every relevant submodule on staging deploys (memory) ## Links - [[3. Resources/MOCs/WordPress Platform Design MOC]] — applies-in: Records working defaults for WordPress site operations.