Changeset 3567

Show
Ignore:
Timestamp:
01/22/08 22:08:08 (18 months ago)
Author:
jwage
Message:

Fixed compiler task and made Compiler return the path compiled file was written to.

Location:
trunk/lib/Doctrine
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/lib/Doctrine/Compiler.php

    r3458 r3567  
    4040     * 
    4141     * @throws Doctrine_Compiler_Exception      if something went wrong during the compile operation 
    42      * @return void 
     42     * @return $target Path the compiled file was written to 
    4343     */ 
    4444    public static function compile($target = null, $includedDrivers = array()) 
     
    134134        fwrite($fp, $stripped); 
    135135        fclose($fp); 
     136 
     137        return $target; 
    136138    } 
    137139} 
  • trunk/lib/Doctrine/Task/Compile.php

    r3458 r3567  
    4040    public function execute() 
    4141    { 
    42         Doctrine::compile($this->getArgument('compiled_path'), $this->getArgument('drivers', array())); 
    43          
    44         $this->notify('Compiled Doctrine successfully to: ' . $this->getArgument('compiled_path')); 
     42        $compiledPath = Doctrine_Compiler::compile($this->getArgument('compiled_path'), $this->getArgument('drivers', array())); 
     43 
     44        $this->notify('Compiled Doctrine successfully to: ' . $compiledPath); 
    4545    } 
    4646}