From 4c6248c35945be84ecdaa1dbd4e024d1d11fe37b Mon Sep 17 00:00:00 2001 From: Nicola Vitale Date: Mon, 4 Nov 2024 15:06:20 +0100 Subject: [PATCH] www/py-youtube-transcript-api: Add new port Youtube-transcript-api is a python API which allows you to retrieve the transcript/subtitles for a given YouTube video. It also works for automatically generated subtitles, supports translating subtitles and it does not require a headless browser, like other selenium based solutions do! https://github.com/jdepoix/youtube-transcript-api --- www/Makefile | 1 + www/py-youtube-transcript-api/Makefile | 20 ++++++++++++++++++++ www/py-youtube-transcript-api/distinfo | 3 +++ www/py-youtube-transcript-api/pkg-descr | 4 ++++ 4 files changed, 28 insertions(+) create mode 100644 www/py-youtube-transcript-api/Makefile create mode 100644 www/py-youtube-transcript-api/distinfo create mode 100644 www/py-youtube-transcript-api/pkg-descr diff --git a/www/Makefile b/www/Makefile index 9de05fb300f5..24e3d3935fa8 100644 --- a/www/Makefile +++ b/www/Makefile @@ -1898,6 +1898,7 @@ SUBDIR += py-xandikos SUBDIR += py-xyzservices SUBDIR += py-yarl + SUBDIR += py-youtube-transcript-api SUBDIR += py-yt-dlp SUBDIR += pydio-cells SUBDIR += qdecoder diff --git a/www/py-youtube-transcript-api/Makefile b/www/py-youtube-transcript-api/Makefile new file mode 100644 index 000000000000..eec5b2c1daac --- /dev/null +++ b/www/py-youtube-transcript-api/Makefile @@ -0,0 +1,20 @@ +PORTNAME= youtube-transcript-api +DISTVERSION= 0.6.2 +CATEGORIES= www python +MASTER_SITES= PYPI +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} +DISTNAME= ${PORTNAME:S/-/_/g}-${DISTVERSIONFULL} + +MAINTAINER= nivit@FreeBSD.org +COMMENT= Python module for YouTube Transcript/Subtitle API +WWW= https://github.com/jdepoix/youtube-transcript-api + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}requests>=2.32.3:www/py-requests@${PY_FLAVOR} + +USES= python +USE_PYTHON= autoplist distutils + +.include diff --git a/www/py-youtube-transcript-api/distinfo b/www/py-youtube-transcript-api/distinfo new file mode 100644 index 000000000000..4430d7d30738 --- /dev/null +++ b/www/py-youtube-transcript-api/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1730707696 +SHA256 (youtube_transcript_api-0.6.2.tar.gz) = cad223d7620633cec44f657646bffc8bbc5598bd8e70b1ad2fa8277dec305eb7 +SIZE (youtube_transcript_api-0.6.2.tar.gz) = 24565 diff --git a/www/py-youtube-transcript-api/pkg-descr b/www/py-youtube-transcript-api/pkg-descr new file mode 100644 index 000000000000..17a68e56990f --- /dev/null +++ b/www/py-youtube-transcript-api/pkg-descr @@ -0,0 +1,4 @@ +Youtube-transcript-api is a Python API which allows you to retrieve the +transcript/subtitles for a given YouTube video. It also works for automatically +generated subtitles, supports translating subtitles and it does not require a +headless browser, like other selenium based solutions do!