summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/librespot/default.nix
blob: 23b496130f08bf9184f6498f4cd58c40e6ce2480 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
{
  lib,
  buildPythonPackage,
  defusedxml,
  fetchFromGitHub,
  protobuf,
  pycryptodomex,
  pyogg,
  requests,
  setuptools,
  websocket-client,
  zeroconf,
}:

buildPythonPackage rec {
  pname = "librespot";
  version = "0.0.10";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "kokarare1212";
    repo = "librespot-python";
    tag = "v${version}";
    hash = "sha256-VjVPrWttOYfWsxzZpRgpZVenmP0y9Fea6Bhv9U8BO9U=";
  };

  env.PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION = "python";

  pythonRelaxDeps = true;

  build-system = [ setuptools ];

  dependencies = [
    defusedxml
    protobuf
    pycryptodomex
    pyogg
    requests
    websocket-client
    zeroconf
  ];

  # Doesn't include any tests
  doCheck = false;

  pythonImportsCheck = [ "librespot" ];

  meta = {
    description = "Open Source Spotify Client";
    homepage = "https://github.com/kokarare1212/librespot-python";
    changelog = "https://github.com/kokarare1212/librespot-python/releases/tag/v${version}";
    license = lib.licenses.asl20;
    maintainers = with lib.maintainers; [ onny ];
  };
}