Guard against windows? + style homogenization

This commit is contained in:
☈king 2013-02-08 01:03:29 -06:00 committed by rkingpa@sharpsaw.org
parent 5f3b5857fc
commit fbb159cc29
1 changed files with 2 additions and 2 deletions

View File

@ -180,8 +180,8 @@ class Pry
end
if input == Readline
if $stdin.tty? and not $stdout.tty?
Readline.output = File.open '/dev/tty', 'w'
if !$stdout.tty? && $stdin.tty? && !Pry::Helpers::BaseHelpers.windows?
Readline.output = File.open('/dev/tty', 'w')
end
input.readline(current_prompt, false) # false since we'll add it manually
elsif defined? Coolline and input.is_a? Coolline