guix_mirror_bot pushed a commit to branch master
in repository guix.

commit ce9d4061ea24a388b8598e47bd1ce22f5950d865
Author: Danny Milosavljevic <[email protected]>
AuthorDate: Fri Dec 5 19:37:36 2025 +0100

    gnu: Add go-github-com-google-go-containerregistry.
    
    * gnu/packages/golang-web.scm (go-github-com-google-go-containerregistry): 
New variable.
    
    Change-Id: I495faa4a82138221d7a84ab06c8e47bbccfd482f
    Modified-by: Sharlatan Hellseher <[email protected]>
    Signed-off-by: Sharlatan Hellseher <[email protected]>
---
 gnu/packages/golang-web.scm | 64 +++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 64 insertions(+)

diff --git a/gnu/packages/golang-web.scm b/gnu/packages/golang-web.scm
index f12271257b..8b87b1f0e6 100644
--- a/gnu/packages/golang-web.scm
+++ b/gnu/packages/golang-web.scm
@@ -5899,6 +5899,70 @@ replacement for memcached in many cases.  It provides a 
data loading mechanism
 with caching and de-duplication that works across a set of peer processes.")
     (license license:asl2.0)))
 
+(define-public go-github-com-google-go-containerregistry
+  (package
+    (name "go-github-com-google-go-containerregistry")
+    (version "0.20.2")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+              (url "https://github.com/google/go-containerregistry";)
+              (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "0gmbvpcbp6n9hx8dpggbxl7540b6vq3p0rm5a6lsjj2gw62p7zp5"))
+       (modules '((guix build utils)))
+       (snippet
+        #~(begin
+            ;; Submodules with their own go.mod files and packed as separated
+            ;; packages:
+            ;;
+            ;; - github.com/google/go-containerregistry/cmd/krane
+            ;; - github.com/google/go-containerregistry/pkg/authn/k8schain
+            ;; - github.com/google/go-containerregistry/pkg/authn/kubernetes
+            (for-each delete-file-recursively
+                      (list "cmd/krane"
+                            "pkg/authn/k8schain"
+                            "pkg/authn/kubernetes"))
+            (delete-file-recursively "vendor")))))
+    (build-system go-build-system)
+    (arguments
+     (list
+      #:skip-build? #t
+      #:import-path "github.com/google/go-containerregistry"
+      #:test-flags
+      #~(list "-vet=off"
+              "-skip" (string-join
+                       (list "TestGcloudErrors"
+                             "TestGcloudSuccess"
+                             "TestKeychainGCRandAR")
+                       "|"))))
+    (native-inputs
+     ;; For the CLI commands.
+     (list go-github-com-spf13-cobra
+           go-github-com-google-go-cmp))
+    (propagated-inputs
+     (list go-github-com-containerd-stargz-snapshotter-estargz
+           go-github-com-docker-cli
+           go-github-com-docker-distribution
+           go-github-com-docker-docker
+           go-github-com-klauspost-compress
+           go-github-com-mitchellh-go-homedir
+           go-github-com-opencontainers-go-digest
+           go-github-com-opencontainers-image-spec
+           go-golang-org-x-oauth2
+           go-golang-org-x-sync
+           go-golang-org-x-tools))
+    (home-page "https://github.com/google/go-containerregistry";)
+    (synopsis "Go library and tools for working with container registries")
+    (description
+     "This package provides a Go library for interacting with container
+registries.  It includes tools like @code{crane} for interacting with remote
+images and registries, @code{gcrane} for GCR-specific operations, and
+libraries for building and manipulating container images.")
+    (license license:asl2.0)))
+
 (define-public go-github-com-google-go-dap
   (package
     (name "go-github-com-google-go-dap")

Reply via email to