logging: console support/format for new log types

This commit is contained in:
Rachman Chavik 2012-05-24 10:29:59 +07:00
parent 9d76d3f88a
commit 3f6593311b
2 changed files with 5 additions and 1 deletions

View file

@ -128,9 +128,13 @@ class ConsoleOutput {
* @var array
*/
protected static $_styles = array(
'emergency' => array('text' => 'red', 'underline' => true),
'alert' => array('text' => 'red', 'underline' => true),
'critical' => array('text' => 'red', 'underline' => true),
'error' => array('text' => 'red', 'underline' => true),
'warning' => array('text' => 'yellow'),
'info' => array('text' => 'cyan'),
'debug' => array('text' => 'yellow'),
'success' => array('text' => 'green'),
'comment' => array('text' => 'blue'),
'question' => array('text' => "magenta"),

View file

@ -175,7 +175,7 @@ class Shell extends Object {
}
CakeLog::config('stderr', array(
'engine' => 'ConsoleLog',
'types' => array('error', 'warning'),
'types' => array('emergency', 'alert', 'critical', 'error', 'warning', 'debug'),
'stream' => $this->stderr,
));
if ($this->stdin == null) {