rsanchez / eecli

Command line interface for ExpressionEngine
MIT License
37 stars 13 forks source link

Add in cache refresh ability #20

Closed khaliqgant closed 9 years ago

khaliqgant commented 9 years ago

This allows you to pass in additional options --refresh and --refresh_time="x" to allow cache to be cleared then refreshed using the ce_cache break_cache command.

The wiki would add in this information

--refresh

Whether to refresh cache after clearing

--refresh_time="1"

Number of seconds to wait between refreshing and deleting items

I did notice that if I did not specify the HTTP_HOST the cache would not refresh because the url ce cache was attempting to hit was just localhost and this was seen from the eecli show:config site_url command.

So the command looked like this in total:

HTTP_HOST="some-site.vmg" vendor/eecli/eecli/bin/eecli cache:clear:ce_cache static/sweet-template/index.html --refresh --refresh_time="1"
rsanchez commented 9 years ago

This is great! I'll add the docs. You can also set http host with an option:

vendor/bin/eecli --http_host="some-site.vmg" cache:clear:ce_cache static/sweet-template/index.html --refresh --refresh_time="1"
khaliqgant commented 9 years ago

@rsanchez Any idea when you're going to bring develop into master?

rsanchez commented 9 years ago

Today is your lucky day. Just tagged 1.0.6 with this in it.

khaliqgant commented 9 years ago

Excellent!