diff options
author | CoprDistGit <infra@openeuler.org> | 2023-05-05 09:48:58 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2023-05-05 09:48:58 +0000 |
commit | 9060b6180050d01370573b589795617706ddd9ac (patch) | |
tree | 332387f34a0305a4404528afc47ff5c5a9bfe510 | |
parent | 1358c7a0d15f901d51fb26dcdcac4394431e19aa (diff) |
automatic import of python-npytdlopeneuler20.03
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | python-npytdl.spec | 169 | ||||
-rw-r--r-- | sources | 1 |
3 files changed, 171 insertions, 0 deletions
@@ -0,0 +1 @@ +/NPytdl-4.1.2.tar.gz diff --git a/python-npytdl.spec b/python-npytdl.spec new file mode 100644 index 0000000..35fe9c9 --- /dev/null +++ b/python-npytdl.spec @@ -0,0 +1,169 @@ +%global _empty_manifest_terminate_build 0 +Name: python-NPytdl +Version: 4.1.2 +Release: 1 +Summary: a new youtube_dl +License: MIT License +URL: https://github.com/rexwu1104/Pytdl +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/d2/3d/44b663ef596f7bc2afb85fd048b01eec1729caf618e0d39c01df5e2bc462/NPytdl-4.1.2.tar.gz +BuildArch: noarch + +Requires: python3-youtube-dl +Requires: python3-bs4 +Requires: python3-orjson +Requires: python3-spotipy + +%description +# Pytdl (NPytdl) + +*** + +We have nine methods for `Pytdl` class + +| method | return | +| :-----: | :-----: | +| `resultList(query : str)` | json | +| `spotifyResultList(query : str)` | json | +| `playList(list_id : str)` | json | +| `spotifyPlayList(list_id : str)` | json | +| `resultsList(querys : List[str])` | json | +| `spotifyResultsList(querys : List[str])` | json | +| `next(id : str)` | json | +| `spotifyTrack(id : str)` | json | +| `info(url : str)` | YoutubeVideos \| YoutubeVideo \| SpotifyMusics \| SpotifyMusic | + +```py +from NPytdl import Pytdl +ydl = Pytdl() + +song = ydl.info("https://youtu.be/RGtSdbjxVKU") + +import asyncio +asyncio.run(song.create()) + +song.download(f"./test/{song.title}") +``` + + + + +%package -n python3-NPytdl +Summary: a new youtube_dl +Provides: python-NPytdl +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-NPytdl +# Pytdl (NPytdl) + +*** + +We have nine methods for `Pytdl` class + +| method | return | +| :-----: | :-----: | +| `resultList(query : str)` | json | +| `spotifyResultList(query : str)` | json | +| `playList(list_id : str)` | json | +| `spotifyPlayList(list_id : str)` | json | +| `resultsList(querys : List[str])` | json | +| `spotifyResultsList(querys : List[str])` | json | +| `next(id : str)` | json | +| `spotifyTrack(id : str)` | json | +| `info(url : str)` | YoutubeVideos \| YoutubeVideo \| SpotifyMusics \| SpotifyMusic | + +```py +from NPytdl import Pytdl +ydl = Pytdl() + +song = ydl.info("https://youtu.be/RGtSdbjxVKU") + +import asyncio +asyncio.run(song.create()) + +song.download(f"./test/{song.title}") +``` + + + + +%package help +Summary: Development documents and examples for NPytdl +Provides: python3-NPytdl-doc +%description help +# Pytdl (NPytdl) + +*** + +We have nine methods for `Pytdl` class + +| method | return | +| :-----: | :-----: | +| `resultList(query : str)` | json | +| `spotifyResultList(query : str)` | json | +| `playList(list_id : str)` | json | +| `spotifyPlayList(list_id : str)` | json | +| `resultsList(querys : List[str])` | json | +| `spotifyResultsList(querys : List[str])` | json | +| `next(id : str)` | json | +| `spotifyTrack(id : str)` | json | +| `info(url : str)` | YoutubeVideos \| YoutubeVideo \| SpotifyMusics \| SpotifyMusic | + +```py +from NPytdl import Pytdl +ydl = Pytdl() + +song = ydl.info("https://youtu.be/RGtSdbjxVKU") + +import asyncio +asyncio.run(song.create()) + +song.download(f"./test/{song.title}") +``` + + + + +%prep +%autosetup -n NPytdl-4.1.2 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-NPytdl -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Fri May 05 2023 Python_Bot <Python_Bot@openeuler.org> - 4.1.2-1 +- Package Spec generated @@ -0,0 +1 @@ +2d88719cf1c8192233b80de8a49937b8 NPytdl-4.1.2.tar.gz |