2019-08-09 00:05:54 +01:00
|
|
|
{ lib, buildPythonPackage, fetchFromGitHub, isPy3k
|
2018-10-29 18:59:01 +00:00
|
|
|
, pafy
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2019-08-09 00:05:54 +01:00
|
|
|
pname = "mps-youtube";
|
|
|
|
version = "0.2.8";
|
2018-10-29 18:59:01 +00:00
|
|
|
disabled = (!isPy3k);
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "mps-youtube";
|
|
|
|
repo = "mps-youtube";
|
|
|
|
rev = "v${version}";
|
2019-08-09 00:05:54 +01:00
|
|
|
sha256 = "1w1jhw9rg3dx7vp97cwrk5fymipkcy2wrbl1jaa38ivcjhqg596y";
|
2018-10-29 18:59:01 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ pafy ];
|
|
|
|
|
|
|
|
# disabled due to error in loading unittest
|
|
|
|
# don't know how to make test from: <mps_youtube. ...>
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
# before check create a directory and redirect XDG_CONFIG_HOME to it
|
|
|
|
preCheck = ''
|
|
|
|
mkdir -p check-phase
|
|
|
|
export XDG_CONFIG_HOME=$(pwd)/check-phase
|
|
|
|
'';
|
|
|
|
|
2019-08-09 00:05:54 +01:00
|
|
|
meta = with lib; {
|
2018-10-29 18:59:01 +00:00
|
|
|
description = "Terminal based YouTube player and downloader";
|
|
|
|
homepage = https://github.com/np1/mps-youtube;
|
|
|
|
license = licenses.gpl3;
|
|
|
|
maintainers = with maintainers; [ odi ];
|
|
|
|
};
|
|
|
|
}
|