Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

bob: add completion

authored by sudosubin and committed by Bjørn Forsman e025e615 9f66359b

+9 -1
+9 -1
pkgs/development/tools/build-managers/bob/default.nix
··· 1 - { lib, buildGoModule, fetchFromGitHub }: 1 + { lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles }: 2 2 3 3 buildGoModule rec { 4 4 pname = "bob"; ··· 16 16 vendorHash = "sha256-S1XUgjdSVTWXehOLCxXcvj0SH12cxqvYadVlCw/saF4="; 17 17 18 18 excludedPackages = [ "example/server-db" "test/e2e" "tui-example" ]; 19 + 20 + nativeBuildInputs = [ installShellFiles ]; 21 + 22 + postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' 23 + installShellCompletion --cmd bob \ 24 + --bash <($out/bin/bob completion) \ 25 + --zsh <($out/bin/bob completion -z) 26 + ''; 19 27 20 28 # tests require network access 21 29 doCheck = false;