"text"*-x fixed.
This commit is contained in:
parent
06a3300740
commit
55f3a15e81
|
@ -72,7 +72,7 @@ class ProgressBar::Console < ProgressBar::Base
|
||||||
def change_text
|
def change_text
|
||||||
l = (100.0*i/max).to_i
|
l = (100.0*i/max).to_i
|
||||||
dd, td = done_dur, total_dur
|
dd, td = done_dur, total_dur
|
||||||
STDOUT.printf "\r\e[J%s / %s [%s>%s] %s", format_time(dd), format_time(td), '='*l, ' '*(100-l), text
|
STDOUT.printf "\r\e[J%s / %s [%s>%s] %s", format_time(dd), format_time(td), '='*l, ' '*[100, 100-l].min, text
|
||||||
end
|
end
|
||||||
alias change_progress change_text
|
alias change_progress change_text
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue