3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/misc/wtf/default.nix
2020-05-29 16:05:13 +02:00

40 lines
919 B
Nix

{ buildGoModule
, fetchFromGitHub
, lib
, makeWrapper
, ncurses
}:
buildGoModule rec {
pname = "wtf";
version = "0.30.0";
src = fetchFromGitHub {
owner = "wtfutil";
repo = pname;
rev = "v${version}";
sha256 = "11vy39zygk1gxb1nc1zmxlgs6fn7yq68090fwm2jar0lsxx8a83i";
};
vendorSha256 = "0qfb352gmsmy5glrsjwc3w57di5k2kjdsyfqn4xf7p4v12yg88va";
buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version}" ];
subPackages = [ "." ];
nativeBuildInputs = [ makeWrapper ];
postInstall = ''
mv "$out/bin/wtf" "$out/bin/wtfutil"
wrapProgram "$out/bin/wtfutil" --prefix PATH : "${ncurses.dev}/bin"
'';
meta = with lib; {
description = "The personal information dashboard for your terminal";
homepage = "https://wtfutil.com/";
license = licenses.mpl20;
maintainers = with maintainers; [ kalbasit ];
platforms = platforms.linux ++ platforms.darwin;
};
}