Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wp-media/wp-rocket-cli
WP CLI interface for the WP Rocket plugin
https://github.com/wp-media/wp-rocket-cli
Last synced: about 8 hours ago
JSON representation
WP CLI interface for the WP Rocket plugin
- Host: GitHub
- URL: https://github.com/wp-media/wp-rocket-cli
- Owner: wp-media
- Created: 2014-05-23T18:13:08.000Z (over 10 years ago)
- Default Branch: trunk
- Last Pushed: 2023-09-05T13:51:51.000Z (over 1 year ago)
- Last Synced: 2025-01-20T12:04:14.542Z (8 days ago)
- Language: PHP
- Homepage:
- Size: 43.9 KB
- Stars: 74
- Watchers: 17
- Forks: 37
- Open Issues: 25
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-wp-speed-up - WP CLI interface for WP Rocket - This repository contains a WP-CLI command for the WP Rocket plugin. After installing this plugin, you will have access to a wp rocket command. (WP-CLI Commands and Packages)
README
## WP CLI interface for WP Rocket
This repository contains a [WP-CLI command](https://github.com/wp-cli/wp-cli) for the [WP Rocket](http://wp-rocket.me) plugin. After installing this plugin, you will have access to a `wp rocket` command.
## Supported commands
* `wp rocket activate-cache --htaccess=` -- Set WP_CACHE to true and clean WP Rocket cache. To also update the htaccess on Apache, use the additional `htaccess` parameter.
* `wp rocket deactivate-cache --htaccess=` -- Set WP_CACHE to false and clean WP Rocket cache. To also update the htaccess on Apache, use the additional `htaccess` parameter.
* `wp rocket clean --post_id= --permalink= --lang= --blog_id=` -- Purge cache files.
* `wp rocket clean --confirm` -- Purge cache files without prompting for confirmation (usefull for automation tools/scripts)
* `wp rocket preload` -- Preload cache files.
* `wp rocket regenerate --file=` -- Regenerate .htaccess, advanced-cache.php or the WP Rocket config file.
* `wp rocket regenerate --file=config --nginx=true` -- regenerate the config file on Nginx hosts.
* `wp rocket cdn --enable= --host= --zone=` -- Enable / Disable CDN with the specified host and zone.
* `wp rocket export` -- Exports the WP Rocket settings as a json file to the current directory.
* `wp rocket import --file=settings.json` -- Imports the settings contained in the provided json file.## Installing
If you're using WP-CLI v0.23.0 or later, you can install this package with:
`wp package install wp-media/wp-rocket-cli`