2024-05-15 15:35:15 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
requests,
|
|
|
|
setuptools,
|
2021-07-03 03:11:41 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "hikvision";
|
|
|
|
version = "2.0.4";
|
2024-05-15 15:35:15 +00:00
|
|
|
pyproject = true;
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2021-07-03 03:11:41 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fbradyirl";
|
2024-05-15 15:35:15 +00:00
|
|
|
repo = "hikvision";
|
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-tiJUqr5WtRvnKll1OymJ9Uva1tUT5so4Zzc4SHLcH9A=";
|
2021-07-03 03:11:41 +00:00
|
|
|
};
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
build-system = [ setuptools ];
|
|
|
|
|
|
|
|
dependencies = [ requests ];
|
2021-07-03 03:11:41 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2021-07-03 03:11:41 +00:00
|
|
|
|
|
|
|
pythonImportsCheck = [ "hikvision.api" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python module for interacting with Hikvision IP Cameras";
|
|
|
|
homepage = "https://github.com/fbradyirl/hikvision";
|
2024-05-15 15:35:15 +00:00
|
|
|
changelog = "https://github.com/fbradyirl/hikvision/releases/tag/v${version}";
|
2021-07-03 03:11:41 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|