nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
1{ buildGoModule, fetchFromGitHub, lib, libGL, nssmdns, pkg-config, xorg }: 2 3buildGoModule rec { 4 pname = "keylight-controller-mschneider82"; 5 version = "0.1.0"; 6 7 src = fetchFromGitHub { 8 owner = "mschneider82"; 9 repo = "keylight-control"; 10 rev = "v${version}"; 11 sha256 = "sha256-UZfbGihCgFBQE1oExuzCexoNgpVGwNoA9orjZ9fh4gA="; 12 }; 13 14 vendorSha256 = "sha256-nFttVJbEAAGsrAglMphuw0wJ2Kf8sWB4HrpVqfHO76o="; 15 16 nativeBuildInputs = [ 17 pkg-config 18 ]; 19 20 buildInputs = [ 21 libGL 22 nssmdns 23 ] ++ (with xorg; [ 24 libX11 25 libX11.dev 26 libXcursor 27 libXext 28 libXi 29 libXinerama 30 libXrandr 31 libXxf86vm 32 xinput 33 ]); 34 35 meta = with lib; { 36 description = "A desktop application to control Elgato Keylights"; 37 longDescription = '' 38 Requires having: 39 * Elgato's Keylight paired to local wifi network. 40 * Service avahi with nssmdns enabled. 41 ''; 42 license = licenses.mit; 43 homepage = "https://github.com/mschneider82/keylight-control"; 44 maintainers = with maintainers; [ ]; 45 }; 46} 47 48# Note: Application errors on first executions but works on re-runs. 49 50# Troubleshooting 51# 1. Keylight lists at: `avahi-browse --all --resolve --ignore-local` 52# 2. Ping Keylight's IP 53# 3. Resolve Keylight's hostname: `getent hosts elgato-key-light-XXXX.local`