mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
[ruby/irb] irb_info codepage mismatch
`chcp` returns different encoding
f80971994a
This commit is contained in:
parent
34deea3b42
commit
de0523fedd
1 changed files with 1 additions and 1 deletions
|
@ -18,7 +18,7 @@ module IRB
|
|||
str += "LC_ALL env: #{ENV["LC_ALL"]}\n" if ENV["LC_ALL"] && !ENV["LC_ALL"].empty?
|
||||
str += "East Asian Ambiguous Width: #{Reline.ambiguous_width.inspect}\n"
|
||||
if RbConfig::CONFIG['host_os'] =~ /mswin|msys|mingw|cygwin|bccwin|wince|emc/
|
||||
codepage = `chcp`.sub(/.*: (\d+)\n/, '\1')
|
||||
codepage = `chcp`.b.sub(/.*: (\d+)\n/, '\1')
|
||||
str += "Code page: #{codepage}\n"
|
||||
end
|
||||
str
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue