[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
09/10: guix download: Honor the number of columns of the terminal.
From: |
Ludovic Courtès |
Subject: |
09/10: guix download: Honor the number of columns of the terminal. |
Date: |
Thu, 14 Apr 2016 22:32:45 +0000 |
civodul pushed a commit to branch master
in repository guix.
commit cc44fbb8d9f47070c488faef3dc4b24f2a8a07d8
Author: Ludovic Courtès <address@hidden>
Date: Fri Apr 15 00:08:28 2016 +0200
guix download: Honor the number of columns of the terminal.
* guix/scripts/download.scm (guix-download): Parameterize
'current-terminal-columns'.
---
guix/scripts/download.scm | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/guix/scripts/download.scm b/guix/scripts/download.scm
index 6ebc14f..1648198 100644
--- a/guix/scripts/download.scm
+++ b/guix/scripts/download.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2012, 2013, 2015 Ludovic Courtès <address@hidden>
+;;; Copyright © 2012, 2013, 2015, 2016 Ludovic Courtès <address@hidden>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -24,6 +24,8 @@
#:use-module (guix utils)
#:use-module (guix base32)
#:use-module (guix download)
+ #:use-module ((guix build download) #:select (current-terminal-columns))
+ #:use-module ((guix build syscalls) #:select (terminal-columns))
#:use-module (web uri)
#:use-module (ice-9 match)
#:use-module (srfi srfi-1)
@@ -115,8 +117,10 @@ Supported formats: 'nix-base32' (default), 'base32', and
'base16'
(add-to-store store (basename (uri-path uri))
#f "sha256" (uri-path uri)))
(else
- (download-to-store store (uri->string uri)
- (basename (uri-path uri))))))
+ (parameterize ((current-terminal-columns
+ (terminal-columns)))
+ (download-to-store store (uri->string uri)
+ (basename (uri-path uri)))))))
(hash (call-with-input-file
(or path
(leave (_ "~a: download failed~%")
- branch master updated (85c7e8e -> b0a6a97), Ludovic Courtès, 2016/04/14
- 04/10: download: Send an ANSI erase-in-line sequence in addition to CR., Ludovic Courtès, 2016/04/14
- 02/10: gnu-maintenance: Recognize source tarball with "-src" in their name., Ludovic Courtès, 2016/04/14
- 09/10: guix download: Honor the number of columns of the terminal.,
Ludovic Courtès <=
- 08/10: ui: Use 'terminal-columns'., Ludovic Courtès, 2016/04/14
- 05/10: download: Add 'current-terminal-columns' parameter., Ludovic Courtès, 2016/04/14
- 10/10: substitute: Honor the number of columns of the client terminal., Ludovic Courtès, 2016/04/14
- 07/10: ui: 'package->recutils' accurately honors the number of columns., Ludovic Courtès, 2016/04/14
- 03/10: gnu-maintenance: Move FTP directory info to 'properties' fields., Ludovic Courtès, 2016/04/14
- 06/10: syscalls: Add TIOCGWINSZ bindings., Ludovic Courtès, 2016/04/14
- 01/10: upstream: Pass a package object to updaters., Ludovic Courtès, 2016/04/14