Flag for assetic:dump task

This commit is contained in:
Piotr Antosik 2015-12-18 01:50:07 +01:00
parent d33eed8d52
commit 77f5e6e518

View File

@ -22,6 +22,8 @@ set('writable_dirs', ['app/cache', 'app/logs']);
// Assets
set('assets', ['web/css', 'web/images', 'web/js']);
// Default true - BC for Symfony < 3.0
set('dump_assets', true);
// Environment vars
env('env_vars', 'SYMFONY_ENV=prod');
@ -68,6 +70,9 @@ task('deploy:assets', function () {
* Dump all assets to the filesystem
*/
task('deploy:assetic:dump', function () {
if (!get('dump_assets')) {
return;
}
run('php {{release_path}}/' . trim(get('bin_dir'), '/') . '/console assetic:dump --env={{env}} --no-debug');