nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 pytestCheckHook,
6 requests,
7 setuptools,
8}:
9
10buildPythonPackage rec {
11 pname = "pyhik";
12 version = "0.4.1";
13 pyproject = true;
14
15 src = fetchFromGitHub {
16 owner = "mezz64";
17 repo = "pyHik";
18 tag = version;
19 hash = "sha256-dDUaNeE0wjKsojeezKVWfMBPO+7O5e2QFOHnh3UoFbY=";
20 };
21
22 build-system = [
23 setuptools
24 ];
25
26 dependencies = [
27 requests
28 ];
29
30 # Tests are disabled due to fragile XML namespace assertions
31 doCheck = false;
32
33 nativeCheckInputs = [
34 pytestCheckHook
35 ];
36
37 pythonImportsCheck = [
38 "pyhik"
39 ];
40
41 meta = {
42 description = "Python API to interact with a Hikvision camera event stream and toggle motion detection";
43 homepage = "https://github.com/mezz64/pyHik";
44 license = lib.licenses.mit;
45 maintainers = [ lib.maintainers.jamiemagee ];
46 };
47}