2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, bash }:
|
2018-08-25 22:08:24 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2021-07-27 14:21:24 +00:00
|
|
|
pname = "incron";
|
|
|
|
version = "0.5.12";
|
2018-08-27 20:59:19 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ar-";
|
|
|
|
repo = "incron";
|
2021-07-27 14:21:24 +00:00
|
|
|
rev = "${pname}-${version}";
|
2018-08-27 20:59:19 +00:00
|
|
|
sha256 = "11d5f98cjafiv9h9zzzrw2s06s2fvdg8gp64km7mdprd2xmy6dih";
|
2018-08-25 22:08:24 +00:00
|
|
|
};
|
|
|
|
|
2018-08-27 15:24:10 +00:00
|
|
|
patches = [ ./default_path.patch ];
|
|
|
|
|
|
|
|
prePatch = ''
|
2018-08-25 22:08:24 +00:00
|
|
|
sed -i "s|/bin/bash|${bash}/bin/bash|g" usertable.cpp
|
|
|
|
'';
|
|
|
|
|
2018-08-27 21:28:20 +00:00
|
|
|
installFlags = [ "PREFIX=$(out)" ];
|
|
|
|
installTargets = [ "install-man" ];
|
|
|
|
|
|
|
|
preInstall = ''
|
2018-08-25 22:08:24 +00:00
|
|
|
mkdir -p $out/bin
|
|
|
|
|
|
|
|
# make install doesn't work because setuid and permissions
|
|
|
|
# just manually install the binaries instead
|
|
|
|
cp incrond incrontab $out/bin/
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-10-11 05:55:05 +00:00
|
|
|
description = "A cron-like daemon which handles filesystem events";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/ar-/incron";
|
2018-08-26 01:10:59 +00:00
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = [ maintainers.aanderse ];
|
2018-08-25 22:08:24 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|