pull: '-l' now honors '-p'.

* guix/scripts/pull.scm (process-query): Add 'profile' parameter and
remove 'profile' local variable.
(guix-pull): Adjust caller.
master
Ludovic Courtès 2018-10-09 10:52:39 +02:00
parent fe17037b38
commit e54aec7b8e
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5
1 changed files with 3 additions and 6 deletions

View File

@ -341,11 +341,8 @@ and ALIST2 differ, display HEADING upfront."
(display-new/upgraded-packages (package-alist gen1)
(package-alist gen2)))
(define (process-query opts)
"Process any query specified by OPTS."
(define profile
(string-append (config-directory) "/current"))
(define (process-query opts profile)
"Process any query on PROFILE specified by OPTS."
(match (assoc-ref opts 'query)
(('list-generations pattern)
(define (list-generations profile numbers)
@ -445,7 +442,7 @@ Use '~/.config/guix/channels.scm' instead."))
(string-append (config-directory) "/current"))))
(cond ((assoc-ref opts 'query)
(process-query opts))
(process-query opts profile))
((assoc-ref opts 'dry-run?)
#t) ;XXX: not very useful
(else