2021-01-15 22:18:51 +00:00
|
|
|
{ lib
|
|
|
|
, aiohttp
|
|
|
|
, asynctest
|
2021-03-23 19:22:30 +00:00
|
|
|
, buildPythonPackage
|
2021-01-15 22:18:51 +00:00
|
|
|
, cryptography
|
2021-03-23 19:22:30 +00:00
|
|
|
, fetchFromGitHub
|
2021-01-15 22:18:51 +00:00
|
|
|
, pytest-asyncio
|
|
|
|
, pytestCheckHook
|
2021-03-23 19:22:30 +00:00
|
|
|
, pythonOlder
|
|
|
|
, stdiomask
|
2021-01-15 22:18:51 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "subarulink";
|
2021-08-08 23:34:03 +00:00
|
|
|
version = "0.3.15";
|
2021-03-23 19:22:30 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2021-01-15 22:18:51 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "G-Two";
|
|
|
|
repo = pname;
|
2021-07-17 21:14:59 +00:00
|
|
|
rev = "v${version}";
|
2021-08-08 23:34:03 +00:00
|
|
|
sha256 = "sha256-akDccWkiFwTwq7dvUxm34BFNS5PnQowqnxVvkPFzxLM=";
|
2021-01-15 22:18:51 +00:00
|
|
|
};
|
|
|
|
|
2021-03-23 19:22:30 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
|
|
|
stdiomask
|
|
|
|
];
|
2021-01-15 22:18:51 +00:00
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
asynctest
|
|
|
|
cryptography
|
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2021-03-23 19:22:30 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.cfg --replace "--cov=subarulink" ""
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2021-03-23 19:22:30 +00:00
|
|
|
preCheck = ''
|
|
|
|
export HOME=$(mktemp -d)
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
pythonImportsCheck = [ "subarulink" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python module for interacting with STARLINK-enabled vehicle";
|
|
|
|
homepage = "https://github.com/G-Two/subarulink";
|
|
|
|
license = with licenses; [ asl20 ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|