summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-09-12 12:51:43 +0000
committerhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-09-12 12:51:43 +0000
commit672848de471ff160c37a91de3c9d114a359613b9 (patch)
treea0019770bea953f9c5abb208fface7b84b9d5bc6
parent2698d34dbd373cacd41d7063dc8b1a570eeeb334 (diff)
Partly reverted r59845.
All of environments on Ruby CI are fails rdoc generation. It may be caused by https://github.com/ruby/rdoc/commit/8cfa11d6f1cc7e74e45e42fd8d1d76c5a0646a6e git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59856 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--lib/rdoc/stats/normal.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/rdoc/stats/normal.rb b/lib/rdoc/stats/normal.rb
index 8ad0e45..ba00b6c 100644
--- a/lib/rdoc/stats/normal.rb
+++ b/lib/rdoc/stats/normal.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: false
-require 'io/console'
+require 'io/console/size'
##
# Stats printer that prints just the files being documented with a progress
@@ -23,7 +23,7 @@ class RDoc::Stats::Normal < RDoc::Stats::Quiet
# Print a progress bar, but make sure it fits on a single line. Filename
# will be truncated if necessary.
- terminal_width = IO.console.winsize[1].to_i.nonzero? || 80
+ terminal_width = IO.console_size[1].to_i.nonzero? || 80
max_filename_size = terminal_width - progress_bar.size
if filename.size > max_filename_size then