diff options
author | CoprDistGit <copr-devel@lists.fedorahosted.org> | 2023-02-24 10:18:11 +0000 |
---|---|---|
committer | CoprDistGit <copr-devel@lists.fedorahosted.org> | 2023-02-24 10:18:11 +0000 |
commit | b3b31ae91ac131d4ab18f8274f1c64410932210d (patch) | |
tree | 695508908c8e57b14fbb16d02c71b99dcd5fd923 | |
parent | 8bcd6daecc5a8c7e4ce2cbe56f391f7d1970d0a5 (diff) |
automatic import of python3-epson-projectoropeneuler20.03
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | python-epson-projector.spec | 185 | ||||
-rw-r--r-- | sources | 1 |
3 files changed, 187 insertions, 0 deletions
@@ -0,0 +1 @@ +/epson_projector-0.5.0.tar.gz diff --git a/python-epson-projector.spec b/python-epson-projector.spec new file mode 100644 index 0000000..48a81c1 --- /dev/null +++ b/python-epson-projector.spec @@ -0,0 +1,185 @@ +%global _empty_manifest_terminate_build 0 +Name: python-epson-projector +Version: 0.5.0 +Release: 1 +Summary: Epson projector support for Python +License: MIT +URL: https://github.com/pszafer/epson_projector +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/26/4c/70d8f13492095c48ba640f246ce2e1fdb57e0c7cae89aa31fbf7e80efe0b/epson_projector-0.5.0.tar.gz +BuildArch: noarch + +Requires: python3-aiohttp +Requires: python3-pyserial-asyncio +Requires: python3-async-timeout + +%description +# Epson-projector module +## Asynchronous library to control epson projectors + +Requires Python 3.5. asyncio, aiohttp. + +Created mostly to use with Home Assistant. + +### Usage + +Check out test.py and const.py to see all posibilities to send to projector. + +```python +"""Test and example of usage of Epson module.""" +import epson_projector as epson +from epson_projector.const import (POWER) + +import asyncio +import aiohttp + + +async def main(): + """Run main with aiohttp ClientSession.""" + async with aiohttp.ClientSession() as session: + await run(session) + + +async def run(websession): + """Use Projector class of epson module and check if it is turned on.""" + projector = epson.Projector( + host='HOSTNAME', + websession=websession, + encryption=False) + data = await projector.get_property(POWER) + print(data) + +asyncio.get_event_loop().run_until_complete(main()) +``` + + +%package -n python3-epson-projector +Summary: Epson projector support for Python +Provides: python-epson-projector +BuildRequires: python3-devel +BuildRequires: python3-setuptools +%description -n python3-epson-projector +# Epson-projector module +## Asynchronous library to control epson projectors + +Requires Python 3.5. asyncio, aiohttp. + +Created mostly to use with Home Assistant. + +### Usage + +Check out test.py and const.py to see all posibilities to send to projector. + +```python +"""Test and example of usage of Epson module.""" +import epson_projector as epson +from epson_projector.const import (POWER) + +import asyncio +import aiohttp + + +async def main(): + """Run main with aiohttp ClientSession.""" + async with aiohttp.ClientSession() as session: + await run(session) + + +async def run(websession): + """Use Projector class of epson module and check if it is turned on.""" + projector = epson.Projector( + host='HOSTNAME', + websession=websession, + encryption=False) + data = await projector.get_property(POWER) + print(data) + +asyncio.get_event_loop().run_until_complete(main()) +``` + + +%package help +Summary: Development documents and examples for epson-projector +Provides: python3-epson-projector-doc +%description help +# Epson-projector module +## Asynchronous library to control epson projectors + +Requires Python 3.5. asyncio, aiohttp. + +Created mostly to use with Home Assistant. + +### Usage + +Check out test.py and const.py to see all posibilities to send to projector. + +```python +"""Test and example of usage of Epson module.""" +import epson_projector as epson +from epson_projector.const import (POWER) + +import asyncio +import aiohttp + + +async def main(): + """Run main with aiohttp ClientSession.""" + async with aiohttp.ClientSession() as session: + await run(session) + + +async def run(websession): + """Use Projector class of epson module and check if it is turned on.""" + projector = epson.Projector( + host='HOSTNAME', + websession=websession, + encryption=False) + data = await projector.get_property(POWER) + print(data) + +asyncio.get_event_loop().run_until_complete(main()) +``` + + +%prep +%autosetup -n epson-projector-0.5.0 + +%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-epson-projector -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Fri Feb 24 2023 Python_Bot <Python_Bot@openeuler.org> - 0.5.0-1 +- Package Spec generated @@ -0,0 +1 @@ +441b3508e1c22c96af6c7b2970a35a61 epson_projector-0.5.0.tar.gz |