diff options
author | CoprDistGit <infra@openeuler.org> | 2023-05-31 04:04:16 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2023-05-31 04:04:16 +0000 |
commit | 49e8d41390c972fec475064e33cc969088dbc694 (patch) | |
tree | cec7a00463a86904e7adede2dd52c2a20062b128 /python-pnq.spec | |
parent | 99b818f0ae8754c895f017aadb954361e774a6fc (diff) |
automatic import of python-pnq
Diffstat (limited to 'python-pnq.spec')
-rw-r--r-- | python-pnq.spec | 225 |
1 files changed, 225 insertions, 0 deletions
diff --git a/python-pnq.spec b/python-pnq.spec new file mode 100644 index 0000000..29f3d3c --- /dev/null +++ b/python-pnq.spec @@ -0,0 +1,225 @@ +%global _empty_manifest_terminate_build 0 +Name: python-pnq +Version: 0.0.21 +Release: 1 +Summary: please add a summary manually as the author left a blank one +License: MIT +URL: https://github.com/sasano8/pnq +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/35/a7/e9a386298769ef8c77e647d194a821b4e3612e19f35a8498d1531d4852d0/pnq-0.0.21.tar.gz +BuildArch: noarch + + +%description +## Features +- コレクション操作に関する多彩な操作 +- アクセシブルなインタフェース +- 型ヒントの活用 +- 非同期ストリームに対応 +## Similar tools +- [PyFunctional](https://github.com/EntilZha/PyFunctional) +- [linqit](https://github.com/avilum/linqit) +- [python-linq](https://github.com/jakkes/python-linq) +- [aioitertools](https://github.com/omnilib/aioitertools) +- [asyncstdlib](https://github.com/maxfischer2781/asyncstdlib) +- [asq](https://github.com/sixty-north/asq) +## Documentation +- See [documentation](https://sasano8.github.io/pnq/) for more details. +## Dependencies +- Python 3.8+ +## Installation +Install with pip: +```shell +$ pip install pnq +``` +## Getting Started +``` python +import pnq +for x in pnq.query([1, 2, 3]).map(lambda x: x * 2): + print(x) +# => 2, 4, 6 +pnq.query([1, 2, 3]).map(lambda x: x * 2).result() +# => [2, 4, 6] +pnq.query([1, 2, 3]).filter(lambda x: x == 3).one() +# => 2 +``` +``` python +import asyncio +import pnq +async def aiter(): + yield 1 + yield 2 + yield 3 +async def main(): + async for x in pnq.query(aiter()).map(lambda x: x * 2): + print(x) + # => 2, 4, 6 + await pnq.query(aiter()).map(lambda x: x * 2) + # => [2, 4, 6] + await pnq.query(aiter()).filter(lambda x: x == 3)._.one() + # => 3 +asyncio.run(main()) +``` +## release note +### v0.0.1 (2021-xx-xx) +* Initial release. + +%package -n python3-pnq +Summary: please add a summary manually as the author left a blank one +Provides: python-pnq +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-pnq +## Features +- コレクション操作に関する多彩な操作 +- アクセシブルなインタフェース +- 型ヒントの活用 +- 非同期ストリームに対応 +## Similar tools +- [PyFunctional](https://github.com/EntilZha/PyFunctional) +- [linqit](https://github.com/avilum/linqit) +- [python-linq](https://github.com/jakkes/python-linq) +- [aioitertools](https://github.com/omnilib/aioitertools) +- [asyncstdlib](https://github.com/maxfischer2781/asyncstdlib) +- [asq](https://github.com/sixty-north/asq) +## Documentation +- See [documentation](https://sasano8.github.io/pnq/) for more details. +## Dependencies +- Python 3.8+ +## Installation +Install with pip: +```shell +$ pip install pnq +``` +## Getting Started +``` python +import pnq +for x in pnq.query([1, 2, 3]).map(lambda x: x * 2): + print(x) +# => 2, 4, 6 +pnq.query([1, 2, 3]).map(lambda x: x * 2).result() +# => [2, 4, 6] +pnq.query([1, 2, 3]).filter(lambda x: x == 3).one() +# => 2 +``` +``` python +import asyncio +import pnq +async def aiter(): + yield 1 + yield 2 + yield 3 +async def main(): + async for x in pnq.query(aiter()).map(lambda x: x * 2): + print(x) + # => 2, 4, 6 + await pnq.query(aiter()).map(lambda x: x * 2) + # => [2, 4, 6] + await pnq.query(aiter()).filter(lambda x: x == 3)._.one() + # => 3 +asyncio.run(main()) +``` +## release note +### v0.0.1 (2021-xx-xx) +* Initial release. + +%package help +Summary: Development documents and examples for pnq +Provides: python3-pnq-doc +%description help +## Features +- コレクション操作に関する多彩な操作 +- アクセシブルなインタフェース +- 型ヒントの活用 +- 非同期ストリームに対応 +## Similar tools +- [PyFunctional](https://github.com/EntilZha/PyFunctional) +- [linqit](https://github.com/avilum/linqit) +- [python-linq](https://github.com/jakkes/python-linq) +- [aioitertools](https://github.com/omnilib/aioitertools) +- [asyncstdlib](https://github.com/maxfischer2781/asyncstdlib) +- [asq](https://github.com/sixty-north/asq) +## Documentation +- See [documentation](https://sasano8.github.io/pnq/) for more details. +## Dependencies +- Python 3.8+ +## Installation +Install with pip: +```shell +$ pip install pnq +``` +## Getting Started +``` python +import pnq +for x in pnq.query([1, 2, 3]).map(lambda x: x * 2): + print(x) +# => 2, 4, 6 +pnq.query([1, 2, 3]).map(lambda x: x * 2).result() +# => [2, 4, 6] +pnq.query([1, 2, 3]).filter(lambda x: x == 3).one() +# => 2 +``` +``` python +import asyncio +import pnq +async def aiter(): + yield 1 + yield 2 + yield 3 +async def main(): + async for x in pnq.query(aiter()).map(lambda x: x * 2): + print(x) + # => 2, 4, 6 + await pnq.query(aiter()).map(lambda x: x * 2) + # => [2, 4, 6] + await pnq.query(aiter()).filter(lambda x: x == 3)._.one() + # => 3 +asyncio.run(main()) +``` +## release note +### v0.0.1 (2021-xx-xx) +* Initial release. + +%prep +%autosetup -n pnq-0.0.21 + +%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-pnq -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Wed May 31 2023 Python_Bot <Python_Bot@openeuler.org> - 0.0.21-1 +- Package Spec generated |