Skip to content

Latest commit

 

History

History
9 lines (5 loc) · 555 Bytes

miscellaneous-notes.md

File metadata and controls

9 lines (5 loc) · 555 Bytes

Miscellaneous Notes

WP-CLI Commands

Any .php files placed in bin/wp-cli/multiple-use will automatically be registered as WP-CLI commands scripts, so you can just run wp {foo} {bar}. See purge-cloudflare-cache.php as an example.

One-off scripts can be placed in bin/wp-cli/single-use and called with wp eval-file bin/wp-cli/single-use/example.php

The reasoning behind that setup is that wp help shouldn't be cluttered with dozens of commands that were only used once, but commands that are used regularly should be documented there.