yt-dlp: use PyPI tarball
This commit is contained in:
parent
8cc518e2a1
commit
1f2818d65d
|
@ -1,12 +1,11 @@
|
||||||
{ lib, buildPythonPackage
|
{ lib, buildPythonPackage, fetchPypi
|
||||||
, zip, ffmpeg, rtmpdump, phantomjs2, atomicparsley, pycryptodome, pandoc
|
, ffmpeg, rtmpdump, phantomjs2, atomicparsley, pycryptodome
|
||||||
, fetchFromGitHub
|
|
||||||
, websockets, mutagen
|
, websockets, mutagen
|
||||||
, ffmpegSupport ? true
|
, ffmpegSupport ? true
|
||||||
, rtmpSupport ? true
|
, rtmpSupport ? true
|
||||||
, phantomjsSupport ? false
|
, phantomjsSupport ? false
|
||||||
, hlsEncryptedSupport ? true
|
, hlsEncryptedSupport ? true
|
||||||
, installShellFiles, makeWrapper }:
|
}:
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
pname = "yt-dlp";
|
pname = "yt-dlp";
|
||||||
|
@ -15,15 +14,18 @@ buildPythonPackage rec {
|
||||||
# to the latest stable release.
|
# to the latest stable release.
|
||||||
version = "2021.08.10";
|
version = "2021.08.10";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchPypi {
|
||||||
owner = "yt-dlp";
|
inherit pname;
|
||||||
repo = "yt-dlp";
|
version = builtins.replaceStrings [ ".0" ] [ "." ] version;
|
||||||
rev = version;
|
sha256 = "8da1bf4dc4641d37d137443c4783109ee8393caad5e0d270d9d1d534e8f25240";
|
||||||
sha256 = "sha256-8mOjIvbC3AFHCXKV5G66cFy7SM7sULzM8czXcqQKbms=";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ installShellFiles makeWrapper ];
|
# build_lazy_extractors assumes this directory exists but it is not present in
|
||||||
buildInputs = [ zip pandoc ];
|
# the PyPI package
|
||||||
|
postPatch = ''
|
||||||
|
mkdir -p ytdlp_plugins/extractor
|
||||||
|
'';
|
||||||
|
|
||||||
propagatedBuildInputs = [ websockets mutagen ]
|
propagatedBuildInputs = [ websockets mutagen ]
|
||||||
++ lib.optional hlsEncryptedSupport pycryptodome;
|
++ lib.optional hlsEncryptedSupport pycryptodome;
|
||||||
|
|
||||||
|
@ -48,6 +50,7 @@ buildPythonPackage rec {
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
homepage = "https://github.com/yt-dlp/yt-dlp/";
|
homepage = "https://github.com/yt-dlp/yt-dlp/";
|
||||||
description = "Command-line tool to download videos from YouTube.com and other sites (youtube-dl fork)";
|
description = "Command-line tool to download videos from YouTube.com and other sites (youtube-dl fork)";
|
||||||
|
changelog = "https://github.com/yt-dlp/yt-dlp/raw/${version}/Changelog.md";
|
||||||
longDescription = ''
|
longDescription = ''
|
||||||
yt-dlp is a youtube-dl fork based on the now inactive youtube-dlc.
|
yt-dlp is a youtube-dl fork based on the now inactive youtube-dlc.
|
||||||
|
|
||||||
|
@ -56,7 +59,7 @@ buildPythonPackage rec {
|
||||||
youtube-dl is released to the public domain, which means
|
youtube-dl is released to the public domain, which means
|
||||||
you can modify it, redistribute it or use it however you like.
|
you can modify it, redistribute it or use it however you like.
|
||||||
'';
|
'';
|
||||||
license = licenses.publicDomain;
|
license = licenses.unlicense;
|
||||||
maintainers = with maintainers; [ mkg20001 ];
|
maintainers = with maintainers; [ mkg20001 ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue