git.iko.soy/typeable/nixpkgs
on master help sign in
waypoint: 0.3.1 -> 0.3.2

Disable check phase to avoid error log Add completion

commite10ce7ef01a1bd6846bf4982c97b8b2d2a57ae82 author06kellyjac <dev@j-k.io> dateFri 14 May 2021, 09:21 (6 years ago) parent0755dee
1 file changed+25−5
pkgs/applications/networking/cluster/waypoint/default.nix+25−5
pkgs/applications/networking/cluster/waypoint/default.nix+25−5
@@ -1,20 +1,20 @@
1−{ lib, buildGoModule, fetchFromGitHub, go-bindata }:
1+{ lib, buildGoModule, fetchFromGitHub, go-bindata, installShellFiles }:
22
33buildGoModule rec {
44 pname = "waypoint";
5− version = "0.3.1";
5+ version = "0.3.2";
66
77 src = fetchFromGitHub {
88 owner = "hashicorp";
99 repo = pname;
1010 rev = "v${version}";
11− sha256 = "sha256-WzKUVfc7oGMh0TamL5b6gsm/BAfSCZ6EB3Hg4Tg/3Hw=";
11+ sha256 = "sha256-57DHImPYVFK+MXWGeArvc5fwHmqa3zodLytfDoAxglo=";
1212 };
1313
1414 deleteVendor = true;
15− vendorSha256 = "sha256-VxKUYD92DssoSjWxR+1gZLq34vCVM/4U2ju5felLWzI=";
15+ vendorSha256 = "sha256-HxrY35SqfUbT6VCCXkLUjAsxgtMzpOeoicAGLwD2OyA=";
1616
17− nativeBuildInputs = [ go-bindata ];
17+ nativeBuildInputs = [ go-bindata installShellFiles ];
1818
1919 # GIT_{COMMIT,DIRTY} filled in blank to prevent trying to run git and ending up blank anyway
2020 buildPhase = ''
@@ -23,9 +23,29 @@ buildGoModule rec {
2323 runHook postBuild
2424 '';
2525
26+ doCheck = false;
27+
2628 installPhase = ''
2729 runHook preInstall
30+
31+ local INSTALL="$out/bin/waypoint"
2832 install -D waypoint $out/bin/waypoint
33+
34+ # Write to a file as it doesn't like EOF within <()
35+ cat > waypoint.fish <<EOF
36+ function __complete_waypoint
37+ set -lx COMP_LINE (commandline -cp)
38+ test -z (commandline -ct)
39+ and set COMP_LINE "$COMP_LINE "
40+ $INSTALL
41+ end
42+ complete -f -c waypoint -a "(__complete_waypoint)"
43+ EOF
44+ installShellCompletion --cmd waypoint \
45+ --bash <(echo "complete -C $INSTALL waypoint") \
46+ --fish <(cat waypoint.fish) \
47+ --zsh <(echo "complete -o nospace -C $INSTALL waypoint")
48+
2949 runHook postInstall
3050 '';
3151