From 87116afa76d8a1bf82cf1fd8a7040f25ebd9e46b Mon Sep 17 00:00:00 2001 From: takara_shinya Date: Wed, 2 Apr 2014 17:06:14 +0900 Subject: [PATCH 1/2] add rename config property --- classes/casset.php | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/classes/casset.php b/classes/casset.php index 2e9e808..e8fa5cb 100644 --- a/classes/casset.php +++ b/classes/casset.php @@ -80,6 +80,7 @@ class Casset { 'inline' => false, 'attr' => array(), 'deps' => array(), + 'rename' => false, ); /** @@ -176,6 +177,8 @@ public static function _init() static::$deps_max_depth = \Config::get('casset.deps_max_depth', static::$deps_max_depth); + static::$default_options['rename'] = \Config::get('casset.rename', static::$default_options['rename']); + $group_sets = \Config::get('casset.groups', array()); foreach ($group_sets as $group_type => $groups) @@ -796,7 +799,7 @@ public static function render_js($group = false, $options = array(), $attr_dep = if (static::$groups['js'][$group_name]['combine']) { - $filename = static::combine('js', $file_group, static::$groups['js'][$group_name]['min'], $inline); + $filename = static::combine('js', $file_group, static::$groups['js'][$group_name]['min'], $inline, $group_name); if (!$inline && static::$show_files && $options['gen_tags']) { $ret .= '