nix/pkgs/sway-launcher-desktop.nix
2022-02-17 14:51:28 -05:00

43 lines
1.2 KiB
Nix

{
pkgs,
lib,
fzf,
fetchFromGitHub,
stdenv,
gawk,
...
}:
stdenv.mkDerivation rec {
pname = "sway-launcher-desktop";
version = "1.5.4";
src = fetchFromGitHub {
owner = "Biont";
repo = "sway-launcher-desktop";
rev = "a40da16223698f44f66a5184b28d74ecae3326be";
sha256 = "sha256-Fm+R5Wkwgvu2hBLzySVz6k6fjF8tpJ5dY5Hiow+Qa8c=";
};
patchPhase = ''
patchShebangs ${pname}.sh
substituteInPlace ${pname}.sh --replace \$\(awk \$\(${pkgs.gawk}/bin/awk
substituteInPlace ${pname}.sh --replace 'fzf --ansi' '${pkgs.fzf}/bin/fzf --ansi'
'';
installPhase = ''
install -d $out/bin
install ${pname}.sh $out/bin/${pname}
'';
meta = with lib; {
description = "TUI Application launcher with Desktop Entry support.";
longDescription = ''
This is a TUI-based launcher menu made with bash and the amazing fzf.
Despite its name, it does not (read: no longer) depend on the Sway window manager
in any way and can be used with just about any WM.
'';
homepage = "https://github.com/Biont/sway-launcher-desktop";
changelog = "https://github.com/Biont/sway-launcher-desktop/releases/tag/v${version}";
license = licenses.gpl3;
platforms = platforms.linux;
};
}