public function run($args)
	{
		$this->_scriptName=$args[0];
		array_shift($args);
		if(isset($args[0]))
		{
			$name=$args[0];
			array_shift($args);
		}
		else
			$name='help';

		$oldCommand=$this->_command;
		if(($command=$this->createCommand($name))===null)
			$command=$this->createCommand('help');
		$this->_command=$command;
		$command->init();
		$exitCode=$command->run($args);
		$this->_command=$oldCommand;
		return $exitCode;
	}