1{ lib
2, asyncssh
3, buildPythonPackage
4, fetchFromGitHub
5, pytest-asyncio
6, pytest-mock
7, pytestCheckHook
8}:
9
10buildPythonPackage rec {
11 pname = "aioasuswrt";
12 version = "1.4.0";
13
14 src = fetchFromGitHub {
15 owner = "kennedyshead";
16 repo = pname;
17 rev = "V${version}";
18 sha256 = "1iv9f22v834g8wrjcynjn2azpzk8gsczv71jf7dw8aix0n04h325";
19 };
20
21 propagatedBuildInputs = [
22 asyncssh
23 ];
24
25 nativeCheckInputs = [
26 pytest-asyncio
27 pytest-mock
28 pytestCheckHook
29 ];
30
31 postPatch = ''
32 substituteInPlace setup.cfg \
33 --replace "--cov-report html" "" \
34 --replace "--cov-report term-missing" ""
35 '';
36
37 pythonImportsCheck = [
38 "aioasuswrt"
39 ];
40
41 meta = with lib; {
42 description = "Python module for Asuswrt";
43 homepage = "https://github.com/kennedyshead/aioasuswrt";
44 license = with licenses; [ mit ];
45 maintainers = with maintainers; [ fab ];
46 };
47}