depot/third_party/nixpkgs/pkgs/tools/X11/jumpapp/default.nix
Default email 8ac5e011d6 Project import generated by Copybara.
GitOrigin-RevId: 2c3273caa153ee8eb5786bc8141b85b859e7efd7
2020-04-24 19:36:52 -04:00

31 lines
910 B
Nix

{ stdenv, lib, perl, pandoc, fetchFromGitHub, xdotool, wmctrl, xprop, nettools }:
stdenv.mkDerivation rec {
pname = "jumpapp";
version = "1.1";
src = fetchFromGitHub {
owner = "mkropat";
repo = "jumpapp";
rev = "v${version}";
sha256 = "1jrk4mm42sz6ca2gkb6w3dad53d4im4shpgsq8s4vr6xpl3b43ry";
};
makeFlags = [ "PREFIX=$(out)" ];
nativeBuildInputs = [ pandoc perl ];
buildInputs = [ xdotool wmctrl xprop nettools perl ];
postFixup = let
runtimePath = lib.makeBinPath buildInputs;
in
''
sed -i "2 i export PATH=${runtimePath}:\$PATH" $out/bin/jumpapp
sed -i "2 i export PATH=${perl}/bin:\$PATH" $out/bin/jumpappify-desktop-entry
'';
meta = {
homepage = "https://github.com/mkropat/jumpapp";
description = "A run-or-raise application switcher for any X11 desktop";
license = lib.licenses.mit;
maintainers = [ lib.maintainers.matklad ];
};
}