mbox series

[bug#67503,0/2] Improvements to the go importer

Message ID cover.1701166089.git.efraim@flashner.co.il
Headers show
Series Improvements to the go importer | expand

Message

Efraim Flashner Nov. 28, 2023, 10:18 a.m. UTC
I had intended to do some go packaging but found myself working on the
go importer instead.

According to the upstream go documentation, go.mod IS supposed to list
the indirect dependencies so that when someone runs 'go build' or 'go
install' all the dependencies are already listed.  For us, the indirect
dependencies are already listed as propagated-inputs for the packages
which actually use them.

For the second patch I'm not super happy about using 'second' (yes,
(flatten (go.mod-directives go.mod 'go)) does return (version "1.18"))
but I couldn't find a nice way to return just the version string, and it
seemed better than cadr.  Using version>? was the simplest way to do the
version compare, but I can copy the logic over if we'd rather not import
(guix utils).

Efraim Flashner (2):
  guix: import: Don't include indirect dependencies in go.
  guix: import: Report go version for go importer.

 guix/import/go.scm | 37 +++++++++++++++++++++++++++++++------
 1 file changed, 31 insertions(+), 6 deletions(-)


base-commit: 62376e3eb67644454bc655bed56be4be965bd13e