about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/security/ssh-to-pgp/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/tools/security/ssh-to-pgp/default.nix')
-rw-r--r--nixpkgs/pkgs/tools/security/ssh-to-pgp/default.nix29
1 files changed, 29 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/tools/security/ssh-to-pgp/default.nix b/nixpkgs/pkgs/tools/security/ssh-to-pgp/default.nix
new file mode 100644
index 000000000000..487cc44cdd73
--- /dev/null
+++ b/nixpkgs/pkgs/tools/security/ssh-to-pgp/default.nix
@@ -0,0 +1,29 @@
+{ lib, fetchFromGitHub, buildGoModule, gnupg }:
+
+buildGoModule rec {
+  pname = "ssh-to-pgp";
+  version = "1.0.0";
+
+  src = fetchFromGitHub {
+    owner = "Mic92";
+    repo = "ssh-to-pgp";
+    rev = version;
+    sha256 = "sha256-TDrpnWAez8muysMdmKFBDZfK8CyhGn1VqHB8+zD6jSk=";
+  };
+
+  vendorSha256 = "sha256-ZF/WsmqmGHZIAGTPKJ70UhtmssNhiInEZfzrKxQLw9I=";
+
+  checkInputs = [ gnupg ];
+  checkPhase = ''
+    HOME=$TMPDIR go test .
+  '';
+
+  doCheck = true;
+
+  meta = with lib; {
+    description = "Convert ssh private keys to PGP";
+    homepage = "https://github.com/Mic92/ssh-to-pgp";
+    license = licenses.mit;
+    maintainers = with maintainers; [ mic92 ];
+  };
+}