Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ buildGoModule, fetchFromGitHub, lib, lm_sensors }: 2 3buildGoModule rec { 4 pname = "fan2go"; 5 version = "0.8.0"; 6 7 src = fetchFromGitHub { 8 owner = "markusressel"; 9 repo = pname; 10 rev = version; 11 sha256 = "3pnJaLD+FEQWAAwIiTkcs9VgqO0JwRaK7JLdIygeChY="; 12 }; 13 14 vendorSha256 = "9EeiYPNTUEFHxTdvVb2JLU6Qi0oazH+n9MB8Dg+RLJ4="; 15 16 postConfigure = '' 17 substituteInPlace vendor/github.com/md14454/gosensors/gosensors.go \ 18 --replace '"/etc/sensors3.conf"' '"${lm_sensors}/etc/sensors3.conf"' 19 ''; 20 21 CGO_CFLAGS = "-I ${lm_sensors}/include"; 22 CGO_LDFLAGS = "-L ${lm_sensors}/lib"; 23 24 meta = with lib; { 25 description = "A simple daemon providing dynamic fan speed control based on temperature sensors"; 26 homepage = "https://github.com/markusressel/fan2go"; 27 license = licenses.agpl3Plus; 28 maintainers = with maintainers; [ mtoohey ]; 29 platforms = platforms.linux; 30 }; 31}