profiles: Add 'packages->manifest' procedure.
* guix/profiles.scm (packages->manifest): New procedure.
This commit is contained in:
parent
7ea1432e22
commit
8404ed5c3e
|
@ -80,6 +80,7 @@
|
|||
|
||||
profile-manifest
|
||||
package->manifest-entry
|
||||
packages->manifest
|
||||
%default-profile-hooks
|
||||
profile-derivation
|
||||
generation-number
|
||||
|
@ -172,6 +173,18 @@ omitted or #f, use the first output of PACKAGE."
|
|||
(dependencies (delete-duplicates deps))
|
||||
(search-paths (package-native-search-paths package)))))
|
||||
|
||||
(define (packages->manifest packages)
|
||||
"Return a list of manifest entries, one for each item listed in PACKAGES.
|
||||
Elements of PACKAGES can be either package objects or package/string tuples
|
||||
denoting a specific output of a package."
|
||||
(manifest
|
||||
(map (match-lambda
|
||||
((package output)
|
||||
(package->manifest-entry package output))
|
||||
(package
|
||||
(package->manifest-entry package)))
|
||||
packages)))
|
||||
|
||||
(define (manifest->gexp manifest)
|
||||
"Return a representation of MANIFEST as a gexp."
|
||||
(define (entry->gexp entry)
|
||||
|
|
Loading…
Reference in New Issue