at v192 32 lines 915 B view raw
1{ stdenv, fetchurl, coreutils, ncurses }: 2 3stdenv.mkDerivation rec { 4 name = "entr-${version}"; 5 version = "3.2"; 6 7 src = fetchurl { 8 url = "http://entrproject.org/code/${name}.tar.gz"; 9 sha256 = "0ikigpfzyjmr8j6snwlvxzqamrjbhlv78m8w1h0h7kzczc5f1vmi"; 10 }; 11 12 postPatch = '' 13 substituteInPlace Makefile.bsd --replace /bin/echo echo 14 substituteInPlace entr.c --replace /bin/cat ${coreutils}/bin/cat 15 substituteInPlace entr.c --replace /usr/bin/clear ${ncurses}/bin/clear 16 substituteInPlace entr.1 --replace /bin/cat cat 17 substituteInPlace entr.1 --replace /usr/bin/clear clear 18 ''; 19 dontAddPrefix = true; 20 doCheck = true; 21 checkTarget = "test"; 22 installFlags = [ "PREFIX=$(out)" ]; 23 24 meta = { 25 homepage = http://entrproject.org/; 26 description = "Run arbitrary commands when files change."; 27 28 license = stdenv.lib.licenses.isc; 29 30 platforms = stdenv.lib.platforms.all; 31 }; 32}