File: setup.py

package info (click to toggle)
python-sharkiq 1.1.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 172 kB
  • sloc: python: 847; makefile: 2
file content (43 lines) | stat: -rw-r--r-- 1,219 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
import pathlib
from setuptools import setup

try:
    import re2 as re
except ImportError:
    import re

packages = ["sharkiq"]

# The directory containing this file
HERE = pathlib.Path(__file__).parent

# The text of the README file
README = (HERE / "README.md").read_text()

# Pull the version from __init__.py so we don't need to maintain it in multiple places
init_txt = (HERE / packages[0] / "__init__.py").read_text("utf-8")
try:
    version = re.findall(r"^__version__ = ['\"]([^'\"]+)['\"]\r?$", init_txt, re.M)[0]
except IndexError:
    raise RuntimeError('Unable to determine version.')


setup(
    name="sharkiq",
    version=version,
    description="Python API for Shark IQ robots",
    long_description=README,
    long_description_content_type="text/markdown",
    url="https://github.com/JeffResc/sharkiq-ng",
    author="Jeff Rescignano",
    author_email="jeff@jeffresc.dev",
    license="MIT",
    classifiers=[
        "License :: OSI Approved :: MIT License",
        "Programming Language :: Python :: 3",
        "Programming Language :: Python :: 3.7",
    ],
    packages=packages,
    include_package_data=False,
    install_requires=list(val.strip() for val in open("requirements.txt")),
)