Beispiel #1
0
 /**
  * Show version info for the current task and kill the script
  * 
  * @param Event $ev An event fired when the field was parsed
  * @return void
  */
 public static function showVersionInformation(Event $ev)
 {
     $task = $ev->getData('task');
     $script = Cli::getScriptName();
     $version = $task::VERSION;
     Env::log("{$script} version {$version}\n");
     Env::terminate(0);
 }
Beispiel #2
0
 /**
  * Terminate the script
  *
  * This method exists for testing purposes
  * @param integer $exitcode
  */
 public function terminate($exitcode)
 {
     Env::terminate($exitcode);
 }