nixpkgs/pkgs/tools/networking/gping/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

48 lines
1 KiB
Nix
Raw Normal View History

{ lib
2021-05-15 23:01:12 +02:00
, stdenv
2020-11-14 04:01:32 +01:00
, rustPlatform
, fetchFromGitHub
2023-08-01 23:25:46 +02:00
, installShellFiles
2021-05-15 23:01:12 +02:00
, libiconv
2022-02-07 09:56:32 +01:00
, Security
2023-07-01 15:39:58 +02:00
, iputils
}:
2020-11-14 04:01:32 +01:00
rustPlatform.buildRustPackage rec {
pname = "gping";
version = "1.16.1";
2020-11-14 04:01:32 +01:00
src = fetchFromGitHub {
owner = "orf";
repo = "gping";
rev = "gping-v${version}";
hash = "sha256-hCqjbJt0dHuvFsWEF/WgLEPY2xws71wFGdhzThYOOvA=";
};
cargoHash = "sha256-3jpQ8ANg9WYK1Q5Hph6fK442e5f9dsLQbTMBEwTaENc=";
2022-02-07 09:56:32 +01:00
buildInputs = lib.optionals stdenv.isDarwin [ libiconv Security ];
2021-05-15 23:01:12 +02:00
2023-08-01 23:25:46 +02:00
nativeBuildInputs = [ installShellFiles ];
nativeCheckInputs = lib.optionals stdenv.isLinux [ iputils ];
2023-07-01 15:39:58 +02:00
2023-08-01 23:25:46 +02:00
postInstall = ''
installManPage gping.1
'';
2022-02-07 09:57:12 +01:00
doInstallCheck = true;
installCheckPhase = ''
$out/bin/gping --version | grep "${version}"
'';
meta = with lib; {
description = "Ping, but with a graph";
homepage = "https://github.com/orf/gping";
2023-07-01 15:39:58 +02:00
changelog = "https://github.com/orf/gping/releases/tag/gping-v${version}";
2020-11-14 04:01:32 +01:00
license = licenses.mit;
maintainers = with maintainers; [ cafkafk ];
2024-02-11 03:19:15 +01:00
mainProgram = "gping";
};
}