[rspec-devel] [ rspec-Bugs-15604 ] Cannot use console colouring mode without " win32console" gem on Windows.

noreply at rubyforge.org noreply at rubyforge.org
Wed Nov 14 11:37:33 EST 2007


Bugs item #15604, was opened at 2007-11-13 15:50
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=3149&aid=15604&group_id=797

Category: runner module
Group: None
Status: Open
Resolution: Rejected
Priority: 3
Submitted By: Roman Chernyatchik (romeo)
Assigned to: Aslak Hellesøy (aslak_hellesoy)
>Summary: Cannot use console colouring mode without "win32console" gem on Windows.

Initial Comment:
Cannot use console colouring mode without "win32console" gem on Windows.

Hi guys! I've written renderer for rspec colouring output, but I cannot use it on Windows platform. Please add opportunity to use colouring mode on Windows without "win32console" gem!

The problem is in base_text_formatter.rb: 

def colour=(colour)
     @colour = colour
     begin ; require 'Win32/Console/ANSI' if @colour && PLATFORM =~ /win32/ ; rescue LoadError ;  raise "You must gem install win32console to use colour on Windows" ; end
end 

----------------------------------------------------------------------

>Comment By: Roman Chernyatchik (romeo)
Date: 2007-11-14 19:37

Message:
We've implemented  colour support in console panel of ROR plugin for IntelliJ 
IDEA.  But "win32console" gem doesn't allow us to redirect output stream thus it 
hides all output from our console even when colour mode is disabled. 

----------------------------------------------------------------------

Comment By: Aslak Hellesøy (aslak_hellesoy)
Date: 2007-11-13 19:26

Message:
This makes no sense. You must install the gem to have console colour on windows. The error message even tells you that.

Or tell us how to have colour support without the gem - I don't think it's possible.

----------------------------------------------------------------------

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=3149&aid=15604&group_id=797


More information about the rspec-devel mailing list