Module: NoAnsi

Defined in:
lib/no-ansi.rb

Overview

Shadow to JustAnsi but does not use ANSI codes. It can be used as a compatible JustAnsi replacement.

Examples:

Define global Ansi module depending on NO_COLOR environment variable

Ansi = ENV.key?('NO_COLOR') ? NoAnsi : JustAnsi

puts Ansi.bbcode('[b]Hello World![/b]')
# => prints bold text when 'NO_COLOR' was not defined

See Also: