all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#47310] [PATCH 0/4] Improve parsing of synopsis and description, add pinned versions mode
@ 2021-03-22  4:10 Maxim Cournoyer
  2021-03-22  4:20 ` [bug#47310] [PATCH 1/4] import: utils: Refactor maybe-inputs and add maybe-propagated-inputs Maxim Cournoyer
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Maxim Cournoyer @ 2021-03-22  4:10 UTC (permalink / raw)
  To: 47310

Hi Guix!

This furthers the Go importer some more by adding better parsing of the
description and synopsis field.  It's now also possible to import specific
versions, or to import dependencies at the exact version.

A good example to try this new mode with is the protobuf package at version
1.24.0, which is what originally motivated this change:

./pre-inst-env guix import go -r --pin-versions google.golang.org/protobuf@v1.24.0

--8<---------------cut here---------------start------------->8---
(define-public go-google-golang-org-protobuf-1.23.1-0.20200526195155-81db48ad09cc
  (package
    (name "go-google-golang-org-protobuf")
    (version "1.23.1-0.20200526195155-81db48ad09cc")
    (source
      (origin
        (method git-fetch)
        (uri (git-reference
               (url "https://go.googlesource.com/protobuf")
               (commit (go-version->git-ref version))))
        (file-name (git-file-name name version))
        (sha256
          (base32
            "02cpr8rqr5wmpj2fqb32mzilsdnxkh52g1jz95a3ck3gzffc7hh1"))))
    (build-system go-build-system)
    (arguments
      '(#:import-path "google.golang.org/protobuf"))
    (propagated-inputs
      `(("go-github-com-google-go-cmp-0.4.0"
         ,go-github-com-google-go-cmp-0.4.0)
        ("go-github-com-golang-protobuf-1.4.0"
         ,go-github-com-golang-protobuf-1.4.0)))
    (home-page "https://google.golang.org/protobuf")
    (synopsis "Go support for Protocol Buffers")
    (description
      "This project hosts the Go implementation for
@url{https://developers.google.com/protocol-buffers,protocol buffers}, which is a
language-neutral, platform-neutral, extensible mechanism for serializing
structured data.  The protocol buffer language is a language for specifying the
schema for structured data.  This schema is compiled into language specific
bindings.  This project provides both a tool to generate Go code for the
protocol buffer language, and also the runtime implementation to handle
serialization of messages in Go.  See the
@url{https://developers.google.com/protocol-buffers/docs/overview,protocol buffer developer guide}
for more information about protocol buffers themselves.")
    (license license:bsd-3)))

(define-public go-honnef-co-go-tools-0.0.0-20190523083050-ea95bdfd59fc
  (package
    (name "go-honnef-co-go-tools")
    (version "0.0.0-20190523083050-ea95bdfd59fc")
    (source
      (origin
        (method git-fetch)
        (uri (git-reference
               (url "https://github.com/dominikh/go-tools")
               (commit (go-version->git-ref version))))
        (file-name (git-file-name name version))
        (sha256
          (base32
            "1763nw7pwpzkvzfnm63dgzcgbq9hwmq5l1nffchnhh77vgkaq4ic"))))
    (build-system go-build-system)
    (arguments '(#:import-path "honnef.co/go/tools"))
    (home-page "https://honnef.co/go/tools")
    (synopsis "Documentation")
    (description
      "Staticcheck is a state of the art linter for the .  Using static analysis, it finds bugs and performance issues,
offers simplifications, and enforces style rules.")
    (license license:expat)))

(define-public go-google-golang-org-genproto-0.0.0-20200526211855-cb27e3aa2013
  (package
    (name "go-google-golang-org-genproto")
    (version "0.0.0-20200526211855-cb27e3aa2013")
    (source
      (origin
        (method git-fetch)
        (uri (git-reference
               (url "https://github.com/googleapis/go-genproto")
               (commit (go-version->git-ref version))))
        (file-name (git-file-name name version))
        (sha256
          (base32
            "0ml73ghqcwbz7ipfk8fnxb5indcml49b5p7vp1fsyny0abyyrmxf"))))
    (build-system go-build-system)
    (arguments
      '(#:import-path "google.golang.org/genproto"))
    (propagated-inputs
      `(("go-honnef-co-go-tools-0.0.0-20190523083050-ea95bdfd59fc"
         ,go-honnef-co-go-tools-0.0.0-20190523083050-ea95bdfd59fc)
        ("go-google-golang-org-protobuf-1.23.1-0.20200526195155-81db48ad09cc"
         ,go-google-golang-org-protobuf-1.23.1-0.20200526195155-81db48ad09cc)
        ("go-google-golang-org-grpc-1.27.0"
         ,go-google-golang-org-grpc-1.27.0)
        ("go-golang-org-x-tools-0.0.0-20190524140312-2c0ae7006135"
         ,go-golang-org-x-tools-0.0.0-20190524140312-2c0ae7006135)
        ("go-golang-org-x-lint-0.0.0-20190313153728-d0100b6bd8b3"
         ,go-golang-org-x-lint-0.0.0-20190313153728-d0100b6bd8b3)
        ("go-github-com-golang-protobuf-1.4.1"
         ,go-github-com-golang-protobuf-1.4.1)))
    (home-page "https://google.golang.org/genproto")
    (synopsis "Go generated proto packages")
    (description
      "This repository contains the generated Go packages for common protocol buffer
types, and the generated @url{http://grpc.io,gRPC} code necessary for interacting with Google's gRPC
APIs.")
    (license license:asl2.0)))

(define-public go-google-golang-org-protobuf-1.24.0
  (package
    (name "go-google-golang-org-protobuf")
    (version "1.24.0")
    (source
      (origin
        (method git-fetch)
        (uri (git-reference
               (url "https://go.googlesource.com/protobuf")
               (commit (string-append "v" version))))
        (file-name (git-file-name name version))
        (sha256
          (base32
            "0x3qyn3rizbs671gs7f8v50rmiwf9h7kbaradpivw9718mhbg1gn"))))
    (build-system go-build-system)
    (arguments
      '(#:import-path "google.golang.org/protobuf"))
    (propagated-inputs
      `(("go-google-golang-org-genproto-0.0.0-20200526211855-cb27e3aa2013"
         ,go-google-golang-org-genproto-0.0.0-20200526211855-cb27e3aa2013)
        ("go-github-com-google-go-cmp-0.4.0"
         ,go-github-com-google-go-cmp-0.4.0)
        ("go-github-com-golang-protobuf-1.4.1"
         ,go-github-com-golang-protobuf-1.4.1)))
    (home-page "https://google.golang.org/protobuf")
    (synopsis "Go support for Protocol Buffers")
    (description
      "This project hosts the Go implementation for
@url{https://developers.google.com/protocol-buffers,protocol buffers}, which is a
language-neutral, platform-neutral, extensible mechanism for serializing
structured data.  The protocol buffer language is a language for specifying the
schema for structured data.  This schema is compiled into language specific
bindings.  This project provides both a tool to generate Go code for the
protocol buffer language, and also the runtime implementation to handle
serialization of messages in Go.  See the
@url{https://developers.google.com/protocol-buffers/docs/overview,protocol buffer developer guide}
for more information about protocol buffers themselves.")
    (license license:bsd-3)))
--8<---------------cut here---------------end--------------->8---
    
Thank you,

Maxim Cournoyer (4):
  import: utils: Refactor maybe-inputs and add maybe-propagated-inputs.
  import: go: Improve synopsis and description parsing.
  import: go: Add an option to use pinned versions.
  import: go: Append version to symbol name in the pinned version mode.

 doc/guix.texi              |  14 +-
 guix/build-system/go.scm   |  24 +-
 guix/import/go.scm         | 454 +++++++++++++++++++++++--------------
 guix/import/utils.scm      |  47 ++--
 guix/scripts/import.scm    |   3 +-
 guix/scripts/import/go.scm |  75 +++---
 tests/go.scm               | 139 ++++++------
 7 files changed, 455 insertions(+), 301 deletions(-)

-- 
2.30.1





^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2021-04-24  3:31 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-03-22  4:10 [bug#47310] [PATCH 0/4] Improve parsing of synopsis and description, add pinned versions mode Maxim Cournoyer
2021-03-22  4:20 ` [bug#47310] [PATCH 1/4] import: utils: Refactor maybe-inputs and add maybe-propagated-inputs Maxim Cournoyer
2021-03-22  4:20   ` [bug#47310] [PATCH 2/4] import: go: Improve synopsis and description parsing Maxim Cournoyer
2021-03-22  4:20   ` [bug#47310] [PATCH 3/4] import: go: Add an option to use pinned versions Maxim Cournoyer
2021-04-10  3:13     ` bug#47310: " Maxim Cournoyer
2021-03-22  4:20   ` [bug#47310] [PATCH 4/4] import: go: Append version to symbol name in the pinned version mode Maxim Cournoyer
2021-04-10 20:54 ` [bug#47310] [PATCH 0/4] go importer: Better synopsis and descriptions, pinned versions mode Ludovic Courtès
2021-04-11  0:57   ` Maxim Cournoyer
     [not found] ` <20210414120939.mmvprjaz6636kz4h@noop.avalenn.eu>
     [not found]   ` <87czusjtpc.fsf@gmail.com>
2021-04-18 10:31     ` go-build-system possible improvments François
2021-04-21  2:00       ` Maxim Cournoyer
2021-04-22 16:36         ` François
2021-04-24  3:30           ` Maxim Cournoyer

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.