From b3242473c5334c17a88e415c32d130474fdad118 Mon Sep 17 00:00:00 2001 From: CoprDistGit Date: Mon, 15 May 2023 04:19:38 +0000 Subject: automatic import of python-pycoolmasternet-async --- .gitignore | 1 + python-pycoolmasternet-async.spec | 261 ++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 263 insertions(+) create mode 100644 python-pycoolmasternet-async.spec create mode 100644 sources diff --git a/.gitignore b/.gitignore index e69de29..9979aa2 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/pycoolmasternet-async-0.1.6.tar.gz diff --git a/python-pycoolmasternet-async.spec b/python-pycoolmasternet-async.spec new file mode 100644 index 0000000..4c84591 --- /dev/null +++ b/python-pycoolmasternet-async.spec @@ -0,0 +1,261 @@ +%global _empty_manifest_terminate_build 0 +Name: python-pycoolmasternet-async +Version: 0.1.6 +Release: 1 +Summary: A python library to control CoolMasterNet HVAC bridges over asyncio. +License: MIT +URL: https://github.com/OnFreund/pycoolmasternet-async +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/32/c5/38267ec08a8ae81a845dc35d81074d83aa46ffef9636fe5c73e9684c6c9c/pycoolmasternet-async-0.1.6.tar.gz +BuildArch: noarch + + +%description + +# pycoolmasternet-async + +A Python 3 library for interacting with a [CoolMasterNet](https://coolautomation.com/products/coolmasternet/) HVAC bridge. +This is a fork of [pycoolmaster](https://github.com/koreth/pycoolmasternet), modified to present an async interface and some other small changes. + +## Installation + +You can install pycoolmasternet-async from [PyPI](https://pypi.org/project/pycoolmasternet-async/): + + pip3 install pycoolmasternet-async + +Python 3.7 and above are supported. + + +## How to use + +```python +from pycoolmasternet_async import CoolMasterNet +cool = CoolMasterNet("coolmaster") + +# Supply the IP address and optional port number (default 10102). +cool = CoolMasterNet("192.168.0.123", port=12345, read_timeout=1) + +# General information +info = await cool.info() + +# Returns a dict of CoolMasterNetUnit objects. Keys are the unit IDs +units = await cool.status() + +unit = units["L1.001"] + +unit.unit_id + +# Temperature unit: Imperial, Celsius +unit.temperature_unit + +# Current reading of unit's thermometer +unit.temperature + +# Current setting of unit's thermostat +unit.thermostat + +# Setters return a new instance with updated info +unit = await unit.set_thermostat(28) + +# True if unit is turned on +unit.is_on +unit = await unit.turn_on() +unit = await unit.turn_off() + +# Fan speed: low, med, high, auto +unit.fan_speed +unit = await unit.set_fan_speed('med') + +# Mode of operation: auto, cool, dry, fan, heat +unit.mode +unit = await unit.set_mode('cool') + +# Get fresh info +unit = await unit.refresh() + +``` + + +%package -n python3-pycoolmasternet-async +Summary: A python library to control CoolMasterNet HVAC bridges over asyncio. +Provides: python-pycoolmasternet-async +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-pycoolmasternet-async + +# pycoolmasternet-async + +A Python 3 library for interacting with a [CoolMasterNet](https://coolautomation.com/products/coolmasternet/) HVAC bridge. +This is a fork of [pycoolmaster](https://github.com/koreth/pycoolmasternet), modified to present an async interface and some other small changes. + +## Installation + +You can install pycoolmasternet-async from [PyPI](https://pypi.org/project/pycoolmasternet-async/): + + pip3 install pycoolmasternet-async + +Python 3.7 and above are supported. + + +## How to use + +```python +from pycoolmasternet_async import CoolMasterNet +cool = CoolMasterNet("coolmaster") + +# Supply the IP address and optional port number (default 10102). +cool = CoolMasterNet("192.168.0.123", port=12345, read_timeout=1) + +# General information +info = await cool.info() + +# Returns a dict of CoolMasterNetUnit objects. Keys are the unit IDs +units = await cool.status() + +unit = units["L1.001"] + +unit.unit_id + +# Temperature unit: Imperial, Celsius +unit.temperature_unit + +# Current reading of unit's thermometer +unit.temperature + +# Current setting of unit's thermostat +unit.thermostat + +# Setters return a new instance with updated info +unit = await unit.set_thermostat(28) + +# True if unit is turned on +unit.is_on +unit = await unit.turn_on() +unit = await unit.turn_off() + +# Fan speed: low, med, high, auto +unit.fan_speed +unit = await unit.set_fan_speed('med') + +# Mode of operation: auto, cool, dry, fan, heat +unit.mode +unit = await unit.set_mode('cool') + +# Get fresh info +unit = await unit.refresh() + +``` + + +%package help +Summary: Development documents and examples for pycoolmasternet-async +Provides: python3-pycoolmasternet-async-doc +%description help + +# pycoolmasternet-async + +A Python 3 library for interacting with a [CoolMasterNet](https://coolautomation.com/products/coolmasternet/) HVAC bridge. +This is a fork of [pycoolmaster](https://github.com/koreth/pycoolmasternet), modified to present an async interface and some other small changes. + +## Installation + +You can install pycoolmasternet-async from [PyPI](https://pypi.org/project/pycoolmasternet-async/): + + pip3 install pycoolmasternet-async + +Python 3.7 and above are supported. + + +## How to use + +```python +from pycoolmasternet_async import CoolMasterNet +cool = CoolMasterNet("coolmaster") + +# Supply the IP address and optional port number (default 10102). +cool = CoolMasterNet("192.168.0.123", port=12345, read_timeout=1) + +# General information +info = await cool.info() + +# Returns a dict of CoolMasterNetUnit objects. Keys are the unit IDs +units = await cool.status() + +unit = units["L1.001"] + +unit.unit_id + +# Temperature unit: Imperial, Celsius +unit.temperature_unit + +# Current reading of unit's thermometer +unit.temperature + +# Current setting of unit's thermostat +unit.thermostat + +# Setters return a new instance with updated info +unit = await unit.set_thermostat(28) + +# True if unit is turned on +unit.is_on +unit = await unit.turn_on() +unit = await unit.turn_off() + +# Fan speed: low, med, high, auto +unit.fan_speed +unit = await unit.set_fan_speed('med') + +# Mode of operation: auto, cool, dry, fan, heat +unit.mode +unit = await unit.set_mode('cool') + +# Get fresh info +unit = await unit.refresh() + +``` + + +%prep +%autosetup -n pycoolmasternet-async-0.1.6 + +%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-pycoolmasternet-async -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Mon May 15 2023 Python_Bot - 0.1.6-1 +- Package Spec generated diff --git a/sources b/sources new file mode 100644 index 0000000..0cfbe0d --- /dev/null +++ b/sources @@ -0,0 +1 @@ +621d151998d4a5d8a03e61710d5934ae pycoolmasternet-async-0.1.6.tar.gz -- cgit v1.2.3