Merge pull request #43814 from bricewge/alacritty-terminfo

alacritty: add terminfo and man
This commit is contained in:
Silvan Mosberger 2018-07-29 20:56:25 +02:00 committed by GitHub
commit c735294fba
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,11 +4,13 @@
rustPlatform, rustPlatform,
cmake, cmake,
makeWrapper, makeWrapper,
ncurses,
expat, expat,
pkgconfig, pkgconfig,
freetype, freetype,
fontconfig, fontconfig,
libX11, libX11,
gzip,
libXcursor, libXcursor,
libXxf86vm, libXxf86vm,
libXi, libXi,
@ -66,11 +68,15 @@ in buildRustPackage rec {
cmake cmake
makeWrapper makeWrapper
pkgconfig pkgconfig
ncurses
gzip
]; ];
buildInputs = rpathLibs buildInputs = rpathLibs
++ lib.optionals stdenv.isDarwin darwinFrameworks; ++ lib.optionals stdenv.isDarwin darwinFrameworks;
outputs = [ "out" "terminfo" ];
postPatch = '' postPatch = ''
substituteInPlace copypasta/src/x11.rs \ substituteInPlace copypasta/src/x11.rs \
--replace Command::new\(\"xclip\"\) Command::new\(\"${xclip}/bin/xclip\"\) --replace Command::new\(\"xclip\"\) Command::new\(\"${xclip}/bin/xclip\"\)
@ -95,6 +101,14 @@ in buildRustPackage rec {
install -D alacritty-completions.bash "$out/etc/bash_completion.d/alacritty-completions.bash" install -D alacritty-completions.bash "$out/etc/bash_completion.d/alacritty-completions.bash"
install -D alacritty-completions.fish "$out/share/fish/vendor_completions.d/alacritty.fish" install -D alacritty-completions.fish "$out/share/fish/vendor_completions.d/alacritty.fish"
install -dm 755 "$out/share/man/man1"
gzip -c alacritty.man > "$out/share/man/man1/alacritty.1.gz"
install -dm 755 "$terminfo/share/terminfo/a/"
tic -x -o "$terminfo/share/terminfo" alacritty.info
mkdir -p $out/nix-support
echo "$terminfo" >> $out/nix-support/propagated-user-env-packages
runHook postInstall runHook postInstall
''; '';