2019-08-16 01:45:22 +01:00
|
|
|
{ buildGoModule
|
2018-11-20 22:13:22 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, lib
|
|
|
|
}:
|
|
|
|
|
2019-08-16 01:45:22 +01:00
|
|
|
buildGoModule rec {
|
2019-05-26 17:23:10 +01:00
|
|
|
pname = "wtf";
|
2019-08-28 06:00:00 +01:00
|
|
|
version = "0.20.0";
|
2018-11-20 22:13:22 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2019-05-26 17:23:10 +01:00
|
|
|
owner = "wtfutil";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2019-08-28 06:00:00 +01:00
|
|
|
sha256 = "03k3x3fnxz23b75n5x8mlr6srr063q3dwq05wh55b4bgqsf7lgzd";
|
2018-11-20 22:13:22 +00:00
|
|
|
};
|
|
|
|
|
2019-08-28 06:00:00 +01:00
|
|
|
modSha256 = "1nqnjpkrjbb75yfbzh3v3vc4xy5a2aqm9jr40hwq589a4l9p5pw2";
|
|
|
|
|
|
|
|
buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version}" ];
|
2019-08-16 01:45:22 +01:00
|
|
|
|
|
|
|
# As per https://github.com/wtfutil/wtf/issues/501, one of the
|
|
|
|
# dependencies can't be fetched, so vendored dependencies should
|
|
|
|
# be used instead
|
|
|
|
modBuildPhase = ''
|
|
|
|
runHook preBuild
|
|
|
|
make build -mod=vendor
|
|
|
|
runHook postBuild
|
|
|
|
'';
|
2018-11-20 22:13:22 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "The personal information dashboard for your terminal";
|
2019-07-16 03:49:38 +01:00
|
|
|
homepage = "https://wtfutil.com/";
|
2018-11-20 22:13:22 +00:00
|
|
|
license = licenses.mpl20;
|
|
|
|
maintainers = with maintainers; [ kalbasit ];
|
|
|
|
platforms = platforms.linux ++ platforms.darwin;
|
|
|
|
};
|
|
|
|
}
|