Age | Commit message (Collapse) | Author |
|
Use the supplied module path (instead of the repository root) as the import
path for everything except source and homepage URLs. For modules not in the
root of a VCS repository, set #:unpack-path to the repository root by default.
Partly fixes <https://issues.guix.gnu.org/50595>.
Reported by Stephen Paul Weber <singpolyma@singpolyma.net>.
* guix/import/go.scm (go-module->guix-package): Use 'module-path'
instead of 'root-module-path' for #:import-path. Emit #:unpack-path
when #:import-path is not equal to 'root-module-path'.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
This fixes one of the issues noted at <https://issues.guix.gnu.org/50425#4>.
* guix/import/minetest.scm
(release-version): New procedure.
(%minetest->guix-package): Call new procedure instead of release-title.
* tests/minetest.scm
(make-package-sexp): Allow overriding the version number.
(make-releases-json): Allow overriding the release title.
("conventional version number")
("v-prefixed version number")
("dates as version number"): New tests.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
This fixes one of the issues noted in <https://issues.guix.gnu.org/50425#4>.
* guix/import/minetest.scm
(import-dependencies): Call 'delete-duplicates' on the resulting list.
* tests/minetest.scm
("minetest->guix-package, multiple dependencies implemented by one mod"):
New test.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/git.scm (ls-remote-refs): New procedure.
* tests/git.scm ("remote-refs" "remote-refs: only tags"): New tests.
* guix/import/git.scm: New file.
* doc/guix.texi (Invoking guix refresh): Document it.
* tests/import-git.scm: New test file.
* Makefile.am (MODULES, SCM_TESTS): Register the new files.
Co-authored-by: Sarah Morgensen <iskarian@mgsn.dev>
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
Conflicts:
gnu/packages/bioinformatics.scm
gnu/packages/chez.scm
gnu/packages/docbook.scm
gnu/packages/ebook.scm
gnu/packages/gnome.scm
gnu/packages/linux.scm
gnu/packages/networking.scm
gnu/packages/python-web.scm
gnu/packages/python-xyz.scm
gnu/packages/tex.scm
gnu/packages/version-control.scm
gnu/packages/xml.scm
guix/build-system/dune.scm
guix/build-system/go.scm
guix/build-system/linux-module.scm
guix/packages.scm
|
|
* guix/import/cabal.scm (is-id): Accept the location as an argument. Don’t
check if the identifier name is a reserved keyword unless it is the first word
on the line.
(lex-word): Adjust accordingly.
* tests/hackage ("hackage->guix-package tests flag executable"): Expect it to
pass.
Fixes: <https://issues.guix.gnu.org/25138>
Signed-off-by: Lars-Dominik Braun <lars@6xq.net>
|
|
Otherwise, remotes without a branch named 'master' will cause an error when
importing.
* guix/import/elpa (git-repository->origin): Fallback to HEAD instead of the
'master' branch.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/go.scm (fetch-module-meta-data): If no meta entries
have a matching import prefix, return the first entry instead of #f.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/elpa.scm (elpa-url): Add NonGNU ELPA URL.
* doc/guix.texi (Invoking guix import): Document it.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
|
|
* guix/import/go.scm (go-module->guix-package*): Handle errors, remove
memoize.
(go-module-recursive-import): Remove 'guard', add memoize.
* guix/scripts/import/go.scm (guix-import-go): Adjust.
* tests/go.scm: Adjust.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/utils.scm (recursive-import): Skip packages when the
package returned by 'repo->guix-package' is false.
* tests/import-utils.scm: New tests.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/go.scm (go-module-recursive-import): Explicitly return
false when packages are not found.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
Conflicts:
gnu/packages/bioinformatics.scm
gnu/packages/cmake.scm
gnu/packages/curl.scm
gnu/packages/emacs-xyz.scm
gnu/packages/gpodder.scm
gnu/packages/music.scm
gnu/packages/patches/glibc-bootstrap-system.patch
gnu/packages/python-xyz.scm
gnu/packages/shells.scm
gnu/packages/statistics.scm
|
|
Once Chicken 6 gets released, we can just adjust the URL in the ‘egg-uri’
procedure, instead of having to change the URL for all the Chicken packages.
Making things a little more future-proof.
* guix/build-system/chicken.scm (egg-uri): New procedure.
* guix/import/egg.scm (egg-source-url): Adjust accordingly.
(egg->guix-package): Likewise.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/scripts/import/opam.scm: Pass all instances of --repo as a list
to the importer.
* guix/import/opam.scm (opam-fetch): Stop expecting "expanded"
repositories and call get-opam-repository instead to keep values
"symbolic" as long as possible and factorize.
(get-opam-repository): Use the same repository source as CLI opam does
(i.e. HTTP-served index.tar.gz instead of git repositories).
(find-latest-version): Be more flexible on the repositories structure
instead of expecting packages/PACKAGE-NAME/PACKAGE-NAME.VERSION/.
* tests/opam.scm: Update the call to opam->guix-package since repo is
now expected to be a list and remove the mocked get-opam-repository
deprecated by the support for local folders by the actual
implementation.
* doc/guix.texi: Document the new semantics and valid arguments for the
--repo option.
Signed-off-by: Julien Lepiller <julien@lepiller.eu>
|
|
* guix/import/contentdb.scm: New file.
* guix/scripts/import/contentdb.scm: New file.
* tests/contentdb.scm: New file.
* Makefile.am (MODULES, SCM_TESTS): Register them.
* po/guix/POTFILES.in: Likewise.
* doc/guix.texi (Invoking guix import): Document it.
Signed-off-by: Leo Prikler <leo.prikler@student.tugraz.at>
|
|
* guix/import/utils.scm (spdx-string->license): Recognise
GPL-N-only and GPL-N-or-later. Likewise for LGPL and AGPL.
Signed-off-by: Leo Prikler <leo.prikler@student.tugraz.at>
|
|
* guix/import/hackage.scm (hackage-module->sexp)[dependencies]
[native-dependencies]: Make into a list of symbols.
[maybe-inputs]: Wrap INPUTS in 'list' instead of 'quasiquote'.
* tests/hackage.scm (match-ghc-foo)
(match-ghc-foo-6)
(match-ghc-foo-revision)
(match-ghc-foo-import): Adjust accordingly.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/opam.scm (opam->guix-package): Wrap INPUTS and
NATIVE-INPUTS in 'list' instead of 'quasiquote'.
(dependency-list->inputs): Return a list of symbols.
* tests/opam.scm ("opam->guix-package"): Adjust accordingly.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/gem.scm (make-gem-sexp): Wrap inputs in 'list' instead of
'quasiquote'.
* tests/gem.scm ("gem->guix-package")
("gem-recursive-import"): Adjust accordingly.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/egg.scm (egg->guix-package): Generate dependency list from
a list of symbols.
[egg-parse-dependency]: Return a list of symbols.
[maybe-inputs]: Wrap INPUTS in 'list' instead of 'quasiquote'.
* tests/egg.scm (match-chicken-foo): Adjust accordingly.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/print.scm (package->code)<license->code>: Update generated
licence object to match record constructor.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
|
|
* guix/import/go.scm: Fix indentation.
|
|
Upgrade the go.mod parser to handle the full go.mod spec, and to gracefully
handle unexpected/malformed syntax. Restructure parser usage, making the
parse tree available for other uses.
guix/import/go.scm (parse-go.mod): Parse using (ice-9 peg) instead of
regex matching for more robustness. Return a list of directives.
(go.mod-directives): New procedure.
(go.mod-requirements): Likewise.
(go-module->guix-package): Use it.
(%go.mod-replace-directive-rx): Remove unused variable.
tests/go.scm (testing-parse-mod): Adjust accordingly.
(go.mod-requirements)
(fixture-go-mod-unparseable)
(fixture-go-mod-retract)
(fixture-go-mod-strings): New variables.
("parse-go.mod: simple")
("parse-go.mod: comments and unparseable lines")
("parse-go.mod: retract")
("parse-go.mod: raw strings and quoted strings")
("parse-go.mod: complete"): New tests.
Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
|
|
* guix/import/go.scm (fetch-module-meta-data): Parse all go-import meta
tags and return the first 'module-meta' with a matching import prefix.
[go-import->module-meta]: Extract parsing into new procedure.
Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
|
|
* guix/import/go.scm (go-package-licenses): Find license names in
'h2 // div // *text*' elements rather than 'h2 // *text*' elements.
Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
|
|
* guix/import/elpa.scm (elpa-package->sexp)[dependencies]: Turn into a
list of symbols.
[maybe-inputs]: Wrap in 'list' instead of 'quasiquote'.
|
|
* guix/import/print.scm (redundant-input-labels?): New procedure.
(package->code)[package-lists->code]: Rename to...
[inputs->code]: ... this. When 'redundant-input-labels?' returns true,
emit label-less inputs. Adjust callers to new name.
* tests/print.scm (pkg-with-inputs): Adjust accordingly.
|
|
* guix/import/cran.scm (format-inputs): Emit symbols or
'specification->package' calls.
(maybe-inputs): Wrap in 'list' instead of 'quasiquote'.
* tests/cran.scm ("description->package"): Adjust accordingly.
|
|
* guix/import/pypi.scm (maybe-inputs): Wrap PACKAGE-INPUTS in 'list'
instead of 'quasiquote'.
(compute-inputs)[requirement->package-name/sort]: Return a list of symbols.
* tests/pypi.scm ("pypi->guix-package, no wheel")
("pypi->guix-package, wheels"): Adjust accordingly.
|
|
* guix/import/opam.scm (records): Accept whitespace at the beginning.
|
|
Fixes <https://issues.guix.gnu.org/48111>.
* guix/import/go.scm (go-module->guix-package-name): Replace tildes with
hyphens.
Signed-off-by: Leo Prikler <leo.prikler@student.tugraz.at>
|
|
* guix/import/go.scm (go-package-description): Make sure description* is
always a list, so the result is properly matched.
Signed-off-by: Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
|
|
Fixes <https://issues.guix.gnu.org/48701>.
* guix/import/cabal.scm (make-cabal-parser): Modify.
(is-common): New variable.
(lex-common): New procedure.
(is-id): Modify.
(eval-cabal): Modify.
* tests/hackage.scm ("hackage->guix-package test cabal import") New test.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/egg.scm (egg->guix-package): Edit docstring.
|
|
* guix/import/launchpad.scm (latest-release): Rename 'origin-github-uri'
to 'origin-launchpad-uri'.
|
|
* guix/import/launchpad.scm (latest-released-version): Use repository instead
of package name.
(latest-release): Pass repository to latest-released-version.
Signed-off-by: Brice Waegeneire <brice@waegenei.re>
|
|
Fixes <https://bugs.gnu.org/49031>.
Reported by Emad Alblueshi <emad.albloushi@gmail.com>.
* guix/import/launchpad.scm (latest-released-version): Gracefully handle
'json-fetch' returning #f.
|
|
* guix/build-system/r.scm (bioconductor-uri): Update version.
* guix/import/cran.scm (%bioconductor-version): Update.
|
|
* guix/import/egg.scm: New file.
* guix/scripts/import/egg.scm: New file.
* tests/egg.scm: New file.
* Makefile.am (MODULES, SCM_TESTS): Register them.
* po/guix/POTFILES.in: Likewise.
* guix/scripts/import.scm (importers): Add egg importer.
* doc/guix.texi (Invoking guix import, Invoking guix refresh): Document it.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/opam.scm (opam->guix-package): Generate license for the
‘license’ field.
* tests/opam.scm (test-opam-file): Update accordingly.
("opam->guix-package"): Likewise.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/hackage.scm (string->license): Prefix the value of the license
field with ‘license:’.
* tests/hackage.scm (match-ghc-foo, match-ghc-foo-6, match-ghc-foo-revision):
Adjust accordingly.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
|
|
* guix/import/pypi.scm (parse-requires.txt): Document the parameter more
explicitly.
Signed-off-by: Leo Famulari <leo@famulari.name>
|
|
Fixes <https://bugs.gnu.org/47924>.
Reported by Carl Dong <contact@carldong.me>.
* guix/import/go.scm: Autoload (htmlprag).
|
|
This avoids interference with other users of (htmlprag) and makes the
intent clearer.
* guix/import/go.scm <top level>: Remove call to '%strict-tokenizer?'.
(go-package-licenses, go-package-description)
(go-package-synopsis, fetch-module-meta-data): Pass #:strict? #t to
'html->sxml'.
|
|
This importer has suffered from bitrot and no longer works with current
Nix and Nixpkgs. See <https://bugs.gnu.org/32339> and
<https://bugs.gnu.org/36255>.
* guix/import/snix.scm, guix/scripts/import/nix.scm,
tests/snix.scm: Remove.
* Makefile.am (MODULES, SCM_TESTS): Remove them.
* guix/scripts/import.scm (importers): Remove "nix".
* build-aux/test-env.in: Remove NIXPKGS variable.
* configure.ac: Remove '--with-nixpkgs' option.
* doc/guix.texi (Invoking guix import): Remove bit about "guix import
nix".
* etc/completion/fish/guix.fish: Likewise.
|
|
This allows importing packages with complicated version specific dependency
chains without the package symbol names colliding.
* doc/guix.texi (Invoking guix import): Document the --pin-versions option.
Mention that a specific version can be imported. Remove the experimental
warning.
* guix/import/go.scm (go-module->guix-package-name)[version]: Add optional
argument. Rewrite the character translation in terms of string-map.
(go-module->guix-package): Conditionally use dependencies whose symbol include
their version, based no the value of the PIN-VERSIONS? argument.
* guix/import/utils.scm (package->definition): Add a new case where the full
version string is appended to the package symbol.
* guix/scripts/import.scm (guix-import): Correctly print forms starting
with '(define-public [...]'.
* guix/scripts/import/go.scm (guix-import-go): Conditionally include the
version in the package symbols defined.
|
|
The ability to pin versions is handy when having to deal to packages that
bootstrap themselves through a chain of former versions. Not using pinned
versions in these case could introduce dependency cycles.
* guix/build-system/go.scm (guix)
(%go-version-rx): Rename to...
(%go-pseudo-version-rx): ... this. Simplify the regular expression, which in
turns makes it more robust.
* guix/build-system/go.scm (go-version->git-ref): Adjust following the above
rename.
(go-pseudo-version?): New predicate.
(go-module-latest-version): Rename to ...
(go-module-version-string): ... this. Rename goproxy-url argument to just
goproxy. Add a VERSION keyword argument, update docstring and adjust to have
it used.
(go-module-available-versions): New procedure.
(%go.mod-require-directive-rx): Document regexp.
(parse-go.mod): Harmonize the way dependencies are recorded to a list of lists
rather than a list of pairs, as done for other importers. Rewrite to directly pass
multiple values rather than a record object. Filter the replaced modules in a
functional style.
(go-module->guix-package): Add docstring.
[version, pin-versions?]: New arguments. Rename the GOPROXY-URL argument to
GOPROXY. Adjust to the new returned value of fetch-go.mod, which is a string.
Fail when the provided version doesn't exist. Return a list dependencies and
their versions when in pinned versions mode, else just the dependencies.
(go-module-recursive-import)[version, pin-versions?]: New arguments.
Honor the new arguments and guard against network errors.
* guix/scripts/import/go.scm (%default-options): Register a default value for
the goproxy argument.
(show-help): Document that a version can be specified. Remove the --version
argument and add a --pin-versions argument.
(%options)[version]: Remove option.
[pin-versions]: Add option.
(guix-import-go): Adjust so the version provided from the module name is
honored, along the new pin-versions? argument.
* tests/go.scm: Adjust and add new tests.
|