3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request #47731 from periklis/update-kubectx

kubectx: 0.5.1 -> 0.6.1
This commit is contained in:
Sarah Brofeldt 2018-10-03 13:18:52 +02:00 committed by GitHub
commit a8cbded02c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,13 +4,13 @@ with lib;
stdenv.mkDerivation rec {
name = "kubectx";
version = "0.5.1";
version = "0.6.1";
src = fetchFromGitHub {
owner = "ahmetb";
repo = "${name}";
rev = "v${version}";
sha256 = "1bmmaj5fffx4hy55l6x4vl5gr9rp2yhg4vs5b9sya9rjvdkamdx5";
sha256 = "1507g8sm73mqfsxl3fabmj37pk9l4jddsdi4qlpf0ixhk3z1lfkg";
};
buildInputs = [ makeWrapper ];
@ -20,9 +20,24 @@ stdenv.mkDerivation rec {
installPhase = ''
mkdir -p $out/bin
mkdir -p $out/share/zsh/site-functions
mkdir -p $out/share/bash-completion/completions
mkdir -p $out/share/fish/vendor_completions.d
cp kubectx $out/bin
cp kubens $out/bin
# Provide ZSH completions
cp completion/kubectx.zsh $out/share/zsh/site-functions/_kubectx
cp completion/kubens.zsh $out/share/zsh/site-functions/_kubens
# Provide BASH completions
cp completion/kubectx.bash $out/share/bash-completion/completions/kubectx
cp completion/kubens.bash $out/share/bash-completion/completions/kubens
# Provide FISH completions
cp completion/*.fish $out/share/fish/vendor_completions.d/
for f in $out/bin/*; do
wrapProgram $f --prefix PATH : ${makeBinPath [ kubectl ]}
done