use ANSI color codes on shell by default
[bdrem.git] / src / bdrem / Cli.php
index 0525a37634819c231ab7c769ad6a87e2a056550e..3ecd4ea488b83a4bb003189d1c04e1168a53d8cf 100644 (file)
@@ -40,6 +40,16 @@ class Cli extends UserInterface
         //set default renderer to console
         $parser->options['renderer']->default = 'console';
 
         //set default renderer to console
         $parser->options['renderer']->default = 'console';
 
+        $parser->addOption(
+            'ansi',
+            array(
+                'long_name'   => '--no-color',
+                'description' => 'Do not output ANSI color codes',
+                'action'      => 'StoreFalse',
+                'default'     => true
+            )
+        );
+
         //only on CLI
         $parser->addCommand(
             'readme', array(
         //only on CLI
         $parser->addCommand(
             'readme', array(