summaryrefslogtreecommitdiff
path: root/guix/scripts
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2014-08-12 16:10:32 +0200
committerLudovic Courtès <ludo@gnu.org>2014-08-12 16:10:32 +0200
commitf48624fc68165ca2e002342d6e45511fb5455d83 (patch)
tree6399c2b243dcce3349c5f7d569b96cc4ad0a22f6 /guix/scripts
parentf755403014e70d875541bcce5474d2cf410b5da1 (diff)
guix package: Use 'manifest-add'.
* guix/scripts/package.scm (guix-package)[process-actions]: Use 'manifest-add' instead of the equivalent code.
Diffstat (limited to 'guix/scripts')
-rw-r--r--guix/scripts/package.scm18
1 files changed, 4 insertions, 14 deletions
diff --git a/guix/scripts/package.scm b/guix/scripts/package.scm
index 4eb046e1c9..7c3ac24992 100644
--- a/guix/scripts/package.scm
+++ b/guix/scripts/package.scm
@@ -872,19 +872,8 @@ more information.~%"))
(let* ((manifest (profile-manifest profile))
(install (options->installable opts manifest))
(remove (options->removable opts manifest))
- (entries
- (append install
- (fold (lambda (package result)
- (match package
- (($ <manifest-entry> name _ out _ ...)
- (filter (negate
- (cut same-package? <>
- name out))
- result))))
- (manifest-entries
- (manifest-remove manifest remove))
- install)))
- (new (make-manifest entries)))
+ (new (manifest-add (manifest-remove manifest remove)
+ install)))
(when (equal? profile %current-profile)
(ensure-default-profile))
@@ -914,7 +903,8 @@ more information.~%"))
(name (generation-file-name profile
(+ 1 number))))
(and (build-derivations (%store) (list prof-drv))
- (let ((count (length entries)))
+ (let* ((entries (manifest-entries new))
+ (count (length entries)))
(switch-symlinks name prof)
(switch-symlinks profile name)
(maybe-register-gc-root (%store) profile)