blob: 2d699a2bfea47333d95440a7a445b53b8e0d917d (
plain)
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
27
28
29
30
31
|
{ pkgs ? import <nixpkgs> {} }:
pkgs.stdenv.mkDerivation {
pname = "lowbat";
version = "1.0";
src = pkgs.fetchgit {
url = "https://git.tjkeller.xyz/lowbat";
rev = "17e0bbaecb917b7cb42453afa9cd7e80e092c087";
sha256 = "sha256-wh1/QZmbVcEsbCYJxzcswN2QFjO5qkrJCQsba3wf1h8=";
};
nativeBuildInputs = [ pkgs.pkg-config ];
buildInputs = [ pkgs.libnotify pkgs.glib ];
buildPhase = ''
make
'';
installPhase = ''
mkdir -p $out/bin $out/share/man/man1
cp lowbat $out/bin/
cp lowbat.1 $out/share/man/man1/
'';
meta = with pkgs.lib; {
description = "A minimal battery level monitor daemon, written in C";
license = licenses.mit;
maintainers = [ maintainers.tjkeller ];
};
}
|