summaryrefslogtreecommitdiff
path: root/tests/guix-package.sh
AgeCommit message (Expand)Author
2013-09-25guix package: Do not list the zeroth generation....* guix/scripts/package.scm (guix-package)[process-query]: Change 'list-generation' to not list the zeroth generation. * tests/guix-package.sh: Test it. * doc/guix.texi (Invoking guix package): Document it, and use the right term when talking about generations. Nikita Karetnikov
2013-09-25guix package: Exit with 1 when a generation cannot be listed....* guix/scripts/package.scm (guix-package)[process-query]: Exit with 1 when a generation does not exist or the profile points to the zeroth generation. * tests/guix-package.sh: Test the former case. Nikita Karetnikov
2013-09-19guix package: Add '--list-generations'....* guix/scripts/package.scm: Import (srfi srfi-19). (generation-time, matching-generations): New functions. (show-help): Add '--list-generations'. (%options): Likewise. (guix-package)[process-query]: Add support for '--list-generations'. * guix/ui.scm: Import (srfi srfi-19) and (ice-9 regex). (string->generations, string->duration): New functions. * tests/guix-package.sh: Test '--list-generations'. * tests/ui.scm: Import (srfi srfi-19). Test 'string->generations' and 'string->duration'. * doc/guix.texi (Invoking guix-package): Document '--list-generations'. Nikita Karetnikov
2013-09-18tests: Clarify filtering of the "debug" output....* tests/guix-package.sh: Clearly filter out the "debug" output of 'gnu-make-boot0'. Ludovic Courtès
2013-07-10tests: Fix guix-package.sh in the presence of multiple-output `make'....* tests/guix-package.sh: For $boot_make_drv, take only the "out" output. Reported by Nikita Karetnikov <nikita@karetnikov.org>. Ludovic Courtès
2013-05-10package: Store the output path of packages installed with `-e'....* guix/scripts/package.scm (guix-package)[process-actions](package->tuple): Put the output path in the tuple, not the derivation path. * tests/guix-package.sh: Add test. Ludovic Courtès
2013-04-28guix package: Add `--search-paths' & co....* guix/scripts/package.scm (search-path-environment-variables, display-search-paths): New procedures. (show-help, %options): Add `--search-paths'. (guix-package)[process-actions]: Call `display-search-paths' once the profile is ready. [process-query]: Honor `search-paths'. Ludovic Courtès
2013-04-18tests: Use a new synopsis of GNU Hello....* tests/guix-package.sh: Use a new synopsis of GNU Hello, which was added in f50d2669e3e624365221cc81918ba55fdce94107. Nikita Karetnikov
2013-03-01guix package: Add `--install-from-expression'....* guix/scripts/package.scm (read/eval-package-expression): New procedure. (show-help): Add `-e'. (%options): Likewise. (guix-package)[process-actions]: Handle ('install . p) pairs, where P is a package. * tests/guix-package.sh: Add `boot_make_drv'. Use `-i $boot_make_drv' once, and then use `-e $boot_make'. * doc/guix.texi (Invoking guix package): Document `-e'. Ludovic Courtès
2013-02-16Replace individual scripts with master 'guix' script....* scripts/guix.in: New script. * Makefile.am (bin_SCRIPTS): Add 'scripts/guix'. Remove 'guix-build', 'guix-download', 'guix-import', 'guix-package', and 'guix-gc'. (MODULES): Add 'guix/scripts/build.scm', 'guix/scripts/download.scm', 'guix/scripts/import.scm', 'guix/scripts/package.scm', and 'guix/scripts/gc.scm'. * configure.ac (AC_CONFIG_FILES): Add 'scripts/guix'. Remove 'guix-build', 'guix-download', 'guix-import', 'guix-package', and 'guix-gc'. * guix-build.in, guix-download.in, guix-gc.in, guix-import.in, guix-package.in: Remove shell script boilerplate. Move to guix-COMMAND.in to guix/scripts/COMMAND.scm. Rename module from (guix-COMMAND) to (guix scripts COMMAND). Change "guix-COMMAND" to "guix COMMAND" in usage help string. * pre-inst-env.in: Add "@abs_top_builddir@/scripts" to the front of $PATH. Export $GUIX_UNINSTALLED. * tests/guix-build.sh, tests/guix-daemon.sh, tests/guix-download.sh, tests/guix-gc.sh, tests/guix-package.sh: Use "guix COMMAND" instead of "guix-COMMAND". * doc/guix.texi: Replace all occurrences of "guix-COMMAND" with "guix COMMAND". * po/POTFILES.in: Update. Mark H Weaver
2013-02-06guix-package: Test installation of packages by name....* tests/guix-package.sh: Remove `boot_guile'. Replace occurrences of $boot_guile by the `guile-bootstrap' package name. Ludovic Courtès
2013-02-01guix-package: Report `--search' matches in recutils format....* guix/ui.scm (fill-paragraph, string->recutils, package->recutils): New procedures. * guix-package.in (guix-package)[process-query]: Use `package->recutils' to display package meta-data. * tests/guix-package.sh: Adjust test. * tests/ui.scm: New file. * Makefile.am (TESTS): Add it. * doc/guix.texi (Invoking guix-package): Adjust `--search' documentation, and give an example. Ludovic Courtès
2013-02-01guix-package: Gracefully report non-existing outputs....* guix-package.in (guix-package)[find-package](ensure-output): New procedure. Use it to validate SUB-DRV. Ludovic Courtès
2013-01-28guix-package: Add '--search'....* guix-package.in (find-packages-by-description): New procedure. (show-help, %options): Add '--search'. (guix-package)[process-query]: Add support for '--search'. * doc/guix.texi (Invoking guix-package): Document it. * tests/guix-package.sh: Add tests. Nikita Karetnikov
2013-01-27guix-package: Always use the next number for new generations....Suggested by Andreas Enge <andreas@enge.fr> at <http://lists.gnu.org/archive/html/bug-guix/2013-01/msg00325.html>. * guix-package.in (latest-profile-number): Remove. (switch-symlinks): New procedure. (roll-back)[switch-link]: Use it. (guix-package)[process-actions]: Always choose NUMBER + 1 for the new profile. Use `switch-symlinks' instead of `symlink'. Remove code to delete PROFILE when it exists since `switch-symlinks' has the same effect. * tests/guix-package.sh: Adjust existing `--roll-back' tests. * doc/guix.texi (Invoking guix-package): Document this `--roll-back' behavior. Ludovic Courtès
2013-01-27guix-package: When rolling back to nothingness, point to the empty profile....Suggested by Andreas Enge <andreas@enge.fr> at <http://lists.gnu.org/archive/html/bug-guix/2013-01/msg00316.html>. * guix-package.in (roll-back): Check whether PROFILE is valid using `file-exists?'. When NUMBER is zero, just emit a notice. When PREVIOUS-NUMBER is zero and PREVIOUS-PROFILE does not exist, build the empty profile, and link to it. * tests/guix-package.sh: Add tests. * doc/guix.texi (Invoking guix-package): Document the new behavior. Ludovic Courtès
2013-01-24guix-package: Error out when passed a non-option argument....* guix-package.in (guix-package)[parse-options]: Call `leave' when passed a non-option argument. Reported by Andreas Enge <andreas@enge.fr>. * tests/guix-package.sh: Add test. Ludovic Courtès
2013-01-22guix-package: Fix `--roll-back' when `--profile' is not passed....* guix-package.in (roll-back): Fix file name of PREVIOUS-PROFILE, which could end up containing the dirname twice. Reported by Nikita and Andreas. * tests/guix-package.sh: Add test. Ludovic Courtès
2013-01-18distro: Change the module name space to (gnu ...)....* distro: Rename to... * gnu: ... this. Update module names accordingly. * Makefile.am: Adjust accordingly. * po/POTFILES.in: Likewise. * distro.scm: Search for files under /gnu/packages instead of /distro/packages. * gnu/packages/base.scm (ld-wrapper-boot3): Likewise. Ludovic Courtès
2013-01-17guix-package: Allow `--roll-back' to skip missing generations....* guix-package.in (profile-numbers): New procedure. (latest-profile-number): Use it. (previous-profile-number): New procedure. (roll-back): Use it lieu of `1-'. Check whether PREVIOUS-NUMBER is zero, and raise an error when it is. * tests/guix-package.sh: Test whether we can roll back over a "hole". Ludovic Courtès
2013-01-17guix-package: Add `--roll-back'....Based on a patch by Nikita Karetnikov <nikita@karetnikov.org>. * guix-package.in (profile-regexp): New procedure. (latest-profile-number): Remove `%profile-rx', and use `profile-regexp' instead. (profile-number, roll-back): New procedure. (show-help): Add `--roll-back'. (%options): Likewise. (guix-package)[process-actions]: First check whether `roll-back?' is among OPTS, and call `roll-back' if it is, followed by a recursive call to `process-actions'. Emit the "nothing to be done" message only when INSTALL or REMOVE is non-empty. * tests/guix-package.sh (readlink_base): New function. Add tests for `--roll-back'. * doc/guix.texi (Invoking guix-package): Document `--roll-back'. Ludovic Courtès
2013-01-14guix-package: Create or diagnose missing profile directory....Reported by Andreas Enge. * guix-package.in (%profile-directory): Honor $NIX_STATE_DIR. (guix-package)[ensure-default-profile]: Use it. [process-actions]: Call it when the `profile' option is %CURRENT-PROFILE. * tests/guix-package.sh: Add installation test with $HOME set, using the default profile. Ludovic Courtès
2013-01-14tests: Use "binutils:lib" as the `guix-package' example....* tests/guix-package.sh: Use "binutils:lib" instead of "libsigsegv:lib", since the latter no longer exists. Ludovic Courtès
2013-01-07guix-package: Remove `-b' shorthand for `--bootstrap'....* guix-package.in (%options): Remove #\b as an alternate for "bootstrap". (show-help): Adjust accordingly. * tests/guix-package.sh: Use `--bootstrap' instead of `-b'. Ludovic Courtès
2013-01-06Update license headers....Change all license headers, except guix/build/* and ld-wrapper.scm, with this code: (use-modules (guix build utils) (srfi srfi-1)) (fluid-set! %default-port-encoding "UTF-8") (substitute* (remove (lambda (f) (or (string-contains f ".tar.") (string-contains f ".git/") (string-contains f ".so") (string-suffix? ".o" f) (string-suffix? ".a" f) (string-suffix? ".go" f) (string-suffix? ".pdf" f) (string-suffix? ".png" f) (string-suffix? ".info" f) (equal? (basename f) "guix-daemon") (equal? (basename f) "nix-setuid-helper") (string-contains f "nix-upstream/") (string-contains f "distro/packages/bootstrap/"))) (find-files "." "\\.[a-z]+$")) (("^([[:graph:]]+) This file is part of Guix." _ comment-start) (string-append comment-start " This file is part of GNU Guix.")) (("^([[:graph:]]+) Guix --- Nix package management.*" _ comment-start) (string-append comment-start " GNU Guix --- Functional package management for GNU\n")) (("^([[:graph:]]+) Guix is " _ comment-start) (string-append comment-start " GNU Guix is ")) (("^([[:graph:]]+) along with Guix." _ comment-start) (string-append comment-start " along with GNU Guix.")) (("^([[:graph:]]+) Copyright \\(C\\)" _ comment-start) (string-append comment-start " Copyright ©"))) Change headers using C-style comments manually. Ludovic Courtès
2012-12-13Merge branch 'nix-integration'...Conflicts: tests/guix-package.sh Ludovic Courtès
2012-12-13tests: Skip network-dependent tests when the network is unreachable....* tests/builders.scm (network-reachable?): New variable. ("url-fetch", "gnu-build"): Skip unless NETWORK-REACHABLE?. * tests/derivations.scm (%coreutils): Check for network access. ("build-expression->derivation with one input"): Skip when %COREUTILS is #f. * tests/guix-package.sh: Skip installation of GNU Make when the network is unreachable. * tests/packages.scm ("GNU Make, bootstrap"): Likewise. * tests/union.scm ("union-build"): Likewise. Ludovic Courtès
2012-12-12tests: Remove `t-profile' files on exit....* tests/guix-package.sh: Use a trap on EXIT to remove profile-related files. Reported by Andreas Enge <andreas@enge.fr>. Ludovic Courtès
2012-12-12guix-package: Gracefully handle multiple installs of the same path....* guix-package.in (guix-package)[process-actions]: Compute PACKAGES such that packages listed in INSTALL* are first removed from the remainder of the list. When PROF is equal to the previous profile's store path, do nothing. Reported by Andreas Enge <andreas@enge.fr>. * tests/guix-package.sh: Test the behavior of installing the same store path twice. When removing a package, omit its version number. Ludovic Courtès
2012-11-19guix-package: Extract version strings when installing a direct store path....* guix-package.in (guix-package)[process-actions]: Extract the version string from store paths. * tests/guix-package.sh: Adjust accordingly. Ludovic Courtès
2012-11-19guix-package: Add `--list-available'....* guix-package.in (show-help, %options): Add `--list-available'. (guix-package)[process-query]: Add support for `--list-available'. * doc/guix.texi (Invoking guix-package): Document it. * tests/guix-package.sh: Add test. * guix/ui.scm (location->string): New procedure. * guix/utils.scm: Export <location>. Ludovic Courtès
2012-11-19guix-package: Add `--list-installed'....* guix-package.in (show-help, %options): Add `--list-installed'. (guix-package): Move main body to... [process-actions]: ... here. New internal procedure. [process-query]: New procedure. * tests/guix-package.sh: Add tests for `--list-installed'. * doc/guix.texi (Invoking guix-package): Document it. Ludovic Courtès
2012-11-07guix-package: Fix handling of the PACKAGE:OUTPUT syntax....* guix-package.in (guix-package)[find-package]: Return the correct NAME and SUB-DRV when NAME contains #\:. * tests/guix-package.sh (profile): Add test. Ludovic Courtès
2012-11-01Add a preliminary `guix-package' command-line tool....* guix-package.in, tests/guix-package.sh: New files. * configure.ac: Output `guix-package'. * Makefile.am (TESTS): Add `tests/guix-package.sh'. (bin_SCRIPTS): Add `guix-package'. Ludovic Courtès