2022-11-21 17:40:18 +00:00
|
|
|
{ lib
|
|
|
|
, python3
|
2024-02-07 01:22:34 +00:00
|
|
|
, fetchFromGitHub
|
2022-11-21 17:40:18 +00:00
|
|
|
, mopidy
|
|
|
|
}:
|
2021-10-01 09:20:50 +00:00
|
|
|
|
2023-05-24 13:37:59 +00:00
|
|
|
let
|
2024-02-07 01:22:34 +00:00
|
|
|
python = python3;
|
2023-05-24 13:37:59 +00:00
|
|
|
in python.pkgs.buildPythonApplication rec {
|
2021-10-01 09:20:50 +00:00
|
|
|
pname = "mopidy-ytmusic";
|
2024-02-07 01:22:34 +00:00
|
|
|
version = "0.3.9";
|
|
|
|
pyproject = true;
|
2021-10-01 09:20:50 +00:00
|
|
|
|
2024-02-07 01:22:34 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "jmcdo29";
|
|
|
|
repo = "mopidy-ytmusic";
|
|
|
|
rev = "v${version}";
|
|
|
|
hash = "sha256-2o4fDtaIxRDvIiAGV/9qK/00BmYXasBUwW03fxFcDAU=";
|
2021-10-01 09:20:50 +00:00
|
|
|
};
|
|
|
|
|
2024-02-07 01:22:34 +00:00
|
|
|
postPatch = ''
|
|
|
|
# only setup.py has up to date dependencies
|
|
|
|
rm pyproject.toml
|
|
|
|
'';
|
|
|
|
|
|
|
|
nativeBuildInputs = with python.pkgs; [
|
|
|
|
setuptools
|
|
|
|
];
|
|
|
|
|
2021-10-01 09:20:50 +00:00
|
|
|
propagatedBuildInputs = [
|
2023-05-24 13:37:59 +00:00
|
|
|
(mopidy.override { pythonPackages = python.pkgs; })
|
|
|
|
python.pkgs.ytmusicapi
|
|
|
|
python.pkgs.pytube
|
2021-10-01 09:20:50 +00:00
|
|
|
];
|
|
|
|
|
2022-03-30 09:31:56 +00:00
|
|
|
pythonImportsCheck = [ "mopidy_ytmusic" ];
|
|
|
|
|
|
|
|
# has no tests
|
2021-10-01 09:20:50 +00:00
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = with lib; {
|
2024-02-07 01:22:34 +00:00
|
|
|
changelog = "https://github.com/jmcdo29/mopidy-ytmusic/releases/tag/${src.rev}";
|
2021-10-01 09:20:50 +00:00
|
|
|
description = "Mopidy extension for playing music from YouTube Music";
|
2024-02-07 01:22:34 +00:00
|
|
|
homepage = "https://github.com/jmcdo29/mopidy-ytmusic";
|
2021-10-01 09:20:50 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = [ maintainers.nickhu ];
|
|
|
|
};
|
|
|
|
}
|