2024-05-21 13:11:50 +02:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
|
|
|
, installShellFiles
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "gosmee";
|
2024-06-20 07:48:32 +02:00
|
|
|
version = "0.22.1";
|
2024-05-21 13:11:50 +02:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "chmouel";
|
|
|
|
repo = "gosmee";
|
|
|
|
rev = "v${version}";
|
2024-09-14 23:47:11 +02:00
|
|
|
hash = "sha256-UnGzPkbw7x8l1+9xEXFiJZFzJT5yu7MCgPKkKzaFqkk=";
|
2024-05-21 13:11:50 +02:00
|
|
|
};
|
|
|
|
vendorHash = null;
|
|
|
|
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
printf ${version} > gosmee/templates/version
|
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installShellCompletion --cmd gosmee \
|
|
|
|
--bash <($out/bin/gosmee completion bash) \
|
|
|
|
--fish <($out/bin/gosmee completion fish) \
|
|
|
|
--zsh <($out/bin/gosmee completion zsh)
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Command line server and client for webhooks deliveries (and https://smee.io)";
|
|
|
|
homepage = "https://github.com/chmouel/gosmee";
|
|
|
|
license = lib.licenses.asl20;
|
|
|
|
maintainers = with lib.maintainers; [ vdemeester chmouel ];
|
|
|
|
};
|
|
|
|
}
|