1{ lib
2, fetchFromGitHub
3, buildPythonPackage
4, pythonOlder
5, aiolifx
6, poetry-core
7, pytest-asyncio
8, pytestCheckHook
9, async-timeout
10, typer
11}:
12
13buildPythonPackage rec {
14 pname = "aiolifx-themes";
15 version = "0.2.0";
16 format = "pyproject";
17
18 disabled = pythonOlder "3.9";
19
20 src = fetchFromGitHub {
21 owner = "Djelibeybi";
22 repo = "aiolifx-themes";
23 rev = "v${version}";
24 hash = "sha256:17498vdg8i20hk4i8hzc67qaj206ik3s1zn1k70plsjr9zlgs6vz";
25 };
26
27 prePatch = ''
28 # Don't run coverage, or depend on typer for no reason.
29 substituteInPlace pyproject.toml \
30 --replace " --cov=aiolifx_themes --cov-report=term-missing:skip-covered" "" \
31 --replace "typer = " "# unused: typer = "
32 '';
33
34 nativeBuildInputs = [
35 poetry-core
36 ];
37
38 propagatedBuildInputs = [
39 aiolifx
40 ];
41
42 checkInputs = [
43 async-timeout
44 pytestCheckHook
45 pytest-asyncio
46 ];
47
48 pythonImportsCheck = [
49 "aiolifx_themes"
50 ];
51
52 meta = with lib; {
53 description = "Color themes for LIFX lights running on aiolifx";
54 homepage = "https://github.com/Djelibeybi/aiolifx-themes";
55 license = licenses.mit;
56 maintainers = with maintainers; [ lukegb ];
57 };
58}