예제 #1
0
파일: minify.php 프로젝트: nexeck/kollapse
	/**
	 * Includes needed libraries (CSSMin & JSMin).
	 */
	protected function __construct(array $config)
	{
		parent::__construct($config);

		require_once Kohana::find_file('vendor/cssmin', 'cssmin');
		require_once Kohana::find_file('vendor/jsmin', 'jsmin');
	}
예제 #2
0
파일: yui.php 프로젝트: nexeck/kollapse
	/**
	 * Sets location of YUI Compressor.
	 */
	protected function __construct($config)
	{
		parent::__construct($config);

		if ( ! $bin = Kohana::find_file('vendor', 'yuicompressor-'.self::YUI_VERSION, 'jar'))
		{
			throw new Kohana_Exception('YUI Compressor :version not found',
				array(':version' => self::YUI_VERSION));
		}
		elseif (is_executable($bin))
		{
			throw new Kohana_Exeption("YUI Compressor at ':location' must be executable",
				array(':location' => $bin));
		}

		self::$bin = $bin;
	}