pack: Warn when building an empty pack.

* guix/scripts/pack.scm (guix-pack): Warn when MANIFEST has zero
entries.
This commit is contained in:
Ludovic Courtès 2019-05-21 14:49:58 +02:00
parent fd214f1522
commit 3f8326237d
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5
1 changed files with 3 additions and 0 deletions

View File

@ -891,6 +891,9 @@ Create a bundle of PACKAGE.\n"))
(localstatedir? (assoc-ref opts 'localstatedir?)) (localstatedir? (assoc-ref opts 'localstatedir?))
(profile-name (assoc-ref opts 'profile-name)) (profile-name (assoc-ref opts 'profile-name))
(gc-root (assoc-ref opts 'gc-root))) (gc-root (assoc-ref opts 'gc-root)))
(when (null? (manifest-entries manifest))
(warning (G_ "no packages specified; building an empty pack~%")))
(run-with-store store (run-with-store store
(mlet* %store-monad ((profile (profile-derivation (mlet* %store-monad ((profile (profile-derivation
manifest manifest