1{ lib, stdenv, fetchFromGitHub }:
2
3stdenv.mkDerivation rec {
4 pname = "kbdlight";
5 version = "1.3";
6
7 src = fetchFromGitHub {
8 owner = "hobarrera";
9 repo = "kbdlight";
10 rev = "v${version}";
11 sha256 = "1f08aid1xrbl4sb5447gkip9lnvkia1c4ap0v8zih5s9w8v72bny";
12 };
13
14 preConfigure = ''
15 substituteInPlace Makefile \
16 --replace /usr/local $out \
17 --replace 4755 0755
18 '';
19
20 meta = with lib; {
21 homepage = "https://github.com/hobarrera/kbdlight";
22 description = "A very simple application that changes MacBooks' keyboard backlight level";
23 license = licenses.isc;
24 maintainers = [ maintainers.womfoo ];
25 platforms = platforms.linux;
26 };
27}