function drush_minifyjs_minify_js in Minify JS 8
Same name and namespace in other branches
- 7 minifyjs.drush.inc \drush_minifyjs_minify_js()
Drush command logic. drush_[COMMAND_NAME]().
File
- ./
minifyjs.drush.inc, line 42
Code
function drush_minifyjs_minify_js() {
drush_print('Minifying all JS files...');
$files = minifyjs_load_all_files();
foreach ($files as $fid => $file) {
$status = minifyjs_minify_file($fid);
// Only output error messages.
if ($status !== TRUE) {
drush_print($status);
}
}
\Drupal::cache()
->delete(MINIFYJS_CACHE_CID);
drush_print('Complete!');
}