scripts: import: Increase column width for pretty-printer.
Previously, the max column width for the pretty-printer was 50, which caused generated package definitions to include unnecessary newlines, e.g., (home-page "https://gitlab.com/ttyperacer/terminal-typeracer") instead of (home-page "https://gitlab.com/ttyperacer/terminal-typeracer") * guix/scripts/import.scm (guix-import): Set max expression width to 80 when pretty-printing. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
parent
98712c14fe
commit
08c7e7df15
@ -4,6 +4,7 @@
|
||||
;;; Copyright © 2018 Kyle Meyer <kyle@kyleam.com>
|
||||
;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net>
|
||||
;;; Copyright © 2021 Simon Tournier <zimon.toutoune@gmail.com>
|
||||
;;; Copyright © 2021 Xinglu Chen <public@yoctocell.xyz>
|
||||
;;;
|
||||
;;; This file is part of GNU Guix.
|
||||
;;;
|
||||
@ -118,7 +119,8 @@ Run IMPORTER with ARGS.\n"))
|
||||
(if (member importer importers)
|
||||
(let ((print (lambda (expr)
|
||||
(pretty-print expr (newline-rewriting-port
|
||||
(current-output-port))))))
|
||||
(current-output-port))
|
||||
#:max-expr-width 80))))
|
||||
(match (apply (resolve-importer importer) args)
|
||||
((and expr (or ('package _ ...)
|
||||
('let _ ...)
|
||||
|
Loading…
Reference in New Issue
Block a user