2023-04-29 16:46:19 +00:00
|
|
|
{ lib, fetchFromGitHub, buildGoModule, installShellFiles }:
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "nali";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "0.7.3";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "zu1k";
|
|
|
|
repo = "nali";
|
|
|
|
rev = "v${version}";
|
2023-05-24 13:37:59 +00:00
|
|
|
sha256 = "sha256-ZKLxsq7ybom96NKWkioROAVXUoY20zFBZn7ksk4XvT4=";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
2023-04-29 16:46:19 +00:00
|
|
|
vendorHash = "sha256-l3Fs1Hd0kXI56uotic1407tb4ltkCSMzqqozFpvobH8=";
|
2021-12-06 16:07:01 +00:00
|
|
|
subPackages = [ "." ];
|
|
|
|
|
2023-04-29 16:46:19 +00:00
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installShellCompletion --cmd nali \
|
|
|
|
--bash <($out/bin/nali completion bash) \
|
|
|
|
--fish <($out/bin/nali completion fish) \
|
|
|
|
--zsh <($out/bin/nali completion zsh)
|
|
|
|
'';
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "An offline tool for querying IP geographic information and CDN provider";
|
|
|
|
homepage = "https://github.com/zu1k/nali";
|
|
|
|
license = licenses.mit;
|
2022-06-26 10:26:21 +00:00
|
|
|
maintainers = with maintainers; [ diffumist xyenon ];
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
}
|