2022-12-24 23:17:20 +00:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
|
|
|
, unstableGitUpdater
|
|
|
|
}:
|
2018-01-21 22:31:51 +00:00
|
|
|
|
2022-12-24 23:17:20 +00:00
|
|
|
buildGoModule rec {
|
|
|
|
pname = "tewisay";
|
2024-03-03 17:51:10 +00:00
|
|
|
version = "0-unstable-2022-11-04";
|
2018-01-21 22:31:51 +00:00
|
|
|
|
2022-12-24 23:17:20 +00:00
|
|
|
# lucy deleted the old repo, this is a fork/mirror
|
2018-01-21 22:31:51 +00:00
|
|
|
src = fetchFromGitHub {
|
2022-12-24 23:17:20 +00:00
|
|
|
owner = "raymond-w-ko";
|
2018-01-21 22:31:51 +00:00
|
|
|
repo = "tewisay";
|
2022-12-24 23:17:20 +00:00
|
|
|
rev = "caa5b0131dda868f656716d2107f02d04d1048d4";
|
|
|
|
hash = "sha256-E492d8P/Bek9xZlJP+k9xvIJEFtA1YrIB/pogvz3wM4=";
|
2018-01-21 22:31:51 +00:00
|
|
|
};
|
|
|
|
|
2022-12-24 23:17:20 +00:00
|
|
|
vendorHash = "sha256-WcpRJ31kqWA255zfjuWDj0honJgSGdm4ONx2yOKk7/g=";
|
2018-01-21 22:31:51 +00:00
|
|
|
|
2022-12-24 23:17:20 +00:00
|
|
|
# Currently hard-coded, will be fixed by developer
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace main.go \
|
|
|
|
--replace "/usr" "$out"
|
|
|
|
'';
|
2018-01-21 22:31:51 +00:00
|
|
|
|
|
|
|
postInstall = ''
|
2022-12-24 23:17:20 +00:00
|
|
|
mkdir -p $out/share
|
|
|
|
mv {cows,zsh} $out/share
|
2018-01-21 22:31:51 +00:00
|
|
|
'';
|
|
|
|
|
2022-12-24 23:17:20 +00:00
|
|
|
passthru.updateScript = unstableGitUpdater { };
|
2018-01-21 22:31:51 +00:00
|
|
|
|
2022-04-17 23:13:36 +00:00
|
|
|
meta = with lib; {
|
2022-12-24 23:17:20 +00:00
|
|
|
homepage = "https://github.com/raymond-w-ko/tewisay";
|
2018-01-21 22:31:51 +00:00
|
|
|
description = "Cowsay replacement with unicode and partial ansi escape support";
|
2022-12-24 23:17:20 +00:00
|
|
|
license = with licenses; [ cc0 ];
|
2022-04-17 23:13:36 +00:00
|
|
|
maintainers = with maintainers; [ Madouura ];
|
2023-11-27 01:17:53 +00:00
|
|
|
mainProgram = "tewisay";
|
2018-01-21 22:31:51 +00:00
|
|
|
};
|
|
|
|
}
|