setup.py 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. # switchbot-mqtt - MQTT client controlling SwitchBot button automators,
  2. # compatible with home-assistant.io's MQTT Switch platform
  3. #
  4. # Copyright (C) 2020 Fabian Peter Hammerle <fabian@hammerle.me>
  5. #
  6. # This program is free software: you can redistribute it and/or modify
  7. # it under the terms of the GNU General Public License as published by
  8. # the Free Software Foundation, either version 3 of the License, or
  9. # any later version.
  10. #
  11. # This program is distributed in the hope that it will be useful,
  12. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. # GNU General Public License for more details.
  15. #
  16. # You should have received a copy of the GNU General Public License
  17. # along with this program. If not, see <https://www.gnu.org/licenses/>.
  18. import pathlib
  19. import setuptools
  20. _REPO_URL = "https://github.com/fphammerle/switchbot-mqtt"
  21. setuptools.setup(
  22. name="switchbot-mqtt",
  23. use_scm_version={
  24. # > AssertionError: cant parse version docker/0.1.0-amd64
  25. # https://github.com/pypa/setuptools_scm/blob/master/src/setuptools_scm/git.py#L15
  26. "git_describe_command": "git describe --dirty --tags --long --match v*",
  27. },
  28. packages=setuptools.find_packages(),
  29. description="MQTT client controlling SwitchBot button automators, "
  30. # https://www.home-assistant.io/integrations/switch.mqtt/
  31. "compatible with home-assistant.io's MQTT Switch platform",
  32. long_description=pathlib.Path(__file__).parent.joinpath("README.md").read_text(),
  33. long_description_content_type="text/markdown",
  34. author="Fabian Peter Hammerle",
  35. author_email="fabian@hammerle.me",
  36. url=_REPO_URL,
  37. project_urls={"Changelog": _REPO_URL + "/blob/master/CHANGELOG.md"},
  38. license="GPLv3+",
  39. keywords=[
  40. "IoT",
  41. "automation",
  42. "bluetooth",
  43. "button",
  44. "click",
  45. "home-assistant.io",
  46. "home-automation",
  47. "mqtt",
  48. "press",
  49. "push",
  50. "switchbot",
  51. ],
  52. classifiers=[
  53. # https://pypi.org/classifiers/
  54. "Development Status :: 2 - Pre-Alpha",
  55. "Intended Audience :: End Users/Desktop",
  56. "Intended Audience :: System Administrators",
  57. "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
  58. "Operating System :: POSIX :: Linux",
  59. # .github/workflows/python.yml
  60. "Programming Language :: Python :: 3.5",
  61. "Programming Language :: Python :: 3.6",
  62. "Programming Language :: Python :: 3.7",
  63. "Programming Language :: Python :: 3.8",
  64. "Topic :: Home Automation",
  65. ],
  66. entry_points={
  67. "console_scripts": [
  68. "switchbot-mqtt = switchbot_mqtt:_main",
  69. ]
  70. },
  71. install_requires=["PySwitchbot", "paho-mqtt<2"],
  72. setup_requires=["setuptools_scm"],
  73. tests_require=["pytest"],
  74. )