depot/third_party/nixpkgs/pkgs/by-name/op/optinix/package.nix
Default email 159e378cbb Project import generated by Copybara.
GitOrigin-RevId: c04d5652cfa9742b1d519688f65d1bbccea9eb7e
2024-09-19 17:19:46 +03:00

36 lines
884 B
Nix

{
lib,
fetchFromGitLab,
buildGoModule,
installShellFiles,
}:
buildGoModule rec {
pname = "optinix";
version = "0.1.3";
src = fetchFromGitLab {
owner = "hmajid2301";
repo = "optinix";
rev = "v${version}";
hash = "sha256-Y+TCMKLLBcpGgbQbwt/F9PhcDoG9B156hHM9teD+vFA=";
};
vendorHash = "sha256-kwAmp3pP2oEETztJ28fW1H6cMp0mCBiunVy41I8aeEk=";
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd optinix \
--bash <($out/bin/optinix completion bash) \
--fish <($out/bin/optinix completion fish) \
--zsh <($out/bin/optinix completion zsh)
'';
meta = {
description = "Tool for searching options in Nix";
homepage = "https://gitlab.com/hmajid2301/optinix";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ hmajid2301 ];
mainProgram = "optinix";
};
}