[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: which package gets built first?
From: |
( |
Subject: |
Re: which package gets built first? |
Date: |
Fri, 04 Nov 2022 16:39:29 +0000 |
Heya,
On Fri Nov 4, 2022 at 9:49 AM GMT, zimoun wrote:
> Other said, the CLI is somehow parsed from right to left.
Probably because:
args: (pkg1 pkg2 pkg3)
cmds: ()
args: (pkg2 pkg3)
cmds: ((install . pkg1))
args: (pkg3)
cmds: ((install . pkg2)
(install . pkg1))
args: ()
cmds: ((install . pkg3)
(install . pkg2)
(install . pkg1))
I suppose we could add a reverse in this procedure, defined within
guix/scripts/package.scm's options->installable:
(define to-install
(filter-map (match-lambda
(('install . (? package? p))
;; When given a package via `-e', install the first of its
;; outputs (XXX).
(package->manifest-entry* (transform p) "out"))
(('install . (? string? spec))
(if (store-path? spec)
(store-item->manifest-entry spec)
(let-values (((package output)
(specification->package+output spec)))
(package->manifest-entry* (transform package)
output))))
(('install . obj)
(leave (G_ "cannot install non-package object: ~s~%")
obj))
(_
#f))
opts))
-- (