summary refs log tree commit diff
path: root/pkgs/os-specific/linux/light/default.nix
blob: d500019c50b4e71880450fa788e3028b8f98b09b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{ stdenv, fetchFromGitHub, help2man }:

stdenv.mkDerivation rec {
  version = "1.1.2";
  name = "light-${version}";
  src = fetchFromGitHub {
    owner = "haikarainen";
    repo = "light";
    rev = version;
    sha256 = "0c934gxav9cgdf94li6dp0rfqmpday9d33vdn9xb2mfp4war9n4w";
  };

  buildInputs = [ help2man ];

  installPhase = "mkdir -p $out/bin; cp light $out/bin/";

  preFixup = "make man; mkdir -p $out/man/man1; mv light.1.gz $out/man/man1";

  meta = {
    description = "GNU/Linux application to control backlights";
    homepage = https://haikarainen.github.io/light/;
    license = stdenv.lib.licenses.gpl3;
    maintainers = with stdenv.lib.maintainers; [ puffnfresh ];
    platforms = stdenv.lib.platforms.linux;
  };
}