示例#1
0
 public function option_output($k, $v)
 {
     if (is_array($v)) {
         trigger_error('Only a single output location can be supplied', E_USER_ERROR);
     }
     @mkdir($v, 0777, true);
     if (!is_dir($v) || !is_readable($v)) {
         trigger_error($v . ' is not a valid directory', E_USER_ERROR);
     }
     $v = substr($v, strlen($v) - 1) == DIRECTORY_SEPARATOR ? $v : $v . DIRECTORY_SEPARATOR;
     PHPacking_Config::set_output_dir($v);
 }