Red Hat Bugzilla – Bug 474822
progress bar not redrawn correctly on narrow terminals
Last modified: 2014-03-31 19:44:41 EDT
Created attachment 325848 [details]
yum output to terminal
When running yum install on a narrow terminal (mine was 69 chars, but anything narrow will work), the progress is not redrawn, but a newline printed.
So it looks something like this:
Installing : httpd-manual
Installing : httpd-manual #
Installing : httpd-manual ##
Installing : httpd-manual ###
Installing : httpd-manual ####
- start konsole (i386,F8, kdebase-3.5.10-2.fc8)
- ssh root@server
- resize konsole so that it's aproximate 3/4 in width,
about 60 chars wide
- yum install httpd-manual
- x86_64 RHEL 5.3 from latest trees
A can image a couple of options how this could be fixed:
- scale the progress bar
- don't print the progress bar if the terminal is too narrow
- bail out if the terminal is too narrow (like 'w' does, but this is
probably the worst option, probably much worse than incorrectly
printing the progress)
[root@kovy ~]# w
67 column window is too narrow
Yeh, this only got fixed very recently upstream ... before that it just assumed ~80 chars width.
If we do another rebase for 5.4 this will come along for the ride, but I'm not sure if we are (and back porting it is non-trivial, and probably worthless). So no devel ACK, yet.
Release note added. If any revisions are required, please set the
"requires_release_notes" flag to "?" and edit the "Release Notes" field accordingly.
All revisions will be proofread by the Engineering Content Services team.
Previously, yum assumed that any terminal was 80 characters in width. Therefore, when it drew a progress bar on the screen, each additional # printed would force a new line on terminals narrower than 80 characters. Yum now determines the actual width of the terminal rather than assuming the width, and draws its progress bars accordingly.
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.