1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 nix-update-script,
6 pyyaml,
7 setuptools,
8 pytestCheckHook,
9 pytest-mock,
10}:
11
12buildPythonPackage rec {
13 pname = "snap-helpers";
14 version = "0.4.2";
15
16 pyproject = true;
17
18 src = fetchFromGitHub {
19 owner = "albertodonato";
20 repo = "snap-helpers";
21 tag = version;
22 hash = "sha256-7JBvrD4WNOcFSVx3xauk4JgiVGKWuUEdUMRlH7mudE4=";
23 };
24
25 nativeBuildInputs = [ setuptools ];
26
27 propagatedBuildInputs = [ pyyaml ];
28
29 pythonImportsCheck = [ "snaphelpers" ];
30
31 nativeCheckInputs = [
32 pytest-mock
33 pytestCheckHook
34 ];
35
36 passthru.updateScript = nix-update-script { };
37
38 meta = {
39 description = "Interact with snap configuration and properties from inside a snap";
40 homepage = "https://github.com/albertodonato/snap-helpers";
41 changelog = "https://github.com/albertodonato/snap-helpers/releases/tag/${version}";
42 license = lib.licenses.lgpl3Only;
43 maintainers = with lib.maintainers; [ jnsgruk ];
44 platforms = lib.platforms.linux;
45 };
46}