2021-10-17 09:34:42 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, webcolors
|
|
|
|
, pythonOlder
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2021-12-06 16:07:01 +00:00
|
|
|
pname = "flux-led";
|
2022-05-18 14:49:53 +00:00
|
|
|
version = "0.28.29";
|
2021-12-06 16:07:01 +00:00
|
|
|
format = "setuptools";
|
2021-10-17 09:34:42 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Danielhiversen";
|
|
|
|
repo = "flux_led";
|
|
|
|
rev = version;
|
2022-05-18 14:49:53 +00:00
|
|
|
sha256 = "sha256-Hwe8eshY5j+10fARCp7fMnZf2Sxal7+7Vj5DYVPNXks=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-10-17 09:34:42 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
webcolors
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace '"pytest-runner>=5.2",' ""
|
|
|
|
'';
|
|
|
|
|
|
|
|
pytestFlagsArray = [
|
|
|
|
"tests.py"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"flux_led"
|
|
|
|
];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2021-10-17 09:34:42 +00:00
|
|
|
description = "Python library to communicate with the flux_led smart bulbs";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/Danielhiversen/flux_led";
|
2021-10-17 09:34:42 +00:00
|
|
|
license = licenses.lgpl3Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = with maintainers; [ colemickens ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|