From 30915a7419d48c6a5dcfdc3a1547268ac406a9ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Fri, 15 Jul 2022 12:45:32 +0200 Subject: [PATCH] shell: Ignore cached profiles when using '--export-manifest'. Fixes . Fixes a bug where "guix shell -D pkg --export-manifest" would provide the expansion of PKG's dependencies instead of a call to 'package-development-manifest' if that profile happened to be cached. * guix/scripts/shell.scm (profile-cached-gc-root): Add clause for 'export-manifest?. --- guix/scripts/shell.scm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/guix/scripts/shell.scm b/guix/scripts/shell.scm index 004ed7af2e..c115a00320 100644 --- a/guix/scripts/shell.scm +++ b/guix/scripts/shell.scm @@ -390,6 +390,11 @@ (define (key->file key) ;; If the user already specified a profile, there's nothing more to ;; cache. (values #f #f)) + ((('export-manifest? . #t) . _) + ;; When exporting a manifest, compute it anew so that '-D' packages + ;; lead to 'package-development-manifest' expressions rather than an + ;; expanded list of inputs. + (values #f #f)) ((('system . system) . rest) (loop rest system file specs)) ((_ . rest) (loop rest system file specs)))))