-
Notifications
You must be signed in to change notification settings - Fork 1
/
flake.nix
58 lines (53 loc) · 1.64 KB
/
flake.nix
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
description = "Control your Hue lights directly from your terminal.";
outputs = { self, nixpkgs }:
{
devShells = nixpkgs.lib.genAttrs ["aarch64-darwin" "aarch64-linux" "x86_64-darwin" "x86_64-linux"] (system:
let
pkgs = nixpkgs.legacyPackages.${system};
lib = pkgs.lib;
stdenv = pkgs.stdenv;
in
{
default = stdenv.mkDerivation {
name = "hue-shell-${system}";
system = system;
nativeBuildInputs = [
pkgs.go
];
};
}
);
packages = nixpkgs.lib.genAttrs ["aarch64-darwin" "aarch64-linux" "x86_64-darwin" "x86_64-linux"] (system:
let
pkgs = nixpkgs.legacyPackages.${system};
lib = pkgs.lib;
stdenv = pkgs.stdenv;
in
{
hue = pkgs.buildGoModule rec {
name = "hue-${system}";
pname = "hue";
src = pkgs.nix-gitignore.gitignoreSourcePure ''
/.github
/target
*.nix
'' ./.;
vendorHash = "sha256-WDqIOYEGr85eU6crclldnf4w9089+TsgbdnBAKhzRTM=";
meta = with lib; {
description = "Control your Hue lights directly from your terminal.";
homepage = "https://github.com/SierraSoftworks/hue";
license = licenses.mit;
maintainers = [
{
name = "Benjamin Pannell";
email = "[email protected]";
}
];
};
};
default = self.packages.${system}.hue;
}
);
};
}