Merge pull request #68329 from lilyball/exa-installShellFiles
exa: adopt installShellFiles
This commit is contained in:
commit
9fd9768c74
|
@ -1,5 +1,5 @@
|
||||||
{ stdenv, fetchFromGitHub, rustPlatform, cmake, perl, pkgconfig, zlib
|
{ stdenv, fetchFromGitHub, rustPlatform, cmake, perl, pkgconfig, zlib
|
||||||
, darwin, libiconv
|
, darwin, libiconv, installShellFiles
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with rustPlatform;
|
with rustPlatform;
|
||||||
|
@ -17,24 +17,20 @@ buildRustPackage rec {
|
||||||
sha256 = "14qlm9zb9v22hxbbi833xaq2b7qsxnmh15s317200vz5f1305hhw";
|
sha256 = "14qlm9zb9v22hxbbi833xaq2b7qsxnmh15s317200vz5f1305hhw";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake pkgconfig perl ];
|
nativeBuildInputs = [ cmake pkgconfig perl installShellFiles ];
|
||||||
buildInputs = [ zlib ]
|
buildInputs = [ zlib ]
|
||||||
++ stdenv.lib.optionals stdenv.isDarwin [
|
++ stdenv.lib.optionals stdenv.isDarwin [
|
||||||
libiconv darwin.apple_sdk.frameworks.Security ]
|
libiconv darwin.apple_sdk.frameworks.Security ]
|
||||||
;
|
;
|
||||||
|
|
||||||
|
outputs = [ "out" "man" ];
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
mkdir -p $out/share/man/man1
|
installManPage contrib/man/exa.1
|
||||||
cp contrib/man/exa.1 $out/share/man/man1/
|
installShellCompletion \
|
||||||
|
--name exa contrib/completions.bash \
|
||||||
mkdir -p $out/share/bash-completion/completions
|
--name exa.fish contrib/completions.fish \
|
||||||
cp contrib/completions.bash $out/share/bash-completion/completions/exa
|
--name _exa contrib/completions.zsh
|
||||||
|
|
||||||
mkdir -p $out/share/fish/vendor_completions.d
|
|
||||||
cp contrib/completions.fish $out/share/fish/vendor_completions.d/exa.fish
|
|
||||||
|
|
||||||
mkdir -p $out/share/zsh/site-functions
|
|
||||||
cp contrib/completions.zsh $out/share/zsh/site-functions/_exa
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# Some tests fail, but Travis ensures a proper build
|
# Some tests fail, but Travis ensures a proper build
|
||||||
|
|
Loading…
Reference in New Issue