-
Notifications
You must be signed in to change notification settings - Fork 33
Open
Description
First the issue, even with win32console I can't get colors on windows:
irb(main):001:0> require 'ansi/code'
ansi: 'gem install win32console' to use color on Windows
The reason is that win32console is deprecated (and does not load on recent ruby versions). The good news is that, to the best of the my knowledge, it is no longer needed in ruby 2.0+.
The fix is very simple: don't require 'win32console' when ruby version is 2.0+ (assuming I am not missing anything here).
I verified this by changing code.rb, line 9 to:
if RUBY_PLATFORM =~ /(win32|w32)/ && RUBY_VERSION < "2.0"
This seems to work fine for me.
jpc2
Metadata
Metadata
Assignees
Labels
No labels