Pantheon\Terminus\Commands\Env\ClearCacheCommand::clearCache PHP Method

clearCache() public method

Clears the cache on an environment
public clearCache ( string $site_env )
$site_env string The site and environment to clear the cache of
    public function clearCache($site_env)
    {
        list($site, $env) = $this->getSiteEnv($site_env);
        $workflow = $env->clearCache();
        while (!$workflow->checkProgress()) {
            // @TODO: Add Symfony progress bar to indicate that something is happening.
        }
        $this->log()->notice('Caches cleared on {site}.{env}.', ['site' => $site->get('name'), 'env' => $env->id]);
    }
ClearCacheCommand