nix-top: 0.1.0 -> 0.2.0

This commit is contained in:
Samuel Dionne-Riel 2018-07-29 22:09:02 -04:00
parent 92eedad50b
commit e1dc63b41b

View File

@ -3,25 +3,27 @@
, fetchFromGitHub
, ruby
, makeWrapper
, procps # ps
, getent # /etc/passwd
, ncurses # tput
, procps # ps
, binutils-unwrapped # strings
, coreutils
, findutils
}:
# No gems used, so mkDerivation is fine.
let
additionalPath = lib.makeBinPath [ncurses procps binutils-unwrapped findutils];
additionalPath = lib.makeBinPath [ getent ncurses binutils-unwrapped coreutils findutils ];
in
stdenv.mkDerivation rec {
name = "nix-top-${version}";
version = "0.1.0";
version = "0.2.0";
src = fetchFromGitHub {
owner = "samueldr";
repo = "nix-top";
rev = "v${version}";
sha256 = "0l50w90hs3kmdk5kb3cwjzkx38104j6n4ssqs6jpnqfc2znagpni";
sha256 = "0560a9g8n4p764r3va1nn95iv4bg71g8h0wws1af2p5g553j4zps";
};
nativeBuildInputs = [
@ -33,10 +35,13 @@ stdenv.mkDerivation rec {
];
installPhase = ''
mkdir -p $out/bin/
mkdir -p $out/bin $out/libexec/nix-top
cp ./nix-top $out/bin/nix-top
chmod +x $out/bin/nix-top
wrapProgram $out/bin/nix-top \
--prefix PATH : "${additionalPath}"
--prefix PATH : "$out/libexec/nix-top:${additionalPath}"
'' + stdenv.lib.optionalString stdenv.isDarwin ''
ln -s /bin/stty $out/libexec/nix-top
'';
meta = with lib; {
@ -44,7 +49,7 @@ stdenv.mkDerivation rec {
homepage = https://github.com/samueldr/nix-top;
license = licenses.mit;
maintainers = with maintainers; [ samueldr ];
platforms = platforms.linux;
platforms = platforms.linux ++ platforms.darwin;
inherit version;
};
}