From 46a0f9f9004b216c225a1ec58fb22d5fa5f90469 Mon Sep 17 00:00:00 2001 From: Nicolas Goudry Date: Tue, 1 Apr 2025 17:43:24 +0200 Subject: [PATCH] sou: init at 0.2.0 --- pkgs/by-name/so/sou/package.nix | 44 +++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 pkgs/by-name/so/sou/package.nix diff --git a/pkgs/by-name/so/sou/package.nix b/pkgs/by-name/so/sou/package.nix new file mode 100644 index 000000000000..0ee536e93a07 --- /dev/null +++ b/pkgs/by-name/so/sou/package.nix @@ -0,0 +1,44 @@ +{ + lib, + buildGoModule, + fetchFromGitHub, + nix-update-script, + versionCheckHook, +}: + +buildGoModule (finalAttrs: { + pname = "sou"; + version = "0.2.0"; + + src = fetchFromGitHub { + owner = "knqyf263"; + repo = "sou"; + tag = "v${finalAttrs.version}"; + hash = "sha256-uGYCmW60OvEfserujQMXC9r8S8W+EN+w9EXUGjk1vtw="; + }; + + vendorHash = "sha256-6kgiZx/g1PA7R50z7noG+ql+S9wSgTuVTkY5DIqeJHY="; + + ldflags = [ + "-s" + "-w" + "-X=main.version=${finalAttrs.version}" + ]; + + doInstallCheck = true; + nativeInstallCheck = [ versionCheckHook ]; + + # Some of the tests use localhost networking + __darwinAllowLocalNetworking = true; + + passthru.updateScript = nix-update-script { }; + + meta = { + description = "Tool for exploring files in container image layers"; + homepage = "https://github.com/knqyf263/sou"; + changelog = "https://github.com/knqyf263/sou/releases/tag/v${finalAttrs.version}"; + license = lib.licenses.asl20; + maintainers = with lib.maintainers; [ nicolas-goudry ]; + mainProgram = "sou"; + }; +})