mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-22 06:05:13 +00:00
53 lines
933 B
Nix
53 lines
933 B
Nix
{ lib
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, graphviz
|
|
, ifaddr
|
|
, pythonOlder
|
|
, mock
|
|
, nix-update-script
|
|
, pytestCheckHook
|
|
, requests
|
|
, requests-mock
|
|
, xmltodict
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "soco";
|
|
version = "0.24.1";
|
|
disabled = pythonOlder "3.6";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "SoCo";
|
|
repo = "SoCo";
|
|
rev = "v${version}";
|
|
sha256 = "sha256-78JYetA6msGiLMHNTdTN2b5lOiXaY+TQA9ID8qtPmM0=";
|
|
};
|
|
|
|
propagatedBuildInputs = [
|
|
ifaddr
|
|
requests
|
|
xmltodict
|
|
];
|
|
|
|
checkInputs = [
|
|
pytestCheckHook
|
|
graphviz
|
|
mock
|
|
requests-mock
|
|
];
|
|
|
|
pythonImportsCheck = [ "soco" ];
|
|
|
|
passthru.updateScript = nix-update-script {
|
|
attrPath = "python3Packages.${pname}";
|
|
};
|
|
|
|
meta = with lib; {
|
|
homepage = "http://python-soco.com/";
|
|
description = "A CLI and library to control Sonos speakers";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ lovesegfault ];
|
|
};
|
|
}
|