nixpkgs/pkgs/tools/admin/procs/default.nix

35 lines
968 B
Nix
Raw Normal View History

2021-03-25 08:39:32 +00:00
{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles, Security, libiconv }:
2019-05-08 17:01:20 +00:00
rustPlatform.buildRustPackage rec {
pname = "procs";
2021-03-13 11:20:57 +00:00
version = "0.11.4";
2019-05-08 17:01:20 +00:00
src = fetchFromGitHub {
owner = "dalance";
repo = pname;
rev = "v${version}";
2021-03-13 11:20:57 +00:00
sha256 = "sha256-jqcI0ne6fZkgr4bWJ0ysVNvB7q9ErYbsmZoXI38XUng=";
2019-05-08 17:01:20 +00:00
};
2021-03-13 11:20:57 +00:00
cargoSha256 = "sha256-0s5MeWX+rXTyftwg6sReNMRgBzhUMIdHu5buKwg1Yi4=";
2019-05-08 17:01:20 +00:00
2021-01-28 16:17:09 +00:00
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
for shell in bash fish zsh; do
$out/bin/procs --completion $shell > procs.$shell
installShellCompletion procs.$shell
done
'';
2021-03-25 08:39:32 +00:00
buildInputs = lib.optionals stdenv.isDarwin [ Security libiconv ];
2019-05-08 17:01:20 +00:00
meta = with lib; {
2019-05-08 17:01:20 +00:00
description = "A modern replacement for ps written in Rust";
homepage = "https://github.com/dalance/procs";
2020-02-18 01:23:19 +00:00
license = licenses.mit;
maintainers = with maintainers; [ dalance Br1ght0ne ];
2019-05-08 17:01:20 +00:00
platforms = with platforms; linux ++ darwin;
};
}