2020-11-30 08:33:03 +00:00
|
|
|
{ stdenv, fetchFromGitHub, rustPlatform, darwin, installShellFiles }:
|
2020-10-07 09:15:18 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "bottom";
|
2020-11-30 08:33:03 +00:00
|
|
|
version = "0.5.3";
|
2020-10-07 09:15:18 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ClementTsang";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2020-11-30 08:33:03 +00:00
|
|
|
sha256 = "sha256-Gc2bL7KqDqab0hCCOi2rtEw+5r0bSETzTipLLdX/ipk=";
|
2020-10-07 09:15:18 +00:00
|
|
|
};
|
|
|
|
|
2020-11-30 08:33:03 +00:00
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
2020-10-07 09:15:18 +00:00
|
|
|
buildInputs = stdenv.lib.optional stdenv.hostPlatform.isDarwin darwin.apple_sdk.frameworks.IOKit;
|
|
|
|
|
2020-11-30 08:33:03 +00:00
|
|
|
cargoSha256 = "sha256-Bdkq3cTuziTQ7/BkvuBHbfuxRIXnz4h2OadoAGNTBc0=";
|
2020-10-07 09:15:18 +00:00
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
|
2020-11-30 08:33:03 +00:00
|
|
|
postInstall = ''
|
|
|
|
installShellCompletion $releaseDir/build/bottom-*/out/btm.{bash,fish} --zsh $releaseDir/build/bottom-*/out/_btm
|
|
|
|
'';
|
|
|
|
|
2020-10-07 09:15:18 +00:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A cross-platform graphical process/system monitor with a customizable interface";
|
|
|
|
homepage = "https://github.com/ClementTsang/bottom";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ berbiche ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|