2021-10-18 09:09:57 +01:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, webcolors
|
|
|
|
, pythonOlder
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
2019-12-31 23:23:03 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "flux_led";
|
2021-10-20 08:00:30 +01:00
|
|
|
version = "0.24.12";
|
2021-10-18 09:09:57 +01:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2019-12-31 23:23:03 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Danielhiversen";
|
|
|
|
repo = "flux_led";
|
|
|
|
rev = version;
|
2021-10-20 08:00:30 +01:00
|
|
|
sha256 = "sha256-vhmqfHAqbgDUvbn+dR7TuA5SFjF72/nhCL1h+GPy+9c=";
|
2019-12-31 23:23:03 +00:00
|
|
|
};
|
|
|
|
|
2021-10-18 09:09:57 +01:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
webcolors
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2021-10-20 08:00:30 +01:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace '"pytest-runner>=5.2",' ""
|
|
|
|
'';
|
|
|
|
|
2021-10-18 09:09:57 +01:00
|
|
|
pytestFlagsArray = [
|
|
|
|
"tests.py"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"flux_led"
|
|
|
|
];
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2021-10-18 09:09:57 +01:00
|
|
|
description = "Python library to communicate with the flux_led smart bulbs";
|
2019-12-31 23:23:03 +00:00
|
|
|
homepage = "https://github.com/Danielhiversen/flux_led";
|
2021-10-18 09:09:57 +01:00
|
|
|
license = licenses.lgpl3Plus;
|
2019-12-31 23:23:03 +00:00
|
|
|
maintainers = with maintainers; [ colemickens ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|