This allows users to write Bash commands like:
guix time-machine -C <(echo %default-channels) -- ...
or:
guix build -m <(echo '(specifications->manifest (list "guile"))')
Previously, on GNU/Linux, they would fail with:
error: failed to load '/dev/fd/63': No such file or directory
* guix/ui.scm (try-canonicalize-path): New procedure.
(load*): Use it.
* tests/guix-build.sh: Test 'guix build -m' with a /dev/fd/N file.
* doc/guix.texi (Invoking guix time-machine): Document limitation.
* guix/inferior.scm (cached-channel-instance): New VALIDATE-CHANNELS
argument. Use it to validate channels when there are no cache hit.
* guix/scripts/time-machine.scm
(%options): Tag the given reference with 'tag-or-commit instead of 'commit.
(%oldest-possible-commit): New variable.
(guix-time-machine) <validate-guix-channel>: New nested procedure. Pass it to
the 'cached-channel-instance' call.
* tests/guix-time-machine.sh: New test.
* Makefile.am (SH_TESTS): Register it.
Suggested-by: Simon Tournier <zimon.toutoune@gmail.com>
Reviewed-by: Ludovic Courtès <ludo@gnu.org>
Reviewed-by: Simon Tournier <zimon.toutoune@gmail.com>
The `pam-mount-volumes-service-type' adds additional volumes to the
pam-mount-service-type in addition to any that are already specified in
`pam-mount-rules'.
* doc/guix.texi (PAM Mount Volume Service): add documentation for
`pam-mount-service-type'.
* gnu/services/pam-mount.scm: new file.
* Makefile.am: add pam-mount tests
* tests/services/pam-mount.scm: new tests
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
The rationale is to reduce the number of derivations built per pack to ideally
one, to minimize storage requirements. The number of derivations had gone up
with 68380db4 ("pack: Extract populate-profile-root from
self-contained-tarball/builder.") as a side effect to improving code reuse.
* guix/scripts/pack.scm (guix): Add commentary comment.
(populate-profile-root, self-contained-tarball/builder): Extract to...
* guix/build/pack.scm (populate-profile-root): ... this, and...
(build-self-contained-tarball): ... that, adjusting for use on the build side.
(assert-utf8-locale): New procedure.
(self-contained-tarball, debian-archive, rpm-archive): Adjust accordingly.
Reviewed-by: Ludovic Courtès <ludo@gnu.org>
* guix/import/texlive.scm (tlpdb): Also retrieve so-called binfiles.
(formats):
(linked-scripts): New functions.
(tlpdb->package): Use new functions to set #:LINK-SCRIPTS argument and
possibly INPUTS.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package, single script, no extension"):
("texlive->guix-package, multiple scripts, with extensions"):
("texlive->guix-package, script with associated input"): New tests.
* guix/import/texlive.scm (latex-bin-dependency-tree): New function.
(tlpdb->package): Set #:TEXLIVE-LATEX-BIN? when appropriate.
* tests/texlive.scm ("texlive->guix-package, lonely `hyphen-base' dependency
and ARCH"): Update test.
* guix/import/texlive.scm (tlpdb->package): Meta packages should use trivial
build system and an appropriate builder.
* tests/texlive.scm ("texlive->guix-package, meta-package"):
("texlive->guix-package, translate dependencies"): Update tests.
* guix/import/texlive.scm (translate-depends): New function.
(tlpdb->package): Use new function.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package, translate dependencies"):
("texlive->guix-package, lonely `hyphen-base' dependency and ARCH"): New tests.
* guix/import/texlive.scm (tlpdb): Store "execute" entries.
(tlpdb->package): Add #:CREATE-FORMATS argument when there is an AddFormat
execute action.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package, with TeX format"):
("texlive->guix-package, execute but no TeX format"): New tests.
* guix/import/texlive.scm (tlpdb->package): Generate more appropriate source,
home page and license fields when importing meta packages, i.e., TeX Live
collections and schemes.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package, meta-package"): New test.
* guix/import/texlive.scm (tlpdb->package): Add TEXLIVE-METAFONT as a native
input whenever font metrics are to be generated.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package, with METAFONT files"): New test.
* guix/import/texlive.scm (string->license): Add missing case and try first to
split license strings before giving up.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package, multiple licenses"): New test.
* guix/import/texlive.scm (tlpdb): Also register `catalogue' key.
(tlpdb->package): First try to use catalogue for the home-page, then the
name.
* tests/texlive.scm (%fake-tlpdb): Add tests data.
("texlive->guix-package, with catalogue entry, no inputs"): New test.
* guix/import/texlive.scm (tlpdb->package): Generate a package that doesn't
need SIMPLE-TEXLIVE-PACKAGE.
* guix/import/utils.scm (package->definition): Remove special case for
`simple-texlive-package'.
* tests/texlive.scm (%fake-tlpdb): Add test data.
("texlive->guix-package"): Update test.
("texlive->guix-package, no docfiles"): New test.
Fixes <https://issues.guix.gnu.org/63048>.
Reported by Ekaitz Zarraga <ekaitz@elenq.tech>.
* gnu/home/services.scm (with-shell-quotation-bindings): New procedure.
(environment-variable-shell-definitions): Use it instead of inline copy.
* gnu/home/services/shells.scm (bash-serialize-aliases): Use it. Add
clause for 'literal-string?'.
* tests/guix-home.sh: Add 'aliases' to 'home-bash-extension' and test it.
With this change, commands such as 'guix build' or 'guix package' report
obvious package-level cycles upfront. Derivation-level cycles are not
detected.
* guix/packages.scm (&package-cyclic-dependency-error): New condition
type.
(package-transitive-supported-systems): Define 'visited', check it, and
parameterize it.
* guix/ui.scm (call-with-error-handling): Handle
'&package-cyclic-dependency-error'.
* tests/packages.scm ("package-transitive-supported-systems detects
cycles"): Add test.
Previously it would try to access the real elpa.gnu.org. This would
succeed when network is available because "taxy-magit-section" is an
existing package.
* guix/import/elpa.scm (elpa-repository)
(package-from-elpa-repository?): Recognize 'gnu/http.
* tests/elpa.scm ("package-latest-release"): Use 'http' instead of
'https'. Change "taxy-magit-section" to "fake-taxy-magit-section".
Previously it would try to access the real metacpan.org. This would
succeed when network is available because "Test-Script" is an existing
package.
* tests/cpan.scm ("package-latest-release"): Wrap
'upstream-source-inputs' call in 'parameterize'. Set
'current-http-proxy'. Change the order of responses in
'with-http-server'.
Fixes <https://issues.guix.gnu.org/63921>.
The regression was introduced in
dbbc7e9461, which changed the order of
services. As a result, someone using 'modify-services' could find
themselves with incorrect ordering of expressions in the "boot" script,
whereby the cleanup expressions would come after (execl ".../shepherd").
This, in turn, would lead shepherd to error out at boot with EADDRINUSE
on /var/run/shepherd/socket.
* gnu/services.scm (%delete-service, %apply-clauses): Remove.
(clause-alist): New macro.
(apply-clauses): New procedure.
(modify-services): Use it. Adjust docstring.
* tests/services.scm ("modify-services: do nothing"): Remove 'sort' call.
("modify-services: delete service"): Likewise, and add 't4' service.
("modify-services: change value"): Remove 'sort' call and fix expected value.
Turns out it's easier to read.
* tests/cpan.scm ("cpan->guix-package"): Use a quasiquoted pattern.
* tests/elpa.scm (eval-test-with-elpa): Likewise.
* tests/gem.scm ("gem->guix-package")
("gem->guix-package with a specific version")
("gem-recursive-import")
("gem-recursive-import with a specific version"): Likewise.
* tests/hexpm.scm ("hexpm-recursive-import"): Likewise.
* tests/opam.scm ("opam->guix-package"): Likewise.
* tests/pypi.scm ("pypi->guix-package, no wheel")
("pypi->guix-package, wheels")
("pypi->guix-package, no usable requirement file.")
("pypi->guix-package, package name contains \"-\" followed by digits"):
Likewise.
* tests/texlive.scm ("texlive->guix-package"): Likewise.
* guix/upstream.scm (update-package-inputs)[filtered-inputs]
[regular-inputs, native-inputs, propagated-inputs]: New procedures.
Use them in 'update-field' calls.
* tests/guix-refresh.sh (GUIX_TEST_UPDATER_TARGETS): Add "libreoffice"
to the dependencies of "the-test-package". Add 'updater-ignored-inputs'
property to "the-test-package".
* doc/guix.texi (Invoking guix refresh): Document it.
* guix/import/gem.scm (ruby-package-name): Add "bundler" special case.
(gem->guix-package): Adjust accordingly.
* tests/gem.scm ("gem-recursive-import")
("gem-recursive-import with a specific version"): Remove "ruby-bundler"
from the expected packages.
* guix/import/cpan.scm (cpan-name->downstream-name)
(cran-dependency->upstream-input, cran-module-inputs): New procedures.
(cpan-module->sexp)[guix-name, convert-inputs]: Remove.
[maybe-inputs]: Adjust to deal with <upstream-input>.
Use 'cpan-name->downstream-name' instead of 'guix-name'. Add call to
'cpan-module-inputs' and adjust calls to 'maybe-inputs'. No longer emit
input labels.
* tests/cpan.scm ("cpan->guix-package"): Adjust test accordingly.
Previously, 'guix refresh r-ggplot2 -u' and similar commands would print
of list of input changes that would have to be made manually. With this
change, 'guix refresh -u' takes care of updating input fields
automatically.
* guix/upstream.scm (update-package-inputs): New procedure.
(update-package-source): Call it when 'upstream-source-inputs' returns
true.
* guix/scripts/refresh.scm (update-package): Remove iteration over the
result of 'changed-inputs'.
* guix/import/test.scm (available-updates): Add support for input
lists.
* tests/guix-refresh.sh (GUIX_TEST_UPDATER_TARGETS): Add input list for
"the-test-package".
Make sure 'guix refresh -u' updates 'inputs' accordingly.
* doc/guix.texi (Invoking guix refresh): Mention it.
Returning the expected list of inputs rather than changes relative to
the current package definition is less ambiguous and offers more
possibilities for further processing.
* guix/upstream.scm (<upstream-source>)[input-changes]: Remove.
[inputs]: New field.
(<upstream-input>): New record type.
* guix/upstream.scm (upstream-input-type-predicate)
(input-type-filter, upstream-source-regular-inputs)
(upstream-source-native-inputs, upstream-source-propagated-inputs): New
procedures.
(changed-inputs): Expect an <upstream-source> as its second argument.
Adjust accordingly.
* guix/import/pypi.scm (distribution-sha256): New procedure.
(maybe-inputs): Expect a list of <upstream-input>.
(compute-inputs): Rewrite to return a list of <upstream-input>.
(pypi-package-inputs, pypi-package->upstream-source): New procedures.
(make-pypi-sexp): Use it.
* guix/import/stackage.scm (latest-lts-release): Define 'cabal'.
Replace 'input-changes' field by 'inputs'.
* guix/scripts/refresh.scm (update-package): Use 'changed-inputs'
instead of 'upstream-source-input-changes'.
* tests/cran.scm ("description->package"): Adjust order of inputs.
* tests/pypi.scm (default-sha256, default-sha256/base32): New variables.
(foo-json): Add 'digests' entry.
("pypi->guix-package, no wheel"): Check HASH against DEFAULT-SHA256/BASE32.
("pypi->guix-package, wheels"): Likewise.
("pypi->guix-package, no usable requirement file."): Likewise.
("pypi->guix-package, package name contains \"-\" followed by digits"):
Likewise.
("package-latest-release"): New test.
* tests/upstream.scm (test-package-sexp): Remove.
("changed-inputs returns no changes"): Rewrite to use <upstream-source>.
(test-new-package-sexp): Remove.
("changed-inputs returns changes to plain input list"): Rewrite.
("changed-inputs returns changes to all plain input lists"): Likewise.
("changed-inputs returns changes to labelled input list")
("changed-inputs returns changes to all labelled input lists"): Remove.
* guix/import/cran.scm (maybe-inputs): Expect PACKAGE-INPUTS to be a
list of <upstream-input>.
(source-dir->dependencies): Return a list of <upstream-input>.
(vignette-builders): Likewise.
(uri-helper, cran-package-source-url)
(cran-package-propagated-inputs, cran-package-inputs): New procedures.
(description->package): Use them instead of local definitions.
(latest-cran-release): Replace 'input-changes' field by 'inputs'.
(latest-bioconductor-release): Likewise.
(format-inputs): Remove.
* guix/import/hackage.scm (cabal-package-inputs): New procedure.
(hackage-module->sexp): Use it.
[maybe-inputs]: Expect a list of <upstream-input>.
* guix/import/pypi.scm (%pypi-base-url): New variable.
(pypi-fetch): Use it.
* tests/pypi.scm (foo-json): Compute URLs relative to '%local-url'.
(test-json-1, test-json-2, test-source-hash): Remove.
(file-dump): New procedure.
(with-pypi): New macro.
("pypi->guix-package, no wheel")
("pypi->guix-package, wheels")
("pypi->guix-package, no usable requirement file.")
("pypi->guix-package, package name contains \"-\" followed by digits"):
Rewrite using 'with-pypi'.
* tests/pypi.scm (sample-directory): New variable.
(pypi-tarball, wheel-file): New procedures.
("pypi->guix-package, no wheel")
("pypi->guix-package, wheels")
("pypi->guix-package, no usable requirement file.")
("pypi->guix-package, package name contains \"-\" followed by digits"):
Use them.
If a substitute server advertises in its narinfo, for example, both a
/zstd and a /lzip URL but the /zstd URL is unreachable, try the /lzip
URL.
Fixes <https://issues.guix.gnu.org/63634>.
* guix/narinfo.scm (narinfo-preferred-uris): New procedure.
(narinfo-best-uri): Rebase on top of it.
* guix/scripts/substitute.scm (download-nar)[try-fetch]: New procedure.
Use 'narinfo-preferred-uris' and 'try-fetch' to attempt all the URLs of
NARINFO.
* tests/substitute.scm (request-substitution): Remove 'parameterize'.
Delete DESTINATION.
("substitute, preferred nar URL is 404, other is 200"): New test.
Suggested by Maxim Cournoyer <maxim.cournoyer@gmail.com>
and Simon Tournier <zimon.toutoune@gmail.com>.
* guix/lint.scm (check-archival): Add 'local-file?' clause. Clarify
message in case (package-source package) is not an origin.
* tests/lint.scm ("archival: not an origin"): New test.
* guix/read-print.scm (read-with-comments): Check whether REST is a pair
before calling 'set-cdr!'.
* tests/read-print.scm ("read-with-comments: half dot notation"): New test.
Previously, a mere (arguments '(#:tests? #f)) would lead
guix style -S inputs --input-simplification=safe
to bail out. It now recognizes such trivial argument lists and
proceeds.
* guix/scripts/style.scm (trivial-package-arguments?): New procedure.
(simplify-package-inputs): Use it in the 'safe case instead of 'null?'.
* tests/style.scm ("input labels, 'safe' policy, trivial arguments"):
New test.
This is a followup to cb8d080349.
* tests/pypi.scm ("pypi->guix-package, no wheel")
("pypi->guix-package, wheels")
("pypi->guix-package, no usable requirement file.")
("pypi->guix-package, package name contains \"-\" followed by digits"):
Replace 'python-build-system' by 'pyproject-build-system'.
* tests/guix-graph.sh: Change the expected path from emacs to libffi. `guix
graph --path` outputs only one possible path, and the one it outputs for this
case has changed.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* tests/guix-build.sh: Do not try to rewrite gcc, it is hidden and so will not
be rewritten, as per eee95b5a87. Instead, try
to build grep with coreutils rewritten to hello.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* guix/read-print.scm (printed-string)[preserve-newlines?]: New
procedure.
Use it to preserve newlines on long strings.
* tests/read-print.scm: Add test.
* tests/guix-package-aliases.sh: "guix upgrade foo bar" has always
returned zero; adjust accordingly.
* tests/guix-refresh.sh: "guix refresh -t test idutils" and similar
return zero; adjust accordingly.
Addresses <https://issues.guix.gnu.org/62406>.
With 'set -e', a return status inverted with '!' does not cause the shell to
exit immediately. Instead use '&& false' to indicate an expected failure.
* tests/guix-archive.sh, tests/guix-build-branch.sh, tests/guix-build.sh,
tests/guix-daemon.sh, tests/guix-download.sh,
tests/guix-environment-container.sh, tests/guix-environment.sh,
tests/guix-gc.sh, tests/guix-git-authenticate.sh, tests/guix-graph.sh,
tests/guix-hash.sh, tests/guix-home.sh, tests/guix-pack-relocatable.sh,
tests/guix-pack.sh, tests/guix-package-aliases.sh, tests/guix-package-net.sh,
tests/guix-package.sh, tests/guix-refresh.sh, tests/guix-shell.sh,
tests/guix-style.sh, tests/guix-system.sh: Replace uses of '! ...' with
'... && false' or `test ! ...` as appropriate.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Desktop these days means having Rust support (GNOME), which i686 currently
lacks on Guix.
* tests/guix-system.sh: Do not attempt to build the desktop.tmpl image for
i686-linux.
The home page for the package had changed.
* tests/texlive.scm ("texlive->guix-package"): Match the home-page and
synopsis inexactly to avoid future similar breakages.
* guix/scripts/environment.scm (show-environment-options-help)
(%options): Add '--nesting'.
(options/resolve-packages): Handle it.
(launch-environment/container): Add #:nesting? and honor it.
[nesting-mappings]: New procedure.
(guix-environment*): Add support for '--nesting'.
* guix/scripts/shell.scm (profile-cached-gc-root): Special-case
'nesting?'.
* tests/guix-environment-container.sh: Test it.
* doc/guix.texi (Invoking guix shell): Document it.
This changes the 'custom-serializer' field into a generic
'extra-args' field that can be extended to support new literals.
Within extra-args, the literals 'sanitizer' and 'serializer' allow
for user-defined sanitization and serialization procedures respectively.
The 'empty-serializer' was also added as a literal to be used as before.
To prevent confusion between the new “explicit” style of specifying
a sanitizer, and the old “implicit” style, the latter has been
deprecated, and a warning is issued if it is encountered.
* gnu/services/configuration.scm (define-configuration-helper):
Rename 'custom-serializer' to 'extra-args'. Add support for literals
'sanitizer', 'serializer' and 'empty-serializer'. Rename procedure
'field-sanitizer' to 'default-field-sanitizer' to avoid syntax clash.
Only define default field sanitizers if user-defined ones are absent.
(normalize-extra-args): New variable.
(<configuration-field>)[sanitizer]: New field.
* doc/guix.texi (Complex Configurations): Document the newly added
literals.
* tests/services/configuration.scm: Add tests for the new literals.
Signed-off-by: Liliana Marie Prikler <liliana.prikler@gmail.com>
For the atftp package added in the preceeding commit, lint produced this
warning:
gnu/packages/networking.scm:2924:5: atftp@0.8.0:
URI https://git.code.sf.net/p/atftp/code not reachable:
404 ("Not Found")
Thanks to Sergey Trofimov for suggesting a fix! [1]
[1] https://issues.guix.gnu.org/62156#3
It was implemented here, and the warning disappeared.
* guix/lint.scm (check-source): Append "/info/refs" to git-reference-url.
Co-authored-by: Sergey Trofimov <sarg@sarg.org.ru>
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* tests/guix-home.sh: Reorder NIX_STORE_DIR variable definition to
prevent guix from crashing due to missing /gnu/store.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
The primary motivation is to support things like:
guix build guix --with-input=guile=guile-next
without triggering a rebuild of (@@ (gnu packages commencement)
guile-final) and similar things.
It is also consistent with package name resolution on the command line:
a package that cannot be named cannot be replaced.
* guix/packages.scm (package-input-rewriting/spec)[rewrite]: When P is
hidden, return it as-is.
* tests/packages.scm ("package-input-rewriting/spec, hidden package"):
New test.
* doc/guix.texi (Defining Package Variants): Update.
(Package Transformation Options): Update '--with-input' example.
* guix/packages.scm (package-direct-sources): Return 'origin' from 'patches'.
* tests/packages.scm: Test it.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Fixes <https://issues.guix.gnu.org/61013>.
Reported by Maxim Cournoyer <maxim.cournoyer@gmail.com>.
* guix/read-print.scm (pretty-print-with-comments)[starts-with-line-comment?]:
New procedure.
Use it when printing a list.
* tests/read-print.scm: Add two tests.
Fixes <https://issues.guix.gnu.org/61853>.
Fixes a regression introduced in
68380db4c4, whereby the tarball's root
entry is now read-only, due to the creation of "profile-directory" in
the store.
* tests/guix-pack.sh: Remove and recreate $test_directory before
transformation option test.
* tests/guix-pack-relocatable.sh: Add "chmod +w $test_directory" lines
before attempts to write to it.
Commit 68380db4c4 moved from
'gexp->derivation', which as a side effect, would lead tests to require
a "world rebuild"--specifically, they'd have to build (default-guile).
This was mitigated by 68775338a5, but that
change introduced another regression.
* guix/scripts/pack.scm (populate-profile-root): Define 'bootstrap?'.
Pass #:guile to 'computed-file', with a value depending on 'bootstrap?'.
* tests/pack.scm ("self-contained-tarball + localstatedir")
("docker-image + localstatedir", "squashfs-image + localstatedir")
("deb archive with symlinks and control files")
("rpm archive can be installed/uninstalled"): Use a <profile> record
instead of a derivation.
* guix/rpm.scm: New file.
* guix/scripts/pack.scm (rpm-archive): New procedure.
(%formats): Register it.
(show-formats): Add it.
(guix-pack): Register supported extra-options for the rpm format.
* tests/pack.scm (rpm-for-tests): New variable.
("rpm archive can be installed/uninstalled"): New test.
* tests/rpm.scm: New test.
* doc/guix.texi (Invoking guix pack): Document it.
Fixes <https://issues.guix.gnu.org/61156>.
* gnu/build/linux-container.scm (container-excursion): Add extra call to
'primitive-fork' and invoke THUNK in the child process.
* tests/containers.scm ("container-excursion"): Remove extra
'primitive-fork' call, now unnecessary.
("container-excursion*, /proc"): New test.
* gnu/build/linux-container.scm (container-excursion): Return the raw
status value.
* tests/containers.scm ("container-excursion, same namespaces"): Add
'status:exit-val' call.
* guix/scripts/container/exec.scm (guix-container-exec): Correctly
handle the different cases.
Previously this test would fail when HOME=/homeless-shelter and said
directory cannot be created.
* tests/guix-refresh.sh: Pass '--keyring' together with '-u'.
This is a followup to 8aeccc6240.
* guix/transformations.scm (package-with-upstream-version): New procedure.
(transform-package-latest)[package-with-latest-upstream]: Remove.
Use 'package-with-upstream-version' instead.
(transform-package-version): New procedure.
(%transformations, %transformation-options)
(show-transformation-options-help/detailed): Add '-with-version'.
* tests/transformations.scm ("options->transformation, with-version"):
New test.
* doc/guix.texi (Package Transformation Options): Document '--with-version'.
(Defining Package Variants): Mention it.
Fixes <https://issues.guix.gnu.org/60566> where even if "--preserve='^PATH$'"
was passed to 'guix shell' it would be replaced by just the FHS directories
when '--emulate-fhs' was also set.
* gnu/scripts/environment.scm (launch-environment): Add the FHS directories to
$PATH rather than overriding $PATH completely.
* tests/guix-environment-container.sh: Test that FHS directories are in $PATH
in the container and that $PATH can be preserved.
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
* guix/read-print.scm (%special-non-extended-symbols): New variable.
(symbol->display-string): New procedure.
(pretty-print-with-comments): Use it in lieu of 'string->symbol'.
* tests/read-print.scm: Add test.
* nix/libutil/hash.cc (parseHash): Show the hash algorithm name and
expected size in the error message.
* tests/derivations.scm ("fixed-output derivation, invalid hash size"):
New test.
Reported by Stephen Paul Weber <singpolyma@singpolyma.net> at
<https://lists.gnu.org/archive/html/guix-devel/2023-01/msg00035.html>.
* guix/derivations.scm (read-derivation)[outputs->alist]: Treat the
empty hash case as non-fixed-output whether or not the hash algorithm is
the empty string, and preserve the hash algorithm in <derivation-output>.
* tests/derivations.scm ("'download' built-in builder, no fixed-output hash")
("fixed-output-derivation?, no hash", "read-derivation with hash = #f"): New tests.
* gnu/home/services.scm (environment-variable-shell-definitions): Add support
for file-likes and gexps.
* tests/guix-home.sh: Add SHELL environment variable and test its value. Add
BUILDHOSTTIME environment variable.
* gnu/home/services.scm (<literal-string>): New record type.
(environment-variable-shell-definitions): Split 'shell-quote' into
'quote-string' and 'shell-double-quote'. Add 'shell-single-quote'.
Add clause for 'literal-string' records.
* tests/guix-home.sh: Test it.
* doc/guix.texi (Essential Home Services): Document it.
The regression was introduce with commit
a274a6a1ac ("upstream-updater: Rename record
field.")
* tests/tests/gnu-maintenance.scm: ("latest-html-release, scheme-less URIs",
"latest-html-release, no signature", "latest-html-release, signature"):
Replace upstream-updater-latest by upstream-updater-import.
Reported-by: Ricardo Wurmus <rekado@elephly.net>
* tests/import-utils.scm ("recursive-import", "recursive-import: skip false
packages (toplevel)", "recursive-import: skip false packages (dependency)"):
Do not try to match all arguments.
An example:
(match-record obj <my-type>
(field1 (field2 custom-var-name) field3)
...)
* guix/records.scm (match-record-inner): Add support for the new syntax.
* tests/records.scm ("match-record, simple"): Add a simple test case for the
new syntax.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
The next commits will make the functions, which are currently importing the
latest version of a package, change into importing the latest or a given
version of the package (for those updaters supporting specifying a version).
Thus the name ‘latest‘ is no longer appropriate.
* guix/upstream.scm (upstream-updater) Rename field [latest] to
[import]. (lookup-updater, package-latest-release) Adjust fieldname
accordingly.
* guix/gnu-maintenance.scm (%gnu-updater, %gnu-ftp-updater,
%savannah-updater, %sourceforge-updater, %xorg-updater,
%kernel.org-updater, %generic-html-updater),
guix/import/cpan.scm (%cpan-updater),
guix/import/cran.scm (%cran-updater, %bioconductor-updater),
guix/import/crate.scm (%crate-updater),
guix/import/egg.scm (%egg-updater),
guix/import/elpa.scm (%elpa-updater),
guix/import/gem.scm (%gem-updater),
guix/import/git.scm (%generic-git-updater),
guix/import/github.scm (%github-updater),
guix/import/gnome.scm (%gnome-updater),
guix/import/hackage.scm (%hackage-updater),
guix/import/hexpm.scm (%hexpm-updater),
guix/import/kde.scm (%kde-updater),
guix/import/launchpad.scm (%launchpad-updater),
guix/import/minetest.scm (%minetest-updater),
guix/import/opam.scm (%opam-updater),
guix/import/pypi.scm (%pypi-updater),
guix/import/stackage.scm (%stackage-updater),
tests/import-github.scm (found-sexp)
tests/transformations.scm ("options->transformation, with-latest"):
Adjust fieldname accordingly.
Fixes <https://issues.guix.gnu.org/60202>.
Reported by Christopher Baines <mail@cbaines.net>.
* tests/cpio.scm (%test-file): New variable.
("file->cpio-header + write-cpio-header + read-cpio-header"): Use it.
Skip test when the inode number of %TEST-FILE is too big.
With commit bbcd06e56c, the command
"guix package -s '^fileutils$'" would match the 'ocaml-fileutils'
package, because its 'package-upstream-name*' is "fileutils". Work
around it.
Reported by Vagrant Cascadian.
* tests/guix-package.sh: Change "fileutils" example to use a different
package name.