From d6aa244edf624e998ef76952eb34cd2510e0e183 Mon Sep 17 00:00:00 2001 From: Anthony ROUSSEL Date: Tue, 12 Nov 2024 18:27:08 +0100 Subject: [PATCH] okms-cli: init at 0.1.2 https://github.com/ovh/okms-cli --- pkgs/by-name/ok/okms-cli/package.nix | 47 ++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 +++ 2 files changed, 51 insertions(+) create mode 100644 pkgs/by-name/ok/okms-cli/package.nix diff --git a/pkgs/by-name/ok/okms-cli/package.nix b/pkgs/by-name/ok/okms-cli/package.nix new file mode 100644 index 0000000000000..8d452fe492295 --- /dev/null +++ b/pkgs/by-name/ok/okms-cli/package.nix @@ -0,0 +1,47 @@ +{ + lib, + buildGoModule, + fetchFromGitHub, + nix-update-script, + okms-cli, + testers, +}: + +buildGoModule rec { + pname = "okms-cli"; + version = "0.1.2"; + + src = fetchFromGitHub { + owner = "ovh"; + repo = "okms-cli"; + rev = "refs/tags/v${version}"; + hash = "sha256-We1Aq9dOzEa7M6tG8kiVGfWhXfkpdZaJsJ5MCM/HZL4="; + }; + + vendorHash = "sha256-DyIqsvqTi6Yq8MADty/iSiDLgdd2vP/IDyCOm0yaQzk="; + + ldflags = [ + "-s" + "-w" + "-X main.version=${version}" + "-X main.commit=${src.rev}" + "-X main.date=unknown" + ]; + + passthru = { + tests.version = testers.testVersion { + package = okms-cli; + command = "okms version"; + }; + updateScript = nix-update-script { }; + }; + + meta = { + homepage = "https://github.com/ovh/okms-cli"; + changelog = "https://github.com/ovh/okms-cli/releases/tag/v${version}"; + description = "Command Line Interface to interact with your OVHcloud KMS services"; + mainProgram = "okms"; + license = lib.licenses.asl20; + maintainers = [ lib.maintainers.anthonyroussel ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index f18340107d604..603781a92f642 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -15410,6 +15410,10 @@ with pkgs; obs-studio-plugins = recurseIntoAttrs (callPackage ../applications/video/obs-studio/plugins {}); wrapOBS = callPackage ../applications/video/obs-studio/wrapper.nix { }; + okms-cli = callPackage ../by-name/ok/okms-cli/package.nix { + buildGoModule = buildGo123Module; + }; + omegat = callPackage ../applications/misc/omegat.nix { }; inherit (callPackage ../applications/networking/onionshare { }) onionshare onionshare-gui;