### Home Classes Methods

### In Files

- lib/gherkin/formatter/colors.rb

### Included Modules

- Term::ANSIColor

### Files

- LICENSE
- README.rdoc
- meta.txt
- root.txt
- steps.txt
- README.rdoc

### Class/Module Index

Quicksearch

- Gherkin
- Gherkin::CLexer
- Gherkin::Cli
- Gherkin::Cli::Main
- Gherkin::Formatter
- Gherkin::Formatter::Argument
- Gherkin::Formatter::Colors
- Gherkin::Formatter::Escaping
- Gherkin::Formatter::JSONFormatter
- Gherkin::Formatter::MonochromeFormat
- Gherkin::Formatter::PrettyFormatter
- Gherkin::I18n
- Gherkin::I18nLexer
- Gherkin::JSONLexer
- Gherkin::Parser
- Gherkin::Parser::Event
- Gherkin::Parser::FilterListener
- Gherkin::Parser::FormatterListener
- Gherkin::Parser::ParseError
- Gherkin::Parser::Parser
- Gherkin::Parser::Parser::Machine
- Gherkin::Parser::Parser::Machine::StateMachineReader
- Gherkin::Parser::Row
- Gherkin::Parser::TagExpression
- Gherkin::RbLexer
- Gherkin::Rubify
- Gherkin::Tools
- Gherkin::Tools::Files
- Gherkin::Tools::Reformat
- Gherkin::Tools::Stats
- Gherkin::Tools::StatsListener
- Class

No matching classes.

# Gherkin::Formatter::Colors

Defines aliases for coloured output. You don’t invoke any methods from this module directly, but you can change the output colours by defining a `GHERKIN_COLORS` variable in your shell, very much like how you can tweak the familiar POSIX command `ls` with <a href=“$LSCOLORS/$LS_COLORS</a">mipsisrisc.com/rambling/2008/06/27/lscolorsls_colors-now-with-linux-support/”>$LSCOLORS/$LS_COLORS</a</a>>

The colours that you can change are:

- `undefined` - defaults to `yellow`

- `pending` - defaults to `yellow`

- `pending_param` - defaults to `yellow,bold`

- `failed` - defaults to `red`

- `failed_param` - defaults to `red,bold`

- `passed` - defaults to `green`

- `passed_param` - defaults to `green,bold`

- `outline` - defaults to `cyan`

- `outline_param` - defaults to `cyan,bold`

- `skipped` - defaults to `cyan`

- `skipped_param` - defaults to `cyan,bold`

- `comment` - defaults to `grey`

- `tag` - defaults to `cyan`

For instance, if your shell has a black background and a green font (like the “Homebrew” settings for OS X’ Terminal.app), you may want to override passed steps to be white instead of green. Examples:

    export GHERKIN_COLORS="passed=white"
    export GHERKIN_COLORS="passed=white,bold:passed_param=white,bold,underline"

(If you’re on Windows, use SET instead of export). To see what colours and effects are available, just run this in your shell:

    ruby -e "require 'rubygems'; require 'term/ansicolor'; puts Term::ANSIColor.attributes"

Although not listed, you can also use `grey`

### Constants

ALIASES

[Validate]

Generated with the Darkfish Rdoc Generator 2.