depot/third_party/nixpkgs/pkgs/tools/networking/oha/default.nix
Default email 9c6ee729d6 Project import generated by Copybara.
GitOrigin-RevId: 6cee3b5893090b0f5f0a06b4cf42ca4e60e5d222
2023-07-15 19:15:38 +02:00

43 lines
997 B
Nix

{ lib
, rustPlatform
, fetchFromGitHub
, stdenv
, pkg-config
, openssl
, darwin
}:
rustPlatform.buildRustPackage rec {
pname = "oha";
version = "0.6.1";
src = fetchFromGitHub {
owner = "hatoo";
repo = pname;
rev = "refs/tags/v${version}";
sha256 = "sha256-TwaGF/ER1VSaDwapm+0f29i7siqFh/njYqwlQIO5yio=";
};
cargoSha256 = "sha256-PLOc+bQN4/mjb6Rh0b6Wl/iL1Xys2WXNBNK42Rp4ilQ=";
nativeBuildInputs = lib.optionals stdenv.isLinux [
pkg-config
];
buildInputs = lib.optionals stdenv.isLinux [
openssl
] ++ lib.optionals stdenv.isDarwin [
darwin.apple_sdk.frameworks.Security
];
# tests don't work inside the sandbox
doCheck = false;
meta = with lib; {
description = "HTTP load generator inspired by rakyll/hey with tui animation";
homepage = "https://github.com/hatoo/oha";
changelog = "https://github.com/hatoo/oha/blob/v${version}/CHANGELOG.md";
license = licenses.mit;
maintainers = with maintainers; [ figsoda ];
};
}