summaryrefslogtreecommitdiff
path: root/guix
AgeCommit message (Collapse)Author
2019-09-21inferior: Propagate '&store-protocol-error' error conditions.Ludovic Courtès
Until now '&store-protocol-error' conditions raised in the inferior would not be correctly propagated because SRFI-35 records lack a read syntax. Reported at <https://bugs.gnu.org/37449> by Carl Dong <contact@carldong.me>. * guix/inferior.scm (port->inferior): Import (srfi srfi-34) in the inferior. (inferior-eval-with-store): Define 'error?' and 'error-message'. Wrap call to PROC in 'guard'. Check the response of INFERIOR for a 'store-protocol-error' or a 'result' tag. * tests/inferior.scm ("inferior-eval-with-store, &store-protocol-error"): New test.
2019-09-20import/github: Check for more version prefixes.Efraim Flashner
* guix/import/github.scm (latest-released-version): Allow the version string to begin with the word 'version'.
2019-09-19ui: 'relevance' connects regexps with a logical and.zimoun
Fixes <https://bugs.gnu.org/36763>. Previously, the logical and connecting the regexps did not output the expected results (introduced in 8874faaaac665100a095ef25e39c9a389f5a397f). * guix/ui.scm (relevance) [score]: Change its arguments. [regexp->score]: New procedure. * tests/ui.scm ("package-relevance"): Add test. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-09-18scripts: pull: Add options for generation managementKonrad Hinsen
* guix/scripts/pull.scm (%options) Add --roll-back, --switch-generation, --delete-generations (process-generation-change): New function (guix-pull): Execute generation management operations * doc/guix.texi: Document the generation management operations Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-09-18pull: Work around Ubuntu's 'sudo'.Ludovic Courtès
Partly fixes <https://bugs.gnu.org/36785>. Reported by Julien Lepiller <julien@lepiller.eu>. * guix/scripts/pull.scm (ensure-default-profile): Do not call 'migrate-generations' when "SUDO_USER" is set.
2019-09-18import: pypi: Refresher recognizes pythonhosted.org source URLs.Ludovic Courtès
This is a followup to a5376200541abf8245973e601be246bf65b8b6c7. Since that commit, 'pypi-package?' would return false for most Python packages, and thus "guix refresh python-xxx" would report that no updaters apply to the package. * guix/import/pypi.scm (pypi-package?)[pypi-url?]: Recognize "files.pythonhosted.org" URLs.
2019-09-18guix package: "guix package -f FILE" ensures FILE returns a package.Ludovic Courtès
* guix/scripts/package.scm (options->installable): Add clause for 'install option with a non-package object. * tests/guix-package.sh: Add test.
2019-09-16Revert "build-system/r: Use %bioconductor-version."Efraim Flashner
This reverts commit 41ca406fa54e69f61c55b11ffe5cf465192a907c. This commit breaks 'guix pull', as reported by Hao Chen.
2019-09-16build-system/r: Use %bioconductor-version.Ricardo Wurmus
* guix/build-system/r.scm (bioconductor-uri): Use %bioconductor-version instead of hard-coding the version string.
2019-09-16import/cran: Export %bioconductor-version.Ricardo Wurmus
* guix/import/cran.scm (%bioconductor-version): Export it.
2019-09-16pack: Provide a meaningful "repository name" for Docker.Ludovic Courtès
Previously, images produced by 'guix pack -f docker' would always show up as "profile" in the output of 'docker images'. With this change, 'docker images' shows a name constructed from the packages found in the image--e.g., "bash-coreutils-grep-sed". * guix/docker.scm (canonicalize-repository-name): New procedure. (generate-tag): Remove. (manifest): Add optional 'tag' parameter and honor it. (repositories): Likewise. (build-docker-image): Add #:repository parameter and pass it to 'manifest' and 'repositories'. * guix/scripts/pack.scm (docker-image)[build]: Compute 'tag' and pass it as #:repository to 'build-docker-image'.
2019-09-16pack: Add packages in the order in which they appear on the command line.Ludovic Courtès
* guix/scripts/pack.scm (guix-pack)[manifest-from-args](packages): Reverse order of packages taken from OPTS.
2019-09-14import/utils: beautify-description: Recognize more fragments.Ricardo Wurmus
* guix/import/utils.scm (beautify-description): Handle additional common initial sentence fragments in descriptions.
2019-09-13build-system/cargo: Remove unused function.Efraim Flashner
* guix/build/cargo-build-system.scm (touch): Remove it.
2019-09-13build-system/cargo: Use 'strip-store-file-name'.Efraim Flashner
This is a follow-up to f58b2f38e4dfdbb8473fb2816d44fae6ad9cbc79. * guix/build/cargo-build-system.scm (configure): Use bespoke 'strip-store-file-name' function.
2019-09-12file-systems: Add /var/run/nscd to '%network-file-mappings'.Ludovic Courtès
This allows containers created by "guix environment -CN" or by "guix system container -N" to talk to the host nscd. * gnu/system/file-systems.scm (%network-file-mappings): Add "/var/run/nscd". * gnu/build/shepherd.scm (default-mounts)[nscd-socket]: Remove. * gnu/system/linux-container.scm (container-script)[nscd-run-directory] [nscd-mapping, nscd-os, nscd-specs]: Remove. [script]: Filter out from SPECS bind-mounts where the device does not exist. * guix/scripts/environment.scm (launch-environment/container) [optional-mapping->fs]: New procedure. [mappings]: Remove %NETWORK-FILE-MAPPINGS. [file-systems]: Add %NETWORK-FILE-MAPPINGS here, filtered through 'optional-mapping->fs'.
2019-09-12build: cargo-build-system: Strip store hash from vendor-dir.Efraim Flashner
* guix/build/cargo-build-system.scm (configure): When copying the sources into the vendor-dir strip off the hash before the package name.
2019-09-10import: KDE updater finds packages even in sub-directory.Hartmut Goebel
Fixes <http://issues.guix.gnu.org/issue/30345> and finally fixes <http://issues.guix.gnu.org/issue/25020>. Formerly packages living in a path like /stable/frameworks/5.60/portingAids/kross-5.60.0.tar.xz have not been found. * guix/import/kde.scm (uri->kde-path-pattern): New procedure. (latest-kde-release): Use pattern to search for file.
2019-09-10upstream: Move KDE updater into a separate module.Hartmut Goebel
As it was done for (guix import gnome). * guix/import/kde.scm: New file. * Makefile.am (MODULES): Add it. * guix/gnu-maintenance.scm (%kde-updater) (%kde-file-list-uri) (download.kde.org-files) (latest-kde-release): Remove.
2019-09-10gnu-maintenance: KDE updater no longer relies on FTP access.Hartmut Goebel
Fetch the ls-lR.bz2 file list for download.kde.org, convert it into a list of file paths and cache the list. * guix/gnu-maintenance.scm (%kde-file-list-uri): New variable. (download.kde.org-files): New procedure. (latest-kde-release): Change to use DOWNLOAD.KDE.ORG-FILES and search for files in this list.
2019-09-10guix: Rename and move sans-extension to tarball-sans-extension.Hartmut Goebel
* guix/gnu-maintenance.scm (sans-extension): Move and rename to ... * guix/utils.scm (tarball-sans-extension): ... here.
2019-09-10import: crate: Allow imports of a specific version.Martin Becze
* guix/import/crate.scm (crate->guix-package): Add optional 'version' argument and honor it. * guix/scripts/import/crate.scm (guix-import-crate): Assume the first argument is a spec and destructure it with 'package-name->name+version'. Pass both to 'crate->guix-package'. * doc/guix.texi (Invoking guix import): Document it. Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2019-09-10refresh: Distinguish between "no updater" and "failing updater".Ludovic Courtès
Previously, something like "guix refresh texmacs" would report "no updater". Now, it reports that the 'gnu-ftp' updater failed to list releases. * guix/upstream.scm (lookup-updater): Use 'find' instead of 'any' to return the <upstream-updater>. (package-latest-release): Adjust accordingly. * guix/scripts/refresh.scm (check-for-package-update): When 'package-latest-release' returns #f, distinguish between "no updater" and "failing updater".
2019-09-10packages: 'package-field-location' really catches 'system-error.Ludovic Courtès
This had been wrong since forever (i.e., 2013). * guix/packages.scm (package-field-location): Catch 'system-error, not 'system.
2019-09-08import: github: Fix incorrect no-release case.Ludovic Courtès
This is a followup to 81c3dc32244a17241d74eea9fa265edfcb326f6d. Since that commit, when /releases returned an empty JSON array, we would not fall back to /tags because of the incorrect match. * guix/import/github.scm (fetch-releases-or-tags): Match the empty vector instead of the empty list.
2019-09-08daemon: Invoke 'guix gc --list-busy' instead of 'list-runtime-roots'.Ludovic Courtès
* nix/scripts/list-runtime-roots.in: Remove. * guix/store/roots.scm (%proc-directory): New variable. (proc-file-roots, proc-exe-roots, proc-cwd-roots) (proc-fd-roots, proc-maps-roots, proc-environ-roots) (referenced-files, canonicalize-store-item, busy-store-items): New procedures, taken from 'list-runtime-roots.in'. * nix/libstore/globals.hh (Settings)[guixProgram]: New field. * nix/libstore/globals.cc (Settings::processEnvironment): Initialize 'guixProgram'. * nix/libstore/gc.cc (addAdditionalRoots): Drop code related to 'NIX_ROOT_FINDER'. Run "guix gc --list-busy". * nix/local.mk (nodist_pkglibexec_SCRIPTS): Remove 'scripts/list-runtime-roots'. * config-daemon.ac: Don't output nix/scripts/list-runtime-roots. * build-aux/pre-inst-env.in: Don't set 'NIX_ROOT_FINDER'. Set 'GUIX'. * doc/guix.texi (Invoking guix gc): Document '--list-busy'. * guix/scripts/gc.scm (show-help, %options): Add "--list-busy". (guix-gc)[list-busy]: New procedure. Handle the 'list-busy' action.
2019-09-05download: Pass 'http_proxy' et al. to git, hg, etc.Ludovic Courtès
This allows 'git-fetch' etc. origins to honor the proxy and locale of the daemon. * guix/bzr-download.scm (bzr-fetch): Pass #:leaked-env-vars to 'gexp->derivation'. * guix/cvs-download.scm (cvs-fetch): Likewise. * guix/git-download.scm (git-fetch): Likewise. * guix/hg-download.scm (hg-fetch): Likewise. * guix/svn-download.scm (svn-multi-fetch): Likewise.
2019-09-05build-system/asdf: Add option to compress programs.Pierre Neidhardt
* guix/build/lisp-utils.scm (build-program): Add `compress?' key argument. (generate-executable-for-system): Same. (generate-executable): Same.
2019-09-05build-system/julia: Avoid module cycles.Marius Bakke
* guix/build-system/julia.scm: Remove unused imports. (lower)[julia]: Default to (DEFAULT-JULIA).
2019-09-04build-system/julia: Fix syntax error.Ricardo Wurmus
* guix/build-system/julia.scm: Fix invalid module reference.
2019-09-04import: opam: Use propagated-inputs instead of inputs.Julien Lepiller
* guix/import/opam.scm (opam->guix-package): Use propagated-inputs instead of inputs.
2019-09-04import: opam: Remove initial "v" in some version numbers.Julien Lepiller
* guix/import/opam.scm (opam-fetch): Remove initial "v" in some version numbers.
2019-09-04build: Add julia-build-system.nixo
* guix/build/julia-build-system.scm: New file. * guix/build-system/julia.scm: New file. * Makefile.am (MODULES): Add them. * doc/guix.texi (Build Systems): Document julia-build-system. Signed-off-by: Julien Lepiller <julien@lepiller.eu>
2019-09-04import: crate: Correct interpretation of dual-licensing strings.Ludovic Courtès
* guix/import/crate.scm (%dual-license-rx): New variable. (crate->guix-package)[string->license]: Rewrite to match it. * tests/crate.scm (test-crate): Adjust "license" field to current practice.
2019-09-04import: crate: Separate crates.io API from actual conversion.Ludovic Courtès
This provides a clean separation between bindings to the https://crates.io/api/v1 API and actual conversion to Guix package sexps. As a side-effect, it fixes things like "guix import blake2-rfc", "guix refresh -t crates", etc. * guix/import/crate.scm (<crate>, <crate-version>, <crate-dependency>): New record types. (lookup-crate, crate-version-dependencies): New procedures. (crate-fetch): Remove. (crate->guix-package): Rewrite to use the new API. (latest-release): Likewise. * guix/build-system/cargo.scm (%crate-base-url): New variable. * tests/crate.scm (test-crate): Update accordingly. fixlet
2019-09-04ci: Use (guix json) and adjust for Guile-JSON 3.x.Ludovic Courtès
This is in part a followup to 81c3dc32244a17241d74eea9fa265edfcb326f6d. * guix/ci.scm (<build>, <checkout>, <evaluation>): Define using 'define-json-mapping'. (json->build, json->checkout, json->evaluation): Remove. (queued-builds, latest-builds, latest-evaluations): Pass JSON arrays through 'vector->list' to adjust for Guile-JSON 3.x. (evaluations-for-commit): Fix typo to really export.
2019-09-04Add (guix json).Ludovic Courtès
* guix/swh.scm (define-json-reader, define-json-mapping): Move to... * guix/json.scm: ... here. New file. * Makefile.am (MODULES): Add it.
2019-09-04deploy: Add missing store options.Ludovic Courtès
* guix/scripts/deploy.scm (%default-options): Add missing options such as 'print-build-trace?', etc.
2019-09-02lint: Add 'archival' checker.Ludovic Courtès
* guix/lint.scm (check-archival): New procedure. (%network-dependent-checkers): Add 'archival' checker. * tests/lint.scm ("archival: missing content") ("archival: content available") ("archival: missing revision") ("archival: revision available") ("archival: rate limit reached"): New tests. * doc/guix.texi (Invoking guix lint): Document it.
2019-09-02swh: Make 'commit-id?' public.Ludovic Courtès
* guix/swh.scm (commit-id?): Make public.
2019-09-02swh: Add hooks for rate limiting handling.Ludovic Courtès
* guix/swh.scm (%allow-request?, %save-rate-limit-reset-time) (%general-rate-limit-reset-time): New variables. (request-rate-limit-reached?, update-rate-limit-reset-time!): New procedures. (call): Call '%allow-request?'. Change 'swh-error' protocol to pass METHOD in addition to URL. * tests/swh.scm ("rate limit reached") ("%allow-request? and request-rate-limit-reached?"): New tests.
2019-09-02tests: 'with-http-server' accepts multiple responses.Ludovic Courtès
* guix/tests/http.scm (call-with-http-server): Replace 'code' and 'data' parameters with 'responses+data'. Compute RESPONSES as a function of that. Remove #:headers parameter. [http-write]: Quit only when RESPONSES is empty. [server-body]: Get the response and data from RESPONSES, and set it to point to the rest. (with-http-server): Adjust accordingly. * tests/derivations.scm ("'download' built-in builder") ("'download' built-in builder, invalid hash") ("'download' built-in builder, not found") ("'download' built-in builder, check mode"): Adjust to new 'with-http-server' interface. * tests/lint.scm ("home-page: 200") ("home-page: 200 but short length") ("home-page: 404", "home-page: 301, invalid"): ("home-page: 301 -> 200", "home-page: 301 -> 404") ("source: 200", "source: 200 but short length") ("source: 404", "source: 404 and 200") ("source: 301 -> 200", "source: 301 -> 404"): ("github-url", github-url): Likewise. * tests/swh.scm (with-json-result) ("lookup-origin, not found"): Likewise.
2019-09-02import: cran: Only use the git import with what looks like a URL.Ricardo Wurmus
* guix/import/cran.scm (fetch-description): Abort if the argument does not look like a URL.
2019-09-02import: cran: Retry failed git imports on Bioconductor.Ricardo Wurmus
* guix/import/cran.scm (cran->guix-package): Retry failed git imports on Bioconductor.
2019-09-02build/cargo-build-system: Use invoke.Efraim Flashner
* guix/build/cargo-build-system.scm (crate-src?, build, check, install): Use 'invoke'.
2019-08-31lint: Gracefully handle errors from 'connect' & co.Ludovic Courtès
* guix/lint.scm (call-with-networking-fail-safe): Add case for 'system-error' as typically raised by 'connect' & co.
2019-08-30guix system: Reinstalling the bootloader preserves extra menu entries.Ludovic Courtès
Fixes <https://bugs.gnu.org/36876>. Reported by Jesse Gibbons <jgibbons2357@gmail.com>. Previously 'guix system delete-generations' or 'switch-generation' would lose the extra bootloader menu entries specified in the current system's configuration. This fixes that. * guix/scripts/system.scm (reinstall-bootloader): Turn PARAMS into a single <boot-parameters>. Adjust ENTRIES to include extra menu entries specified in PARAMS.
2019-08-30lint: formatting: Reporters return #f or a warning.Ludovic Courtès
* guix/lint.scm (report-tabulations, report-trailing-white-space) (report-long-line, report-lone-parentheses): Return #f instead of *unspecified* when there are no warnings. (report-formatting-issues): Use 'filter-map' instead of 'map' + 'filter'.
2019-08-29import: cran: Add support for git repositories.Ricardo Wurmus
* guix/import/cran.scm (vcs-file?): New procedure. (download): Support downloading from git. (fetch-description): Add a clause for the 'git repository type. (files-match-pattern?): New procedure. (tarball-files-match-pattern?): Implement in terms of FILES-MATCH-PATTERN?. (directory-needs-fortran?, directory-needs-zlib?, directory-needs-pkg-config?): New procedures. (needs-fortran?, needs-zlib?, needs-pkg-config?): Rename these procedures... (tarball-needs-fortran?, tarball-needs-zlib?, tarball-needs-pkg-config?): ...to this, and use them. (file-hash): New procedure. (description->package): Handle the 'git repository type. * guix/import/utils.scm (package->definition): Handle package expression inside of a let. * guix/scripts/import.scm (guix-import): Handle let expressions. * doc/guix.texi (Invoking guix import): Document it.
2019-08-29import: cran: guix-import-cran: Use (guix import utils).Ricardo Wurmus
* guix/scripts/import/cran.scm (guix-import-cran): Use PACKAGE->DEFINITION from (guix import utils) instead of custom procedure.