Subject: [PATCH v2] gnu: Add ssh-to-pgp.

From: Dale Mellor <[email-masked]>
Date: Sun, 21 Apr 2024 03:43:02 +0100

From: Giacomo Leidi <[email-masked]>

* gnu/packages/crypto.scm (ssh-to-pgp): New variable.

Review:
  * License is MIT declared as expat, fine
  * Standard declaration for a Go package
  * guix lint, build --check, build --source --check, all run clean
  * I had a very cursory look over the upstream source, nothing nasty
      jumps out
  * It works for me

Reviewed-by: Dale Mellor <[email-masked]>
Change-Id: Ic8e55ede6b19d9a90291e3ac2cf608e8a59bc061
---
 gnu/packages/crypto.scm | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm
index 2491abcce1..9c62689d18 100644
--- a/gnu/packages/crypto.scm
+++ b/gnu/packages/crypto.scm
@@ -1674,6 +1674,33 @@ (define-public libxcrypt
     (home-page "https://github.com/besser82/libxcrypt")
     (license license:lgpl2.1)))
 
+(define-public ssh-to-pgp
+  (package
+    (name "ssh-to-pgp")
+    (version "1.1.2")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/Mic92/ssh-to-pgp")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "1mph8mm80qzrsd07v7drfrhdah9n9ibsqfcf9kbffi1pw83cm0aa"))))
+    (build-system go-build-system)
+    (arguments
+     '(#:import-path "github.com/Mic92/ssh-to-pgp"))
+    (native-inputs
+     (list gnupg))
+    (propagated-inputs
+     (list go-golang-org-x-sys
+           go-golang-org-x-crypto))
+    (home-page "https://github.com/Mic92/ssh-to-pgp")
+    (synopsis "Convert SSH RSA keys to GPG keys")
+    (description "This package provides @code{ssh-to-pgp}: a Go command line
++utility to convert SSH RSA keys to GPG keys.")
+    (license license:expat)))
+
 (define-public keychain
   (package
     (name "keychain")
-- 
2.41.0