2021-01-28 17:17:09 +01:00
|
|
|
{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles, Security }:
|
2019-05-08 19:01:20 +02:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "procs";
|
2021-02-03 22:00:41 +01:00
|
|
|
version = "0.11.3";
|
2019-05-08 19:01:20 +02:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "dalance";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-02-03 22:00:41 +01:00
|
|
|
sha256 = "sha256-OaHsNxrOrPlAwtFDY3Tnx+nOabax98xcGQeNds32iOA=";
|
2019-05-08 19:01:20 +02:00
|
|
|
};
|
|
|
|
|
2021-02-03 22:00:41 +01:00
|
|
|
cargoSha256 = "sha256-miOfm1Sw6tIICkT9T2V82cdGG2STo9vuLPWsAN/8wuM=";
|
2019-05-08 19:01:20 +02:00
|
|
|
|
2021-01-28 17:17:09 +01:00
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
for shell in bash fish zsh; do
|
|
|
|
$out/bin/procs --completion $shell > procs.$shell
|
|
|
|
installShellCompletion procs.$shell
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2021-01-15 10:19:50 +01:00
|
|
|
buildInputs = lib.optional stdenv.isDarwin Security;
|
2019-05-08 19:01:20 +02:00
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2019-05-08 19:01:20 +02:00
|
|
|
description = "A modern replacement for ps written in Rust";
|
|
|
|
homepage = "https://github.com/dalance/procs";
|
2020-02-18 02:23:19 +01:00
|
|
|
license = licenses.mit;
|
2020-11-17 12:02:06 +01:00
|
|
|
maintainers = with maintainers; [ dalance Br1ght0ne ];
|
2019-05-08 19:01:20 +02:00
|
|
|
platforms = with platforms; linux ++ darwin;
|
|
|
|
};
|
|
|
|
}
|