Cache clear is a plugin written for Craft that allows you to post to a specific URL (with a unique key) to automatically clear your website caches. This is incredibly useful when working in a Git deployment environment.
- Move cacheclear to your plugins directory.
- Install in your control panel at admin/settings/plugins.
- Configure your unique key (Note: make sure you keep this private, unless you like random people clearing your website caches... Who knows, maybe you live on the wild side?)
- Copy the URL from admin/settings/plugins/cacheclear and visit in your browser. Alternatively, you can create a Craft template with the provided code.
- Git tricky with it! Setup a Git hook to automatically hit that URL after every push to automate cache clears! The rest is up to you!
Before I say anything else, this plugin is inspired by Ben Croker's plugin Dump. To clarify what I mean by "inspired" - it is an almost exact copy.. I just spent my time determining how to create an action that would clear the caches.
However, I did check with Ben before releasing this to make sure it was ok... In other words - love your fellow developers and show respect where its due!