summaryrefslogtreecommitdiff
path: root/guix/scripts
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2022-06-19 15:50:50 +0200
committerLudovic Courtès <ludo@gnu.org>2022-07-03 01:41:06 +0200
commite7ab3d33aec3993737cdbc4396a9c44a54a3ce84 (patch)
tree3f0d9a7d2fb75b2d3665065b6d22a04aa3d0b3d0 /guix/scripts
parent4745be8514c6f99216c9636e0060f41818401f3e (diff)
downloadguix-patches-e7ab3d33aec3993737cdbc4396a9c44a54a3ce84.tar
guix-patches-e7ab3d33aec3993737cdbc4396a9c44a54a3ce84.tar.gz
challenge: Do nothing when passed zero arguments.
Previously, 'guix challenge' without arguments would list live store items that had been locally built. This was deemed confusing, especially since 'list-live' is an expensive operation. * guix/scripts/challenge.scm (guix-challenge): Warn and exit with 0 when FILES is empty. * doc/guix.texi (Invoking guix challenge): Update accordingly.
Diffstat (limited to 'guix/scripts')
-rw-r--r--guix/scripts/challenge.scm5
1 files changed, 3 insertions, 2 deletions
diff --git a/guix/scripts/challenge.scm b/guix/scripts/challenge.scm
index 5c0f837d13..f1e5f67dab 100644
--- a/guix/scripts/challenge.scm
+++ b/guix/scripts/challenge.scm
@@ -537,8 +537,9 @@ Challenge the substitutes for PACKAGE... provided by one or more servers.\n"))
(current-terminal-columns (terminal-columns)))
(let ((files (match files
(()
- (filter (cut locally-built? store <>)
- (live-paths store)))
+ (warning
+ (G_ "no arguments specified, nothing to do~%"))
+ (exit 0))
(x
files))))
(set-build-options store