aboutsummaryrefslogtreecommitdiff
path: root/guix/store.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2014-03-07 00:18:28 +0100
committerLudovic Courtès <ludo@gnu.org>2014-03-07 00:19:03 +0100
commitcafb92d853c66b677111594727c586b87bbdd58f (patch)
tree277d0b271f5fee9faa572527f0729f15cb13df6c /guix/store.scm
parent4d01bd3c1ce8a986ebcf50c65a73cc87657f2360 (diff)
downloadgnu-guix-cafb92d853c66b677111594727c586b87bbdd58f.tar
gnu-guix-cafb92d853c66b677111594727c586b87bbdd58f.tar.gz
store: 'export-paths' doesn't export references of the given files.
This fixes a regression introduced in 99fbddf9a623757e39d88bfb431f8f7d6f24b75b ("store: Change 'export-paths' to always export in topological order.") * guix/store.scm (export-paths): Define 'ordered' variable. Iterate over it. * tests/store.scm ("export/import paths, ensure topological order"): Add 'file0'. Adjust accordingly.
Diffstat (limited to 'guix/store.scm')
-rw-r--r--guix/store.scm7
1 files changed, 6 insertions, 1 deletions
diff --git a/guix/store.scm b/guix/store.scm
index 54ed31cbbc..e92e159ff4 100644
--- a/guix/store.scm
+++ b/guix/store.scm
@@ -734,8 +734,13 @@ is raised if the set of paths read from PORT is not signed (as per
(define* (export-paths server paths port #:key (sign? #t))
"Export the store paths listed in PATHS to PORT, in topological order,
signing them if SIGN? is true."
+ (define ordered
+ ;; Sort PATHS, but don't include their references.
+ (filter (cut member <> paths)
+ (topologically-sorted server paths)))
+
(let ((s (nix-server-socket server)))
- (let loop ((paths (topologically-sorted server paths)))
+ (let loop ((paths ordered))
(match paths
(()
(write-int 0 port))