From d0d0c1a2ed4a7445edb86b00f1deae6831fe81c8 Mon Sep 17 00:00:00 2001 From: genga Date: Sat, 25 Jan 2025 15:39:23 +0300 Subject: [PATCH] bento: init at 1.4.1 bento: mark darwin as broken bento: update to use versionCheckHook bento: update --- pkgs/by-name/be/bento/package.nix | 52 +++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 pkgs/by-name/be/bento/package.nix diff --git a/pkgs/by-name/be/bento/package.nix b/pkgs/by-name/be/bento/package.nix new file mode 100644 index 000000000000..9d2f51a3be7b --- /dev/null +++ b/pkgs/by-name/be/bento/package.nix @@ -0,0 +1,52 @@ +{ + lib, + fetchFromGitHub, + buildGoModule, + versionCheckHook, + nix-update-script, +}: + +buildGoModule rec { + pname = "bento"; + version = "1.4.1"; + + src = fetchFromGitHub { + owner = "warpstreamlabs"; + repo = "bento"; + tag = "v${version}"; + hash = "sha256-ukmmmvc5CWctDO+YaW/PiqWizfXtgbcMlIK6PjhxMm4="; + }; + + vendorHash = "sha256-G67i4tZoevlrj+LhjCoHReoWkIZUQVt4YBavmj+h2OI="; + + subPackages = [ + "cmd/bento" + "cmd/serverless/bento-lambda" + ]; + + ldflags = [ + "-s" + "-w" + "-X github.com/warpstreamlabs/bento/internal/cli.Version=${version}" + "-X main.Version=${version}" + ]; + + nativeInstallCheckInputs = [ versionCheckHook ]; + versionCheckProgramArg = [ "--version" ]; + doInstallCheck = true; + + passthru.updateScript = nix-update-script { }; + + meta = { + description = "High performance and resilient stream processor"; + homepage = "https://warpstreamlabs.github.io/bento/"; + changelog = "https://github.com/warpstreamlabs/bento/releases/tag/v${version}"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ genga898 ]; + mainProgram = "bento"; + badPlatforms = [ + # cannot find module providing package github.com/microsoft/gocosmos + lib.systems.inspect.patterns.isDarwin + ]; + }; +}