3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/tools/yq-go/default.nix
2020-11-12 12:22:08 +00:00

34 lines
808 B
Nix

{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
buildGoModule rec {
pname = "yq-go";
version = "3.4.1";
src = fetchFromGitHub {
owner = "mikefarah";
rev = version;
repo = "yq";
sha256 = "09kcqa15assjhp3kdffa3yhc2vykinzgscjzg996qa85kjircy9b";
};
vendorSha256 = "0l5bhbp8dfq04hb4xcpx96ksfwx4xvk0pj5ma00rk3z913ikygcd";
doCheck = false;
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
for shell in bash fish zsh; do
$out/bin/yq shell-completion --variation $shell > yq.$shell
installShellCompletion yq.$shell
done
'';
meta = with lib; {
description = "Portable command-line YAML processor";
homepage = "https://mikefarah.gitbook.io/yq/";
license = [ licenses.mit ];
maintainers = [ maintainers.lewo ];
};
}