Commit Graph

326 Commits

Author SHA1 Message Date
Ricardo Wurmus
8e518d4802
guix: Update to Bioconductor 3.11.
* guix/build-system/r.scm (bioconductor-uri): Use new URL.
* guix/import/cran.scm (%bioconductor-version): Update to 3.11.
2020-06-13 01:19:38 +02:00
Tobias Geerinckx-Rice
35b00d4caa
import: stackage: Fix typo.
* guix/import/stackage.scm (latest-lts-release): Fix spelling of ‘if’.
2020-06-09 22:30:08 +02:00
Marius Bakke
2e08394b3c
import: stackage: Fix typo.
* guix/import/stackage.scm (latest-lts-release): Fix spelling of "included".
2020-06-09 20:43:36 +02:00
Ludovic Courtès
8d1d56578a
git: 'update-cached-checkout' returns the commit relation.
* guix/git.scm (update-cached-checkout): Add #:starting-commit
parameter.  Call 'commit-relation' when #:starting-commit is true.
Always return the relation or #f as the third value.
(latest-repository-commit): Adjust accordingly.
* guix/import/opam.scm (get-opam-repository): Likewise.
* tests/channels.scm ("latest-channel-instances includes channel dependencies")
("latest-channel-instances excludes duplicate channel dependencies"):
Update mock of 'update-cached-checkout' accordingly.
2020-05-25 00:00:28 +02:00
Ludovic Courtès
ce0be5675b
packages: Introduce <content-hash> and use it in <origin>.
* guix/packages.scm (<content-hash>): New record type.
(define-content-hash-constructor, build-content-hash)
(content-hash): New macros.
(print-content-hash): New procedure.
(<origin>): Rename constructor to '%origin'.
[sha256]: Remove field.
[hash]: New field.  Adjust users.
(origin-compatibility-helper, origin): New macros.
(origin-sha256): New deprecated procedure.
(origin->derivation): Adjust accordingly.
* tests/packages.scm ("package-source-derivation, origin, sha512"): New
test.
* guix/tests.scm: Hide (gcrypt hash) 'sha256' for proper syntax
matching.
* tests/challenge.scm: Add #:prefix for (gcrypt hash) and adjust users.
* tests/derivations.scm: Likewise.
* tests/store.scm: Likewise.
* tests/graph.scm ("bag DAG, including origins"): Provide 'sha256' field
with the right length.
* gnu/packages/aspell.scm (aspell-dictionary)
(aspell-dict-ca, aspell-dict-it): Use 'hash' and 'content-hash' for
proper syntax matching.
* gnu/packages/bash.scm (bash-patch): Rename 'sha256' to 'sha256-bv'.
* gnu/packages/bootstrap.scm (bootstrap-executable): Rename 'sha256' to 'bv'.
* gnu/packages/readline.scm (readline-patch): Likewise.
* gnu/packages/virtualization.scm (qemu-patch): Rename 'sha256' to
'sha256-bv'.
* guix/import/utils.scm: Hide (gcrypt hash) 'sha256'.
2020-05-22 01:29:39 +02:00
pimi
daf9fa94e2
guix: cran: Add missing default R package.
* guix/import/cran.scm (default-r-packages): Add "datasets" to the list of
default R packages.

Signed-off-by: Ricardo Wurmus <rekado@elephly.net>
2020-05-13 14:02:58 +02:00
nikita
3c986a7dc2
mailmap: Update entries for Nikita.
* .mailmap: change email and name for Nikita.
* Makefile.am, doc/guix.texi, etc/completion/fish/guix.fish,
gnu/packages/accessibility.scm, gnu/packages/admin.scm,
gnu/packages/audio.scm, gnu/packages/autotools.scm, gnu/packages/cdrom.scm,
gnu/packages/check.scm, gnu/packages/cinnamon.scm,
gnu/packages/compression.scm, gnu/packages/crypto.scm,
gnu/packages/databases.scm, gnu/packages/django.scm, gnu/packages/dns.scm,
gnu/packages/elixir.scm, gnu/packages/emacs-xyz.scm, gnu/packages/emacs.scm,
gnu/packages/enlightenment.scm, gnu/packages/erlang.scm,
gnu/packages/fonts.scm, gnu/packages/fontutils.scm, gnu/packages/forth.scm,
gnu/packages/fvwm.scm, gnu/packages/games.scm, gnu/packages/gl.scm,
gnu/packages/gnome.scm, gnu/packages/gnunet.scm, gnu/packages/gnupg.scm,
gnu/packages/gtk.scm, gnu/packages/guile-wm.scm, gnu/packages/guile-xyz.scm,
gnu/packages/haskell-apps.scm, gnu/packages/haskell-check.scm,
gnu/packages/haskell-crypto.scm, gnu/packages/haskell-xyz.scm,
gnu/packages/haskell.scm, gnu/packages/image-viewers.scm,
gnu/packages/image.scm, gnu/packages/irc.scm, gnu/packages/language.scm,
gnu/packages/libcanberra.scm, gnu/packages/linux.scm,
gnu/packages/lisp-xyz.scm, gnu/packages/lisp.scm, gnu/packages/lolcode.scm,
gnu/packages/lxde.scm, gnu/packages/lxqt.scm, gnu/packages/mail.scm,
gnu/packages/markup.scm, gnu/packages/mate.scm, gnu/packages/maths.scm,
gnu/packages/mc.scm, gnu/packages/messaging.scm, gnu/packages/music.scm,
gnu/packages/ncurses.scm, gnu/packages/networking.scm,
gnu/packages/nickle.scm, gnu/packages/openbox.scm, gnu/packages/pdf.scm,
gnu/packages/perl-check.scm, gnu/packages/perl.scm,
gnu/packages/python-compression.scm, gnu/packages/python-crypto.scm,
gnu/packages/python-web.scm, gnu/packages/python-xyz.scm,
gnu/packages/python.scm, gnu/packages/qt.scm, gnu/packages/ruby.scm,
gnu/packages/rust.scm, gnu/packages/scheme.scm,
gnu/packages/serialization.scm, gnu/packages/shells.scm,
gnu/packages/ssh.scm, gnu/packages/suckless.scm, gnu/packages/tbb.scm,
gnu/packages/telephony.scm, gnu/packages/text-editors.scm,
gnu/packages/textutils.scm, gnu/packages/time.scm, gnu/packages/tls.scm,
gnu/packages/tor.scm, gnu/packages/version-control.scm,
gnu/packages/video.scm, gnu/packages/vim.scm, gnu/packages/web.scm,
gnu/packages/wm.scm, gnu/packages/xdisorg.scm, gnu/packages/xfce.scm,
gnu/packages/xml.scm, gnu/packages/xorg.scm, gnu/services/certbot.scm,
gnu/services/desktop.scm, gnu/services/version-control.scm,
gnu/services/web.scm, guix/import/hackage.scm, guix/licenses.scm: Likewise.

Signed-off-by: Efraim Flashner <efraim@flashner.co.il>
2020-05-13 09:30:26 +03:00
Ludovic Courtès
5fbc753ab5
import: crate: Gracefully handle non-existent crates.
Fixes <https://bugs.gnu.org/40891>.
Reported by Hartmut Goebel <h.goebel@crazy-compilers.com>.

* guix/import/crate.scm (crate->guix-package): Wrap value of
'version-number' and 'version*' in (and crate ...).
2020-04-27 23:29:40 +02:00
Ricardo Wurmus
3c0422b9be
import/print: Don't factorize URI if there's no version match.
* guix/import/print.scm (package->code): If FACTORIZE-URI returns just the
unmodified string use that as the URI.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
3fd4c4c839
import/utils: alist->package: Include arguments.
* guix/import/utils.scm (alist->package): Process arguments field in input
data and include it in the generated package.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
7cef499bb0
import/json: json->code: Handle files with more than one definition.
* guix/import/json.scm (json->code): Convert JSON arrays to lists of package
definitions.
(json->scheme-file): Write all expressions to the target file.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
3532fc39ff
import/utils: alist->package: Ignore known inputs.
* guix/import/utils.scm (alist->package): Accept optional list of known
inputs, which are excluded from the specification lookup.
* guix/import/print.scm (package->code)[package-lists->code]: Handle inputs
which are just symbols.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
86a3b540d0
import/print: package->code: Wrap S-expression in definition.
* guix/import/print.scm (package->code): Return a definition, not just a
package expression.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
c893432320
import/json: Use json->code.
* guix/import/json.scm (json->code): Export procedure.
* guix/scripts/import/json.scm (guix-import-json): Use json->code.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
16dd764691
import/json: Add json->scheme-file.
* guix/import/json.scm (json->code, json->scheme-file): New procedures.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
6269dd567e
import/print: package->code: Wrap build system value in module reference.
* guix/import/print.scm (package->code): Return build system value with
corresponding module.
2020-04-16 23:41:52 +02:00
Ricardo Wurmus
1475d45112
import/print: Return license with prefix.
* guix/import/print.scm (license->code): Prepend license: prefix.
2020-04-16 23:41:49 +02:00
Ricardo Wurmus
9e17989017
import/cran: Import missing module.
This is a follow-up to commit b005c240bb5e436ffe9d55c2dd75c9af85aa0fdd.

Reported-by: Ludovic Courtès <ludo@gnu.org>

* guix/import/cran.scm: Import (guix ui) module.
2020-03-25 16:28:57 +01:00
Ricardo Wurmus
b005c240bb
import/cran: Support importing from Mercurial repositories.
* guix/import/cran.scm (download): Accept keyword #:method; add case for hg
method.
(fetch-description): Handle hg repository.
(description->package): Add cases for hg repositories and update call of
DOWNLOAD procedure.
(cran->guix-package): Retry importing from Bioconductor when hg import failed.
2020-03-25 09:40:05 +01:00
Martin Becze
cf2b91aad0
import: crate: Deduplicate dependencies.
* guix/import/crate.scm (crate-version-dependencies): Deduplicate crate dependencies.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-03-24 15:44:45 +01:00
Julien Lepiller
06f0453ad2
guix: import: opam: Use a default repository.
* guix/import/opam.scm (opam->guix-package): Use a default value for
`repository`.
2020-03-17 00:06:23 +01:00
Ludovic Courtès
c00ae79cca
import: cpan: Gracefully handle missing projects.
* guix/import/cpan.scm (cpan-fetch): Check whether 'json-fetch' returns #f.
2020-03-12 11:52:38 +01:00
Ludovic Courtès
2d0409a4a2
import: utils: Remove 'assoc-ref*'.
* guix/import/utils.scm (assoc-ref*): Remove.
2020-03-12 11:52:37 +01:00
Ludovic Courtès
7657e61d6b
import: pypi: Rewrite to use 'define-json-mapping'.
* guix/import/pypi.scm (non-empty-string-or-false): New procedure.
(<pypi-project>, <project-info>, <distribution>): New record types.
(pypi-fetch): Call 'json->pypi-project'.
(latest-source-release, latest-wheel-release): Use the new record
accessors instead of 'assoc-ref*'.
(pypi->guix-package, latest-release): Likewise.
* tests/pypi.scm (test-json): Add mandatory fields.
2020-03-12 11:52:37 +01:00
Ricardo Wurmus
c363722e81
import/cran: Add vignette builder to native inputs.
* guix/import/cran.scm (needs-knitr?): New procedure.
(description->package): Use it.
2020-03-07 19:31:47 +01:00
Lars-Dominik Braun
c8abbe1468
import: pypi: Add more licenses
* guix/import/pypi.scm (string->license): Add the BSD 2-clause and MPL 2.0
licenses, and add more strings for BSD 3-clause and Expat license.

Signed-off-by: Leo Famulari <leo@famulari.name>
2020-03-04 14:56:38 -05:00
Matt Wette
3d1e42321f
import: github: Use HTTP "Authorization" header for access tokens.
Fixes <https://bugs.gnu.org/39511>.

The "access_token" query parameter is now deprecated:

  https://developer.github.com/changes/2019-11-05-deprecated-passwords-and-authorizations-api/#authenticating-using-query-parameters

* guix/import/github.scm (fetch-releases-or-tags)[headers]: Add
"Authorization" header when (%github-token) is true.
[decorate]: Remove, and remove callers.
2020-02-22 12:17:35 +01:00
Jakub Kądziołka
9d0dfd9a9a
import: pypi: Support exporting packages with .zip source.
* guix/import/pypi.scm (make-pypi-sexp): Rename test-inputs to
  native-inputs. Restructure the way pypi-uri parameters are generated.
  Use pypi-uri's extension parameter when required. Add "unzip" to
  native inputs when the package source is a zip file.

Signed-off-by: Marius Bakke <mbakke@fastmail.com>
2020-02-05 22:03:35 +01:00
Ludovic Courtès
c24fe4a520
import: gem: Deal with unavailable licensing info.
Fixes <https://bugs.gnu.org/39404>.
Reported by Seth <lee.seth@tuta.io>.

* guix/import/gem.scm (<gem>)[licenses]: Adjust for non-vector
licenses.
* tests/gem.scm (test-bar-json): Change "licenses" to 'null'.
("gem-recursive-import"): Adjust accordingly.
2020-02-05 16:18:58 +01:00
Ludovic Courtès
23db833335
import: gem: Rewrite to use a JSON mapping to records.
* guix/import/gem.scm (<gem>, <gem-dependencies>, <gem-dependency>): New
record types with JSON mapping.
(json->gem-dependencies): New procedures.
(rubygems-fetch): Use it.
(hex-string->bytevector): Remove.
(make-gem-sexp): Expect HASH to be a bytevector.
(gem->guix-package): Adjust to use the new <gem> data type instead of an
alist.
(latest-release): Likewise.
2020-02-05 16:18:58 +01:00
Ludovic Courtès
6f918d69b4
import: texlive: Avoid uses of '@@' in tests.
* guix/import/texlive.scm (fetch-sxml, sxml->package): Export.
* tests/texlive.scm <top level>: Call '%http-server-port'.
("fetch-sxml: returns SXML for valid XML"): Use 'with-http-server' and
set 'current-http-proxy' instead of using 'mock'.
("sxml->package"): Remove use of '@@'.
2020-01-17 14:22:08 +01:00
Ludovic Courtès
282f91790a
import: opam: Avoid uses of '@@' in tests.
* guix/import/opam.scm (string-pat, multiline-string, list-pat)
(dict, condition): Export.
(opam-fetch): Add optional 'repository' parameter.
(opam->guix-package): Add #:repository parameter and pass it to
'opam-fetch'.
* tests/opam.scm ("opam->guix-package"): Remove use of 'mock' and pass
TEST-REPO to 'opam->guix-package' instead.
("parse-strings", "parse-multiline-strings")
("parse-lists", "parse-dicts", "parse-conditions"): Remove uses of '@@',
which are no longer needed.
2020-01-17 14:22:07 +01:00
Ludovic Courtès
9d6c6cb20e
import: elpa: Rewrite test to use an HTTP server instead of mocking.
* guix/import/elpa.scm (elpa-url): Add 'gnu/http'.
(elpa->guix-package): Handle it.
* tests/elpa.scm (elpa-package-info-mock, auctex-readme-mock)
(elpa-version->string, package-source-url, ensure-list)
(package-home-page, make-elpa-package): Remove.
<top level>: Call '%http-server-port'.
(eval-test-with-elpa): Remove uses of 'mock'.  Use 'with-http-server'
and parameterize 'current-http-proxy' instead.
2020-01-16 23:14:05 +01:00
Ludovic Courtès
cfd1ed8401
import: cran: Avoid uses of '@@' in the tests.
* guix/import/cran.scm (description->alist, description->package): Export.
<top level>: Set! 'listify'.
* tests/cran.scm (description-alist, "description->package"): Remove use
of '@@' to access the relevant bindings.
2020-01-16 23:14:05 +01:00
Ludovic Courtès
72c678af55
import: crate: Export 'string->license'.
* guix/import/crate.scm (string->license): Export.
* tests/crate.scm (string->license): Remove.
2020-01-16 23:14:05 +01:00
Ludovic Courtès
4aea90b187
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'.
2020-01-15 18:40:43 +01:00
Ludovic Courtès
69f132554c
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.
2020-01-15 18:40:43 +01:00
Ludovic Courtès
af0aefd8c1
import: cran: Fix file descriptor leak.
Fixes <https://bugs.gnu.org/38836>.
Reported by Ricardo Wurmus <rekado@elephly.net>.

* guix/import/cran.scm (bioconductor-packages-list): Close the port
returned by 'http-fetch/cached'.
(fetch-description): Likewise.
2020-01-03 16:06:26 +01:00
Ludovic Courtès
c7ca707b59
import: crate: Honor crate version for recursive imports.
Fixes <https://bugs.gnu.org/38709>.
Reported by Valentin Ignatev <valentignatev@gmail.com>.

* guix/import/crate.scm (crate-recursive-import): Add optional 'version'
parameter and honor it.
* guix/scripts/import/crate.scm (guix-import-crate): Pass VERSION as 2nd
argument to 'crate-recursive-import'.
2019-12-30 23:18:16 +01:00
Ricardo Wurmus
f431d5e299
guix: Upgrade to Bioconductor 3.10.
* guix/build-system/r.scm (bioconductor-uri): Switch to version 3.10.
* guix/import/cran.scm (%bioconductor-version): Same.
2019-12-15 15:38:51 +01:00
Ricardo Wurmus
e31ec53ed8
import: cran: Recognize LGPL 2.1+.
* guix/import/cran.scm (string->license): Add case for lgpl2.1+.
2019-12-14 13:35:58 +01:00
Ludovic Courtès
6212146f88
import: utils: Update docstring of 'recursive-import'.
This is a followup to 70a8e13277d4a44b89dd9ee2290b98105f0235f1.

* guix/import/utils.scm (recursive-import): Update docstring.
2019-12-13 18:04:04 +01:00
Brice Waegeneire
263a267b75
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>
2019-12-11 12:13:03 +01:00
Ludovic Courtès
70a8e13277
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>
2019-12-11 12:13:03 +01:00
Ludovic Courtès
ddd5915900
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.
2019-12-11 12:12:58 +01:00
Julien Lepiller
ba3ff730ca
guix: import: Fix importing dune project.
* guix/import/opam.scm: Detect dune projects from dependencies, then
filter dune from dependencies.
2019-11-30 15:50:51 +01:00
Julien Lepiller
c60d98d42d
guix: import: Fix opam importer.
* guix/import/opam.scm: Allow line breaks in strings.
2019-11-30 15:50:46 +01:00
Ludovic Courtès
c0e9d470e1
import: texlive: Handle multi-license packages.
This fixes "guix import texlive translator".

* guix/import/texlive.scm (sxml->package): Add clause for when 'license'
is a list of licences, as is the case with the "translator" package.
2019-11-22 15:00:59 +01:00
Timothy Sample
064a967ba0
gnu: Use GHC 8.6.5 as the main Haskell compiler.
* gnu/package/haskell.scm (ghc-8): Change to 'ghc-8.6'.
* guix/import/hackage.scm (ghc-standard-libraries): Add 'ghc-heap'
and 'libiserv'.
2019-11-20 20:47:48 -05:00
Martin Becze
f837293202
import: crate: Support recursive imports.
* guix/import/crate.scm (crate-recursive-import): New procedure.
(crate->guix-package): Return dependencies as a second value.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-10-01 23:34:30 +02:00