Skip to content

Commit a446cb1

Browse files
committed
Reduce 1 char from progress output for Windows
Windows command prompt force wraps at the maximum number of chars of the last line so this commit reduces 1 char of it.
1 parent 8f9f4c1 commit a446cb1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/rdoc/stats/normal.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def print_file files_so_far, filename
3131
# will be truncated if necessary.
3232
size = IO.respond_to?(:console_size) ? IO.console_size : IO.console.winsize
3333
terminal_width = size[1].to_i.nonzero? || 80
34-
max_filename_size = terminal_width - progress_bar.size
34+
max_filename_size = (terminal_width - progress_bar.size) - 1
3535

3636
if filename.size > max_filename_size then
3737
# Turn "some_long_filename.rb" to "...ong_filename.rb"

0 commit comments

Comments
 (0)