Skip to content

Commit 19fad26

Browse files
author
Anand Sanmukhani
committed
Update setup.py.
Update __init__.py
1 parent 1715400 commit 19fad26

File tree

3 files changed

+16
-5
lines changed

3 files changed

+16
-5
lines changed

prometheus_connect/__init__.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
1-
name = "prometheus_connect"
2-
from .prometheus_connect import PrometheusConnect
1+
""" A Class for collection of metrics from a Prometheus Host """
2+
3+
__title__ = "prometheus-connect"
4+
__version__ = "0.0.1"
5+
6+
from .prometheus_connect import *

prometheus_connect/prometheus_connect.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
class PrometheusConnect:
2222
"""
23-
A Class for collection of metrics from a Prometheus Host.
23+
A Class for collection of metrics from a Prometheus Host
2424
"""
2525
def __init__(self, url='http://127.0.0.1:9090', headers=None, disable_ssl=False):
2626
"""

setup.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,25 @@
33
with open("README.md", "r") as fh:
44
long_description = fh.read()
55

6+
7+
def get_install_requires():
8+
with open('requirements.txt', 'r') as requirements_file:
9+
res = requirements_file.readlines()
10+
return [req.split(' ', maxsplit=1)[0] for req in res if req]
11+
612
setuptools.setup(
713
name="prometheus-connect",
814
version="0.0.1",
915
author="Anand Sanmukhani",
10-
author_email="[email protected]",
16+
author_email="[email protected]",
1117
description="A small python api to collect data from prometheus",
1218
long_description=long_description,
1319
long_description_content_type="text/markdown",
1420
url="https://github.com/4n4nd/prometheus-connect",
21+
install_requires=get_install_requires(),
1522
packages=setuptools.find_packages(),
1623
classifiers=[
17-
"Programming Language :: Python :: 3",
24+
"Programming Language :: Python :: 3.6",
1825
"License :: OSI Approved :: MIT License",
1926
"Operating System :: OS Independent",
2027
],

0 commit comments

Comments
 (0)