mirror of
https://github.com/clearlinux/docker.git
synced 2026-09-05 05:01:28 +00:00
*Client: Fix the progressbar, without manipulating other outputs
Prior this commit, 'docker images' and other cmd's, which used utils.HumanSize(), showed unnecessary whitespaces. Formatting of progress has been moved to FormatProgess(), justifing the string directly in the template.
This commit is contained in:
+1
-1
@@ -106,7 +106,7 @@ func (r *progressReader) Close() error {
|
||||
func ProgressReader(r io.ReadCloser, size int, output io.Writer, template []byte, sf *StreamFormatter) *progressReader {
|
||||
tpl := string(template)
|
||||
if tpl == "" {
|
||||
tpl = string(sf.FormatProgress("", "%v/%v (%v)"))
|
||||
tpl = string(sf.FormatProgress("", "%8v/%v (%v)"))
|
||||
}
|
||||
return &progressReader{r, NewWriteFlusher(output), size, 0, 0, tpl, sf}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user