2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, fetchurl, libXScrnSaver, libX11 }:
|
2017-07-03 07:46:26 +01:00
|
|
|
|
2020-03-25 14:31:06 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2017-07-03 07:46:26 +01:00
|
|
|
|
2020-03-25 14:31:06 +00:00
|
|
|
version = "9.2.4";
|
|
|
|
name = "x11idle-org-${version}";
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://code.orgmode.org/bzg/org-mode/raw/release_${version}/contrib/scripts/x11idle.c";
|
|
|
|
sha256 = "0fc5g57xd6bmghyl214gcff0ni3idv33i3gkr339kgn1mdjljv5g";
|
2017-07-03 07:46:26 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ libXScrnSaver libX11 ];
|
|
|
|
|
2019-06-19 16:45:34 +01:00
|
|
|
dontUnpack = true;
|
2017-07-03 07:46:26 +01:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
2020-03-25 14:31:06 +00:00
|
|
|
gcc -lXss -lX11 $src -o $out/bin/x11idle
|
2017-07-03 07:46:26 +01:00
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2017-07-03 07:46:26 +01:00
|
|
|
description = ''
|
|
|
|
Compute consecutive idle time for current X11 session with millisecond resolution
|
|
|
|
'';
|
|
|
|
longDescription = ''
|
|
|
|
Idle time passes when the user does not act, i.e. when the user doesn't move the mouse or use the keyboard.
|
|
|
|
'';
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://orgmode.org/";
|
2017-07-03 07:46:26 +01:00
|
|
|
license = licenses.gpl3;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = [ maintainers.swflint ];
|
|
|
|
};
|
|
|
|
}
|