Skip to content

Commit e6e6eb6

Browse files
committed
Use README.md as a long description
1 parent 3dc18da commit e6e6eb6

File tree

1 file changed

+12
-16
lines changed

1 file changed

+12
-16
lines changed

setup.py

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,37 @@
11
import re
22
from setuptools import find_packages, setup
33

4-
LONG_DESCRIPTION = """Django-Prometheus
4+
with open("README.md") as fl:
5+
LONG_DESCRIPTION = fl.read()
56

6-
This library contains code to expose some monitoring metrics relevant
7-
to Django internals so they can be monitored by Prometheus.io.
8-
9-
See https://github.com/korfuri/django-prometheus for usage
10-
instructions.
11-
"""
127

138
def get_version():
14-
version_file = open('django_prometheus/__init__.py', 'r').read()
15-
version_match = re.search(r'^__version__ = [\'"]([^\'"]*)[\'"]', version_file, re.MULTILINE)
9+
version_file = open("django_prometheus/__init__.py", "r").read()
10+
version_match = re.search(
11+
r'^__version__ = [\'"]([^\'"]*)[\'"]', version_file, re.MULTILINE
12+
)
1613
if version_match:
1714
return version_match.group(1)
18-
raise RuntimeError('Unable to find version string.')
15+
raise RuntimeError("Unable to find version string.")
16+
1917

2018
setup(
2119
name="django-prometheus",
2220
version=get_version(),
2321
author="Uriel Corfa",
2422
author_email="[email protected]",
25-
description=(
26-
"Django middlewares to monitor your application with Prometheus.io."),
23+
description=("Django middlewares to monitor your application with Prometheus.io."),
2724
license="Apache",
2825
keywords="django monitoring prometheus",
2926
url="http://github.com/korfuri/django-prometheus",
3027
packages=find_packages(),
3128
test_suite="django_prometheus.tests",
3229
long_description=LONG_DESCRIPTION,
33-
tests_require=['pytest', 'pytest-django'],
30+
long_description_content_type="text/markdown",
31+
tests_require=["pytest", "pytest-django"],
3432
setup_requires=["pytest-runner"],
3533
options={"bdist_wheel": {"universal": "1"}},
36-
install_requires=[
37-
"prometheus-client>=0.7",
38-
],
34+
install_requires=["prometheus-client>=0.7",],
3935
classifiers=[
4036
"Development Status :: 5 - Production/Stable",
4137
"Intended Audience :: Developers",

0 commit comments

Comments
 (0)