Age | Commit message (Expand) | Author |
2020-01-16 | records: Improve reporting of "invalid field specifier" errors....Previously users would just see:
error: invalid field specifier
without source location or hints.
* guix/records.scm (expand): Add optional 'parent-form' parameter and
pass it to 'syntax-violation' when it is true.
(make-syntactic-constructor): Pass S as a third argument to
'report-invalid-field-specifier'.
* guix/ui.scm (report-load-error): For 'syntax-error', show SUBFORM or
FORM in the message.
* tests/records.scm ("define-record-type* & wrong field specifier"): Add
a 'subform' parameter and adjust test accordingly.
("define-record-type* & wrong field specifier, identifier"): New test.
* tests/guix-system.sh: Add test.
| Ludovic Courtès |
2020-01-16 | guix package: Export 'transaction-upgrade-entry'....* guix/scripts/package.scm (transaction-upgrade-entry): Add 'store'
parameter and use it instead of (%store). Export.
* tests/packages.scm ("transaction-upgrade-entry, zero upgrades")
("transaction-upgrade-entry, one upgrade")
("transaction-upgrade-entry, superseded package"): Adjust accordingly.
| Ludovic Courtès |
2020-01-16 | publish: Export 'signed-string'....* guix/scripts/publish.scm (signed-string): Export and improve docstring.
* tests/publish.scm ("/*.narinfo")
("/*.narinfo with properly encoded '+' sign"): Adjust accordingly.
| Ludovic Courtès |
2020-01-16 | graph: Add '--load-path' option....* guix/scripts/graph.scm (%option): Add '--load-path' option.
* doc/guix.texi: Document it.
* tests/guix-graph.sh: Test it.
| Pierre Neidhardt |
2020-01-15 | import: cpan: Rewrite tests to use an HTTP server instead of mocking....* guix/import/cpan.scm (%metacpan-base-url): New variable.
(module->dist-name, cpan-fetch): Refer to it instead of the hard-coded URL.
* tests/cpan.scm ("cpan->guix-package"): Use 'with-http-server' instead
of 'mock'.
| Ludovic Courtès |
2020-01-15 | import: cpan: Rewrite to use 'define-json-mapping'....* guix/import/cpan.scm (<cpan-dependency>, <cpan-release>): New
JSON-mapped record types.
(metacpan-url->mirror-url): New procedure.
(cpan-source-url): Rewrite in terms of it.
(cpan-version): Remove.
(cpan-module->sexp): Rewrite to take a <cpan-release> instead of an
alist, and rename 'meta' to 'release'.
[convert-inputs]: Rewrite to use 'cpan-release-dependencies'.
Update calls to 'convert-inputs' to pass a list of symbols.
Replace 'assoc-ref' calls with the appropriate field accessors.
(cpan->guix-package): Rename 'module-meta' to 'release'.
(latest-release): Likewise, and use the appropriate accessors.
* tests/cpan.scm (test-json): Remove "prereqs" record; add "dependency"
list.
("source-url-http", "source-url-https"): Remove.
("metacpan-url->mirror-url, http")
("metacpan-url->mirror-url, https"): New tests.
| Ludovic Courtès |
2020-01-04 | gexp: Add 'raw-derivation-file'....* guix/gexp.scm (<raw-derivation-file>): New record type.
(raw-derivation-file-compiler): New gexp compiler.
* tests/gexp.scm ("lower-gexp, raw-derivation-file")
("raw-derivation-file"): New tests.
| Ludovic Courtès |
2019-12-27 | git: 'commit-difference' takes a list of excluded commits....* guix/git.scm (commit-closure): Add 'visited' optional parameter.
(commit-difference): Add 'excluded' optional parameter; pass second
argument to 'commit-closure'.
* tests/git.scm ("commit-difference, excluded commits"): New test.
| Ludovic Courtès |
2019-12-26 | gnu: Remove squashfs-tools-next....* gnu/packages/compression.scm (squashfs-tools-next): Remove variable.
* guix/scripts/pack.scm (squashfs-image, guix-pack): Use squashfs-tools.
* tests/pack.scm: Use squashfs-tools.
| Ricardo Wurmus |
2019-12-18 | gexp: Allow character literals in GEXP->SEXP....Fixes <https://bugs.gnu.org/38628>.
* tests/gexp.scm ("lower-gexp, character literal"): New test.
* guix/gexp.scm (gexp->sexp)[self-quoting?]: Add CHAR? to the tested types.
* guix/repl.scm (self-quoting?): Likewise.
* gnu/tests.scm (marionette-shepherd-service)[self-quoting?]: Likewise.
| Marius Bakke |
2019-12-12 | challenge: Support "--diff=diffoscope"....* guix/scripts/challenge.scm (call-with-nar): New procedure.
(narinfo-contents): Express in terms of 'call-with-nar'.
(call-with-mismatches, report-differing-files/external): New
procedures.
(%diffoscope-command): New variable.
(%options): Support "diffoscope" and a string starting with "/".
* tests/challenge.scm (call-mismatch-test): New procedure.
("differing-files"): Rewrite in terms of 'call-mismatch-test'.
("call-with-mismatches"): New test.
* doc/guix.texi (Invoking guix challenge): Document it.
| Ludovic Courtès |
2019-12-12 | challenge: Add "--diff"....* guix/scripts/challenge.scm (dump-port*): New variable.
(archive-contents, store-item-contents, narinfo-contents)
(differing-files, report-differing-files): New procedures.
(summarize-report): Add #:report-differences and call it.
(show-help, %options): Add "--diff".
(%default-options): Add 'difference-report' key.
(report-differing-files): Parameterize CURRENT-TERMINAL-COLUMNS and pass
#:report-differences to 'summarize-report'.
* guix/tests/http.scm (%local-url): Add optional argument.
(call-with-http-server): Fix docstring typo.
* tests/challenge.scm (query-path-size, make-narinfo): New procedures.
("differing-files"): New test.
* doc/guix.texi (Invoking guix challenge): Document "--diff".
| Ludovic Courtès |
2019-12-12 | guix archive: Add '--list'....* guix/scripts/archive.scm (show-help, %options): Add '--list'.
(list-contents): New procedure.
(guix-archive): Honor the '--list' option.
* tests/guix-archive.sh: Test it.
* doc/guix.texi (Invoking guix archive): Document it.
| Ludovic Courtès |
2019-12-12 | serialization: Add 'fold-archive'....* guix/serialization.scm (read-contents): Remove.
(read-file-type, fold-archive): New procedures.
(restore-file): Rewrite in terms of 'fold-archive'.
* tests/nar.scm ("write-file-tree + fold-archive")
("write-file-tree + fold-archive, flat file"): New tests.
| Ludovic Courtès |
2019-12-11 | import: crate: Better handle license expressions....* guix/import/crate.scm (%dual-license-rx): Removed function.
(crate->guix-package): Handle most of the multi-licensing cases.
* tests/crate.scm (licenses): Add tests for some licenses.
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
| Brice Waegeneire |
2019-12-11 | import: crate: Add recursive import test....* tests/crate.scm (test-crate): Rename to...
(test-foo-crate): ... this.
(test-dependencies): Rename to...
(test-foo-dependencies): ... this.
(test-root-crate, test-root-dependencies, test-intermediate-1-crate)
(test-intermediate-1-dependencies, test-intermediate-2-crate)
(test-intermediate-2-dependencies, test-leaf-alice-crate)
(test-leaf-alice-dependencies, test-leaf-bob-crate)
(test-leaf-bob-dependencies): New variables.
("crate->guix-package"): Adjust accordingly.
("cargo-recursive-import"): New test.
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
| Brian Leung |
2019-12-11 | import: utils: 'recursive-import' returns a list rather than a stream....* guix/import/utils.scm (recursive-import): Remove 'list->stream' call.
* guix/scripts/import/cran.scm (guix-import-cran): Remove 'stream->list'
call.
* guix/scripts/import/crate.scm (guix-import-crate): Likewise.
* guix/scripts/import/elpa.scm (guix-import-elpa): Likewise.
* guix/scripts/import/gem.scm (guix-import-gem): Likewise.
* guix/scripts/import/hackage.scm (guix-import-hackage): Likewise.
* guix/scripts/import/opam.scm (guix-import-opam): Likewise.
* guix/scripts/import/pypi.scm (guix-import-pypi): Likewise.
* guix/scripts/import/stackage.scm (guix-import-stackage): Likewise.
* tests/gem.scm ("gem-recursive-import"): Likewise.
* tests/import-utils.scm ("recursive-import"): Likewise.
Co-authored-by: Brian Leung <bkleung89@gmail.com>
| Ludovic Courtès |
2019-12-11 | import: utils: 'recursive-import' returns packages in topological order....* guix/import/utils.scm (topological-sort): New procedure.
(recursive-import): Rewrite to use it.
* tests/import-utils.scm ("recursive-import"): New test.
* guix/import/cran.scm (cran->guix-package): Always return two values.
* guix/scripts/import/cran.scm (guix-import-cran): Remove 'reverse' call
on 'cran-recursive-import' result.
* guix/scripts/import/crate.scm (guix-import-crate): Likewise.
* guix/scripts/import/elpa.scm (guix-import-elpa): Likewise.
* guix/scripts/import/gem.scm (guix-import-gem): Likewise.
* guix/scripts/import/hackage.scm (guix-import-hackage): Likewise.
* guix/scripts/import/opam.scm (guix-import-opam): Likewise.
* guix/scripts/import/pypi.scm (guix-import-pypi): Likewise.
* guix/scripts/import/stackage.scm (guix-import-stackage): Likewise.
* tests/gem.scm ("gem-recursive-import"): Change the order of package
expressions accordingly.
| Ludovic Courtès |
2019-12-10 | tests: processes: Skip tests if running with binfmt....* tests/processes.scm (binfmt-misc?): New procedure,
(test-assert*): new procedure that skips the test if binfmt-misc? returns
| Mathieu Othacehe |
2019-12-08 | lint: Add '--load-path' option....* guix/scripts/lint.scm (%options): Add '--load-path' option.
* doc/guix.texi: Document it.
* tests/guix-lint.sh: Test it.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
| zimoun |
2019-12-07 | derivations: Add 'derivation-input-fold'....* guix/derivations.scm (derivation-input-fold): New procedure.
(substitution-oracle)[closure]: Rewrite in terms of
'derivation-input-fold'.
* tests/derivations.scm ("derivation-input-fold"): New test.
| Ludovic Courtès |
2019-12-01 | tests: lzlib: Do not fail if lzlib in not available....* tests/lzlib.scm: Use test-assert* for all test cases, so that there are no
failures if lzlib is unavailable.
| Mathieu Othacehe |
2019-11-30 | gexp: 'local-file' properly resolves non-literal relative file names....* guix/gexp.scm (local-file): Distinguish the case where FILE is a
literal string and when it's not. Add a clause for when FILE is not a
literal string.
* tests/gexp.scm ("local-file, non-literal relative file name"): New test.
* doc/guix.texi (G-Expressions): Update accordingly.
| Ludovic Courtès |
2019-11-29 | tests: Fix race condition in profile locking test....Previously, there was a possibility that "guix install emacs" would grab
the lock before "guix package -m $module_dir/manifest.scm". When that
happened, the test would start building Emacs and all its dependencies,
which could take a while and some disk space.
This is a followup to b1fb663404894268b5ee92c040f12c52c0bee425.
* tests/guix-package.sh: In profile locking test, emit
"$module_dir/ready" from the manifest and wait for it to exist before
running "guix install emacs".
| Ludovic Courtès |
2019-11-27 | substitute: Make '%allow-unauthenticated-substitutes?' public....* guix/scripts/substitute.scm (warn-about-missing-authentication): New
procedure.
(%allow-unauthenticated-substitutes?): Turn into a public parameter and
use 'warn-about-missing-authentication'.
(valid-narinfo?): Adjust accordingly.
* tests/substitute.scm (call-with-narinfo): Likewise.
| Ludovic Courtès |
2019-11-26 | tests: Avoid unnecessary use of 'mock'....* tests/build-utils.scm ("wrap-script, simple case"): Use the real
'which' instead of mocking it.
| Ludovic Courtès |
2019-11-26 | tests: Avoid (catch 'srfi-34 …) form....* tests/build-utils.scm ("wrap-script, raises condition"): Use 'guard'
instead of "catch 'srfi-34".
| Ludovic Courtès |
2019-11-23 | tests: Use (ice-9 threads)....'call-with-new-thread' as a core binding is deprecated in 2.2 and
removed in 3.0.
* tests/publish.scm: Use (ice-9 threads).
| Ludovic Courtès |
2019-11-22 | pack: Allow multiple '--manifest' options....* guix/scripts/pack.scm (guix-pack): Collect 'manifest' options, and
concatenate the resulting manifests.
* tests/guix-pack.sh: Test it.
* doc/guix.texi (Invoking guix pack): Document it.
| Ludovic Courtès |
2019-11-22 | package: Allow multiple '--manifest' options....* guix/scripts/package.scm (manifest-action): Remove.
(%actions): Remove it.
(load-manifest): New procedure.
(process-actions): Handle 'manifest' options. Define 'files' from
'manifest' options. Define 'manifest' based on FILES. Define 'trans'
to represent the final transaction.
* tests/guix-package.sh: Test it.
* doc/guix.texi (Invoking guix package): Mention
| Ludovic Courtès |
2019-11-22 | profiles: Add 'concatenate-manifests'....* guix/profiles.scm (concatenate-manifests): New procedure.
* tests/profiles.scm ("concatenate-manifests"): New test.
| Ludovic Courtès |
2019-11-22 | environment: Document that '--manifest' can be repeated....* tests/guix-environment.sh: Test 'guix environment' with two '-m' options.
* doc/guix.texi (Invoking guix environment): Explain that '-m' can be
passed multiple times.
| Ludovic Courtès |
2019-11-21 | pack: Add "--derivation"....* guix/scripts/pack.scm (%options, show-help): Add "--derivation".
(guix-pack): Honor it.
* tests/guix-pack.sh: Test it.
* doc/guix.texi (Invoking guix pack): Document it.
| Ludovic Courtès |
2019-11-17 | guix build: Handle "guix build /….drv" correctly for non-existent derivations....This lets the daemon substitute missing derivations, as in the example
at <https://bugs.gnu.org/38226>, instead of failing with ENOENT.
* guix/scripts/build.scm (options->things-to-build): In the
'derivation-path?' case, don't fail when 'read-derivation-from-file'
raises to ENOENT; return the empty list in that case.
(guix-build): Add non-existent '.drv' files to ITEMS.
Pass ITEMS in addition to DRV to 'build-derivations'.
* tests/guix-build.sh: Add test.
| Ludovic Courtès |
2019-11-17 | tests: Test "guix build /gnu/store/….drv"....* tests/guix-build.sh: Add test for passing "guix build" a .drv.
| Ludovic Courtès |
2019-11-08 | guix: package: lock profiles when processing them....* guix/scripts/package.scm (process-actions): Get a per-profile lock to
prevent concurrent actions on profiles.
* tests/guix-package.sh: Add test.
| Julien Lepiller |
2019-11-07 | graph: Support package transformation options....* guix/scripts/graph.scm (%options): Append %TRANSFORMATION-OPTIONS.
(show-help): Call 'show-transformation-options-help'.
(guix-graph): Call 'options->transformation' and use it.
* tests/guix-graph.sh: Add test.
* doc/guix.texi (Invoking guix graph): Document it.
| Ludovic Courtès |
2019-11-07 | gnu: commencement: Ensure 'gnu-make-final' refers to the native 'pkg-config'....Fixes <https://bugs.gnu.org/38093>.
When running:
guix build --target=arm-linux-gnueabihf -e '(@ (gnu packages base) coreutils)'
the '%current-target-system' parameter is set by the time the top-level
of (gnu packages commencement) is evaluated. Consequently, we need to
ensure that the 'pkg-config' macro evaluates in a context where
'%current-target-system' is unset.
* gnu/packages/commencement.scm (gnu-make-final): Refer to '%pkg-config'
instead of 'pkg-config'.
* tests/guix-build.sh: Add test.
| Ludovic Courtès |
2019-10-30 | services: ntp: Ensure no double quotes are output to config file....* gnu/services/networking.scm (ntp-server->string): Use the textual
representation of the values as printed by 'display' rather than 'write', to
avoid inserting double quotes in the generated config.
* tests/networking.scm (%ntp-server-sample): Add a comment and make one of the
options a string, to exercise the fix.
("ntp-server->string"): Move the expected value to the first argument.
("ntp configuration servers deprecated form"): Likewise.
("openntpd generated config string ends with a newline"): Likewise.
| Maxim Cournoyer |
2019-10-23 | cve: Rewrite to read the JSON feed instead of the XML feed....The XML feed was discontinued on Oct. 16th, 2019:
<https://nvd.nist.gov/General/News/XML-Vulnerability-Feed-Retirement-Phase-3>
* guix/cve.scm (string->date*): New procedure.
(<cve-item>, <cve>, <cve-reference>): New record types.
(cpe-match->cve-configuration, configuration-data->cve-configurations)
(json->cve-items, version-matches?): New procedures.
(yearly-feed-uri): Change URL to refer to JSON feed.
(cpe->product-alist, %parse-vulnerability-feed)
(xml->vulnerabilities): Remove.
(cve-configuration->package-list, merge-package-lists)
(cve-item->vulnerability, json->vulnerabilities): New procedures.
(write-cache): Use 'json->vulnerabilities' instead of
'xml->vulnerabilities', and remove 'parameterize'.
(vulnerabilities->lookup-proc): Use 'version-matches?' when VERSION is
true.
* tests/cve.scm (%sample): Use 'tests/cve-sample.json'.
(%expected-vulnerabilities): Rewrite accordingly.
("json->cve-items", "cve-item-published-date")
("json->vulnerabilities"): New tests.
("xml->vulnerabilities"): Remove.
("vulnerabilities->lookup-proc"): Adjust to new vulnerabilities.
* tests/cve-sample.json: New file.
* tests/cve-sample.xml: Remove.
* Makefile.am (EXTRA_DIST): Adjust accordingly.
* doc/guix.texi (Invoking guix lint): Update nist.gov URLs.
| Ludovic Courtès |
2019-10-20 | tests: Avoid now-deprecated 'make-struct'....* tests/cve.scm (vulnerability): Use 'make-struct/no-tail' instead of
'make-struct', which is deprecated.
* tests/lint.scm ("cve: one vulnerability")
("cve: one patched vulnerability")
("cve: known safe from vulnerability")
("cve: vulnerability fixed in replacement version")
("cve: patched vulnerability in replacement"): Likewise.
| Ludovic Courtès |
2019-10-16 | daemon: Make 'profiles/per-user' non-world-writable....Fixes <https://bugs.gnu.org/37744>.
Reported at <https://www.openwall.com/lists/oss-security/2019/10/09/4>.
Based on Nix commit 5a303093dcae1e5ce9212616ef18f2ca51020b0d
by Eelco Dolstra <edolstra@gmail.com>.
* nix/libstore/local-store.cc (LocalStore::LocalStore): Set 'perUserDir'
to #o755 instead of #o1777.
(LocalStore::createUser): New function.
* nix/libstore/local-store.hh (LocalStore): Add it.
* nix/libstore/store-api.hh (StoreAPI): Add it.
* nix/nix-daemon/nix-daemon.cc (performOp): In 'wopSetOptions', add
condition to handle "user-name" property and honor it.
(processConnection): Add 'userId' parameter. Call 'store->createUser'
when userId is not -1.
* guix/profiles.scm (ensure-profile-directory): Note that this is now
handled by the daemon.
* guix/store.scm (current-user-name): New procedure.
(set-build-options): Add #:user-name parameter and pass it to the daemon.
* tests/guix-daemon.sh: Test the creation of 'profiles/per-user' when
listening on a TCP socket.
* tests/store.scm ("profiles/per-user exists and is not writable")
("profiles/per-user/$USER exists"): New tests.
| Ludovic Courtès |
2019-10-15 | tests: Skip container test when lacking kernel support....This is a followup to 96b35998e610c7fc37bf87bf9e07e63d3bebd0a3.
* tests/containers.scm ("eval/container, non-empty load path"): Add
missing 'skip-if-unsupported' call.
| Ludovic Courtès |
2019-10-06 | Merge branch 'master' into core-updates | Ricardo Wurmus |
2019-10-05 | syscalls: Add 'add-to-entropy-count'....* guix/build/syscalls.scm (RNDADDTOENTCNT): New variable.
(add-to-entropy-count): New procedure.
* tests/syscalls.scm ("add-to-entropy-count"): New test.
| Ludovic Courtès |
2019-10-03 | environment: '--container' honors '--preserve'....* guix/scripts/environment.scm (launch-environment/container): Add
#:white-list parameter and honor it.
(guix-environment): Pass #:white-list to 'launch-environment/container'.
* tests/guix-environment-container.sh: Add test.
| Ludovic Courtès |
2019-09-27 | Merge branch 'master' into core-updates | Marius Bakke |
2019-09-26 | guix package: Add '--list-profiles'....* guix/scripts/package.scm (show-help, %options): Add '--list-profiles'.
(process-query): Honor it.
* tests/guix-package.sh: Add test.
| Ludovic Courtès |
2019-09-24 | Merge branch 'master' into core-updates | Ludovic Courtès |
2019-09-23 | gexp: Catch and report non-self-quoting gexp inputs....Previously we would, for example, generate build scripts in the store;
when trying to run them, we'd get a 'read' error due to the presence
of #<foo> syntax in there.
* guix/gexp.scm (gexp->sexp)[self-quoting?]: New procedure.
[reference->sexp]: Check whether the argument in a <gexp-input> box is
self-quoting. Raise a '&gexp-input-error' condition if it's not.
* tests/gexp.scm ("lower-gexp, non-self-quoting input"): New test.
| Ludovic Courtès |