Development

Changeset 1843

You must first sign up to be able to contribute.

Changeset 1843

Show
Ignore:
Timestamp:
08/25/06 10:43:58 (2 years ago)
Author:
fabien
Message:

pake: added some colors to phing tasks

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • tools/pake/trunk/lib/pake/tasks/pakePhingTask.class.php

    r1791 r1843  
    5252    Phing::setProperty('phing.home', getenv('PHING_HOME')); 
    5353 
     54    ob_start(array('pakePhingTask', 'colorize'), 2); 
    5455    $m = new pakePhing(); 
    5556    $m->execute($args); 
    5657    $m->runBuild(); 
     58    ob_end_clean(); 
     59  } 
     60 
     61  public static function colorize($text) 
     62  { 
     63    return preg_replace(array('#(\[.+?\])#e', '#(\+ [^ ]+)#e'), array('pakeColor::colorize("$1", "INFO")', 'pakeColor::colorize("$1", "INFO")'), $text); 
    5764  } 
    5865}