From 5401dd7595f558e759c82b1dede0c2fb687f296b Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Tue, 22 Jan 2013 22:13:10 +0100 Subject: guix-build: Allow version-qualified package names. * guix-build.in (guix-build)[find-package]: New procedure. Use it instead of using `find-packages-by-name' directly. Suggested by Andreas Enge . * tests/guix-build.sh: Add tests. * doc/guix.texi (Invoking guix-build): Add `coreutils-8.20' as an example. Fix guile-1.8 example. --- tests/guix-build.sh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/guix-build.sh b/tests/guix-build.sh index fccf2168b1..5718b07d0c 100644 --- a/tests/guix-build.sh +++ b/tests/guix-build.sh @@ -1,5 +1,5 @@ # GNU Guix --- Functional package management for GNU -# Copyright © 2012 Ludovic Courtès +# Copyright © 2012, 2013 Ludovic Courtès # # This file is part of GNU Guix. # @@ -50,3 +50,11 @@ if guix-build -r "$result" -e '(@@ (gnu packages base) %bootstrap-guile)' then false; else true; fi rm -f "$result" + +# Parsing package names and versions. +guix-build -n time # PASS +guix-build -n time-1.7 # PASS, version found +if guix-build -n time-3.2; # FAIL, version not found +then false; else true; fi +if guix-build -n something-that-will-never-exist; # FAIL +then false; else true; fi -- cgit v1.2.3