mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-27 06:42:14 -05:00
download: Send an ANSI erase-in-line sequence in addition to CR.
Partly fixes <http://bugs.gnu.org/22536>. Reported by Danny Milosavljevic <dannym@scratchpost.org>. * guix/build/download.scm (progress-proc): Send an ANSI erase-in-line sequence.
This commit is contained in:
parent
63e8bb12a4
commit
8a2154fefa
1 changed files with 2 additions and 2 deletions
|
@ -167,8 +167,8 @@ (define* (progress-proc file size
|
|||
(seconds->string elapsed)
|
||||
(progress-bar %) %)))
|
||||
;; TODO: Make this adapt to the actual terminal width.
|
||||
(display "\r\x1b[K" log-port)
|
||||
(display (string-pad-middle left right 80) log-port)
|
||||
(display #\cr log-port)
|
||||
(flush-output-port log-port)
|
||||
(cont))))
|
||||
(lambda (transferred cont)
|
||||
|
@ -183,8 +183,8 @@ (define* (progress-proc file size
|
|||
(seconds->string elapsed)
|
||||
(byte-count->string transferred))))
|
||||
;; TODO: Make this adapt to the actual terminal width.
|
||||
(display "\r\x1b[K" log-port)
|
||||
(display (string-pad-middle left right 80) log-port)
|
||||
(display #\cr log-port)
|
||||
(flush-output-port log-port)
|
||||
(cont))))))))
|
||||
|
||||
|
|
Loading…
Reference in a new issue