about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/misc/upower-notify/default.nix
blob: 8033a91ecf51a98cf26749c304fd13e8cf9b148a (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
27
28
29
30
{ lib, buildGoPackage, fetchFromGitHub }:

# To use upower-notify, the maintainer suggests adding something like this to your configuration.nix:
#
# service.xserver.displayManager.sessionCommands = ''
#   ${pkgs.dunst}/bin/dunst -shrink -geometry 0x0-50-50 -key space & # ...if don't already have a dbus notification display app
#   (sleep 3; exec ${pkgs.yeshup}/bin/yeshup ${pkgs.go-upower-notify}/bin/upower-notify) &
# '';
buildGoPackage rec {
  pname = "upower-notify";
  version = "unstable-2016-03-10";

  goPackagePath = "github.com/omeid/upower-notify";

  src = fetchFromGitHub {
    owner = "omeid";
    repo = "upower-notify";
    rev = "14c581e683a7e90ec9fa6d409413c16599a5323c";
    sha256 = "16zlvn53p9m10ph8n9gps51fkkvl6sf4afdzni6azk05j0ng49jw";
  };

  goDeps = ./deps.nix;

  meta = with lib; {
    description = "simple tool to give you Desktop Notifications about your battery";
    mainProgram = "upower-notify";
    homepage = "https://github.com/omeid/upower-notify";
    maintainers = with maintainers; [ kamilchm ];
  };
}