mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 21:50:55 +00:00
bpytop: init at 1.0.0
This commit is contained in:
parent
64a8d0115b
commit
616962ffd9
45
pkgs/tools/system/bpytop/default.nix
Normal file
45
pkgs/tools/system/bpytop/default.nix
Normal file
|
@ -0,0 +1,45 @@
|
|||
{ stdenv, python3Packages, fetchFromGitHub, makeWrapper, substituteAll }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "bpytop";
|
||||
version = "1.0.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "aristocratos";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "0cxyrk5a9j0ymll9h5b6jq48yjy9srcxh4rmsqk8w0d14prmflgg";
|
||||
};
|
||||
|
||||
buildInputs = [ makeWrapper ];
|
||||
propagatedBuildInputs = with python3Packages; [ python psutil ];
|
||||
|
||||
dontBuild = true;
|
||||
|
||||
postPatch = ''
|
||||
sed -i -e "s#/usr/\[local/\]#$out/#g" \
|
||||
-e "s#/usr/{td}#$out/#g" \
|
||||
./bpytop.py
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/{bin,libexec,share/bpytop}/
|
||||
cp -r ./themes $out/share/bpytop/
|
||||
cp ./bpytop.py $out/libexec/
|
||||
|
||||
makeWrapper ${python3Packages.python.interpreter} $out/bin/bpytop \
|
||||
--add-flags "$out/libexec/bpytop.py" \
|
||||
--prefix PYTHONPATH : "$PYTHONPATH"
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "A resource monitor; python port of bashtop";
|
||||
homepage = src.meta.homepage;
|
||||
license = licenses.apsl20;
|
||||
maintainers = with maintainers; [ aw ];
|
||||
platforms = with platforms; linux ++ freebsd ++ darwin;
|
||||
|
||||
# https://github.com/NixOS/nixpkgs/pull/94625#issuecomment-668509399
|
||||
broken = stdenv.isDarwin;
|
||||
};
|
||||
}
|
|
@ -1369,6 +1369,8 @@ in
|
|||
|
||||
boxfs = callPackage ../tools/filesystems/boxfs { };
|
||||
|
||||
bpytop = callPackage ../tools/system/bpytop { };
|
||||
|
||||
brasero-original = lowPrio (callPackage ../tools/cd-dvd/brasero { });
|
||||
|
||||
brasero = callPackage ../tools/cd-dvd/brasero/wrapper.nix { };
|
||||
|
|
Loading…
Reference in a new issue