From a1376da76686c6f1b570af783ea424854d2fd198 Mon Sep 17 00:00:00 2001 From: CoprDistGit Date: Tue, 20 Jun 2023 04:07:48 +0000 Subject: automatic import of python-manganelo --- .gitignore | 1 + python-manganelo.spec | 173 ++++++++++++++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 175 insertions(+) create mode 100644 python-manganelo.spec create mode 100644 sources diff --git a/.gitignore b/.gitignore index e69de29..ff55e1b 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/manganelo-1.23.tar.gz diff --git a/python-manganelo.spec b/python-manganelo.spec new file mode 100644 index 0000000..eab9471 --- /dev/null +++ b/python-manganelo.spec @@ -0,0 +1,173 @@ +%global _empty_manifest_terminate_build 0 +Name: python-manganelo +Version: 1.23 +Release: 1 +Summary: Unofficial API for the Manganelo/Manganato website. +License: MIT +URL: https://github.com/nixonjoshua98/manganelo +Source0: https://mirrors.aliyun.com/pypi/web/packages/b2/8d/951b110dbf9a47733703816bc082a92236b51720bddb75b82a4e9627fcbc/manganelo-1.23.tar.gz +BuildArch: noarch + +Requires: python3-bs4 +Requires: python3-requests +Requires: python3-reportlab +Requires: python3-pillow +Requires: python3-pydantic + +%description +[![Downloads](https://pepy.tech/badge/manganelo)](https://pepy.tech/project/manganelo) [![Downloads](https://pepy.tech/badge/manganelo/month)](https://pepy.tech/project/manganelo/month) [![Downloads](https://pepy.tech/badge/manganelo/week)](https://pepy.tech/project/manganelo/week) + +# Unofficial Manganelo (Manganato) API + +Installation +- +**Python 3.7+ (latest version requires Python 3.9+)** +```cmd +pip install manganelo +``` + +Examples +- +```python +import manganelo + +home_page = manganelo.get_home_page() + +results = manganelo.get_search_results("Naruto") + +for r in results: + print(r.title, r.views) + + chapters = r.chapter_list + + icon_path = r.download_icon("./icon.png") + + for c in chapters: + print(f"#{c.chapter} | {c.title}") + + chapter_path = c.download(f"./Chapter {c.chapter}.pdf") +``` + + +%package -n python3-manganelo +Summary: Unofficial API for the Manganelo/Manganato website. +Provides: python-manganelo +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-manganelo +[![Downloads](https://pepy.tech/badge/manganelo)](https://pepy.tech/project/manganelo) [![Downloads](https://pepy.tech/badge/manganelo/month)](https://pepy.tech/project/manganelo/month) [![Downloads](https://pepy.tech/badge/manganelo/week)](https://pepy.tech/project/manganelo/week) + +# Unofficial Manganelo (Manganato) API + +Installation +- +**Python 3.7+ (latest version requires Python 3.9+)** +```cmd +pip install manganelo +``` + +Examples +- +```python +import manganelo + +home_page = manganelo.get_home_page() + +results = manganelo.get_search_results("Naruto") + +for r in results: + print(r.title, r.views) + + chapters = r.chapter_list + + icon_path = r.download_icon("./icon.png") + + for c in chapters: + print(f"#{c.chapter} | {c.title}") + + chapter_path = c.download(f"./Chapter {c.chapter}.pdf") +``` + + +%package help +Summary: Development documents and examples for manganelo +Provides: python3-manganelo-doc +%description help +[![Downloads](https://pepy.tech/badge/manganelo)](https://pepy.tech/project/manganelo) [![Downloads](https://pepy.tech/badge/manganelo/month)](https://pepy.tech/project/manganelo/month) [![Downloads](https://pepy.tech/badge/manganelo/week)](https://pepy.tech/project/manganelo/week) + +# Unofficial Manganelo (Manganato) API + +Installation +- +**Python 3.7+ (latest version requires Python 3.9+)** +```cmd +pip install manganelo +``` + +Examples +- +```python +import manganelo + +home_page = manganelo.get_home_page() + +results = manganelo.get_search_results("Naruto") + +for r in results: + print(r.title, r.views) + + chapters = r.chapter_list + + icon_path = r.download_icon("./icon.png") + + for c in chapters: + print(f"#{c.chapter} | {c.title}") + + chapter_path = c.download(f"./Chapter {c.chapter}.pdf") +``` + + +%prep +%autosetup -n manganelo-1.23 + +%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-manganelo -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Tue Jun 20 2023 Python_Bot - 1.23-1 +- Package Spec generated diff --git a/sources b/sources new file mode 100644 index 0000000..34f69e0 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +95ce6202d174cfb62a52fb0cc77e4c6d manganelo-1.23.tar.gz -- cgit v1.2.3