Beispiel #1
0
 /**
  * _runTool() - This is where the magic happens, dispatch Zend_Tool
  *
  * @return void
  */
 protected function _runTool()
 {
     $configOptions = array();
     if (isset($this->_configFile) && $this->_configFile) {
         $configOptions['configOptions']['configFilepath'] = $this->_configFile;
     }
     if (isset($this->_storageDirectory) && $this->_storageDirectory) {
         $configOptions['storageOptions']['directory'] = $this->_storageDirectory;
     }
     // ensure that zf.php loads the Zend_Tool_Project features
     $configOptions['classesToLoad'] = 'Zend_Tool_Project_Provider_Manifest';
     $console = new Zend_Tool_Framework_Client_Console($configOptions);
     $console->dispatch();
 }
Beispiel #2
0
    echo <<<EOS
    
***************************** ZF ERROR ********************************
In order to run the zf command, you need to ensure that Zend Framework
is inside your include_path.  If you are running this tool without 
ZendFramework in your include_path, you can alternatively set one of 
two environment variables to for this tool to work:

a) ZEND_TOOL_INCLUDE_PATH_PREPEND="/path/to/ZendFramework/library"

OR alternatively

b) ZEND_TOOL_INCLUDE_PATH="/path/to/ZendFramework/library"

The former (a) will make the specified Zend Framework first in the
include_path whereas the latter (b) will replace the include_path
with the specified path.

Information:

EOS;
    echo '    original include_path: ' . $_zf['original'] . PHP_EOL;
    echo '    attempted include_path: ' . get_include_path() . PHP_EOL;
    echo '    script location: ' . $_SERVER['SCRIPT_NAME'] . PHP_EOL;
    exit(1);
}
// cleanup the global space
unset($_zf);
// run tool
Zend_Tool_Framework_Client_Console::main();
exit(0);
Beispiel #3
0
function zf_run($zfConfig)
{
    global $_zf;
    unset($_zf);
    $configOptions = array();
    if (isset($zfConfig['CONFIG_FILE'])) {
        $configOptions['configFilepath'] = $zfConfig['CONFIG_FILE'];
    }
    if (isset($zfConfig['CONFIG_FILE'])) {
        $configOptions['storageDirectory'] = $zfConfig['STORAGE_DIR'];
    }
    Zend_Tool_Framework_Client_Console::main($configOptions);
}