0d9fc34957
GitOrigin-RevId: 5ed481943351e9fd354aeb557679624224de38d5
46 lines
1.2 KiB
Nix
46 lines
1.2 KiB
Nix
{ stdenv, lib, fetchFromGitHub, ncurses }:
|
|
|
|
let
|
|
INSTALL_PATH="${placeholder "out"}/share/fzf-tab";
|
|
in stdenv.mkDerivation rec {
|
|
pname = "zsh-fzf-tab";
|
|
version = "unstable-2022-12-08";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "Aloxaf";
|
|
repo = "fzf-tab";
|
|
rev = "ffb7b776be492333b94cf0be87456b62a1f26e2f";
|
|
sha256 = "bIlnYKjjOC6h5/Gg7xBg+i2TBk+h82wmHgAJPhzMsek=";
|
|
};
|
|
|
|
strictDeps = true;
|
|
buildInputs = [ ncurses ];
|
|
|
|
postConfigure = ''
|
|
pushd modules
|
|
./configure --disable-gdbm --without-tcsetpgrp
|
|
popd
|
|
'';
|
|
|
|
postBuild = ''
|
|
pushd modules
|
|
make -j$NIX_BUILD_CORES
|
|
popd
|
|
'';
|
|
|
|
installPhase = ''
|
|
mkdir -p ${INSTALL_PATH}
|
|
cp -r lib ${INSTALL_PATH}/lib
|
|
install -D fzf-tab.zsh ${INSTALL_PATH}/fzf-tab.zsh
|
|
install -D fzf-tab.plugin.zsh ${INSTALL_PATH}/fzf-tab.plugin.zsh
|
|
install -D modules/Src/aloxaf/fzftab.so ${INSTALL_PATH}/modules/Src/aloxaf/fzftab.so
|
|
'';
|
|
|
|
meta = with lib; {
|
|
homepage = "https://github.com/Aloxaf/fzf-tab";
|
|
description = "Replace zsh's default completion selection menu with fzf!";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ vonfry ];
|
|
platforms = platforms.unix;
|
|
};
|
|
}
|