2021-02-05 17:12:51 +00:00
|
|
|
{ stdenv, lib, fetchFromGitHub, buildPerlPackage, shortenPerlShebang, LWP, LWPProtocolHttps, DataDump, JSON }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPerlPackage rec {
|
|
|
|
pname = "WWW-YoutubeViewer";
|
2020-10-07 09:15:18 +00:00
|
|
|
version = "3.7.9";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "trizen";
|
|
|
|
repo = "youtube-viewer";
|
|
|
|
rev = version;
|
2020-10-07 09:15:18 +00:00
|
|
|
sha256 = "16p0sa91h0zpqdpqmy348g6b9qj5f6qrbzrljn157vk00cg6mx18";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
nativeBuildInputs = lib.optional stdenv.isDarwin shortenPerlShebang;
|
2020-04-24 23:36:52 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
LWP
|
|
|
|
LWPProtocolHttps
|
|
|
|
DataDump
|
|
|
|
JSON
|
|
|
|
];
|
2021-02-05 17:12:51 +00:00
|
|
|
postInstall = lib.optionalString stdenv.isDarwin ''
|
2020-04-24 23:36:52 +00:00
|
|
|
shortenPerlShebang $out/bin/youtube-viewer
|
|
|
|
'';
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A lightweight application for searching and streaming videos from YouTube";
|
|
|
|
homepage = "https://github.com/trizen/youtube-viewer";
|
2021-02-05 17:12:51 +00:00
|
|
|
license = with licenses; [ artistic2 ];
|
2022-06-26 10:26:21 +00:00
|
|
|
maintainers = with maintainers; [ woffs ];
|
|
|
|
mainProgram = "youtube-viewer";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|