Sign up ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm trying to simplify my deploy process and am making use of the Capistrano tool. Is there a way to have capistrano flush W3TC's cache in a deploy task?

share|improve this question

closed as off-topic by birgire, Pieter Goosen, Mark Kaplun, Rarst Aug 25 '14 at 16:08

This question appears to be off-topic. The users who voted to close gave this specific reason:

If this question can be reworded to fit the rules in the help center, please edit the question.

2 Answers 2

As @andreascreten, wp-cli will do the job for you.

wp-cli includes commands for W3TC (located in the src/php/wp-cli/commands/community/total-cache.php file), so you can flush the cache by running:

$ wp total-cache flush <type>

Where <type> is one of 'db', 'minify', 'object', 'page' or 'post'.

(Note: If you use 'post', you'll need to pass in --post_id= or --permalink= as well)

share|improve this answer

You could use wp-cli to flush W3TC:

share|improve this answer
Can you provide a better explanation here instead of just a link? – Brian Fegter Aug 29 '12 at 1:45

Not the answer you're looking for? Browse other questions tagged or ask your own question.