2020-10-11 12:50:04 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2021-04-13 19:44:15 +00:00
|
|
|
, fetchFromGitLab
|
2020-10-11 12:50:04 +00:00
|
|
|
, future
|
|
|
|
, ifaddr
|
|
|
|
, pytestCheckHook
|
2021-04-13 19:44:15 +00:00
|
|
|
, pythonOlder
|
2020-10-11 12:50:04 +00:00
|
|
|
}:
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "yeelight";
|
2021-05-04 21:07:42 +00:00
|
|
|
version = "0.6.2";
|
2021-04-13 19:44:15 +00:00
|
|
|
disabled = pythonOlder "3.4";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2021-04-13 19:44:15 +00:00
|
|
|
src = fetchFromGitLab {
|
|
|
|
owner = "stavros";
|
|
|
|
repo = "python-yeelight";
|
|
|
|
rev = "v${version}";
|
2021-05-04 21:07:42 +00:00
|
|
|
sha256 = "0v0i0s8d5z6b63f2sy42wf85drdzrzswlm1hknzr7v6lfr52pwwm";
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
2020-10-11 12:50:04 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
future
|
|
|
|
ifaddr
|
2021-04-13 19:44:15 +00:00
|
|
|
];
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2020-10-11 12:50:04 +00:00
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
2021-04-13 19:44:15 +00:00
|
|
|
];
|
2020-10-11 12:50:04 +00:00
|
|
|
|
|
|
|
pytestFlagsArray = [ "yeelight/tests.py" ];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "yeelight" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
2021-04-13 19:44:15 +00:00
|
|
|
description = "Python library for controlling YeeLight RGB bulbs";
|
2020-09-25 04:45:31 +00:00
|
|
|
homepage = "https://gitlab.com/stavros/python-yeelight/";
|
2021-05-04 21:07:42 +00:00
|
|
|
license = licenses.bsd2;
|
2020-09-25 04:45:31 +00:00
|
|
|
maintainers = with maintainers; [ nyanloutre ];
|
|
|
|
};
|
|
|
|
}
|