mirror of
https://github.com/jongracecox/anybadge.git
synced 2026-01-05 03:41:08 +01:00
Python version support ====================== - Drop Python 2.7 support - Add testing for Python 3.4 and 3.9 - Set python version requirements in setup.py Package changes =============== - Split module up into a package with submodules - Break templates out into package resources - Incorporate server into same package - Use Enum for colors - Refresh example badges - Simplify documentation - Remove cli options and python api documentation from the README as it is hard to maintain, and often goes out-of-date - Add CONTRIBUTING.md
42 lines
1.2 KiB
Python
42 lines
1.2 KiB
Python
#!/usr/bin/python
|
|
import os
|
|
import re
|
|
from setuptools import setup
|
|
|
|
with open('README.md', encoding='utf-8') as f:
|
|
long_description = f.read()
|
|
|
|
# Attempt to get version number from TravisCI environment variable
|
|
version = os.environ.get('TRAVIS_TAG', default='0.0.0')
|
|
|
|
# Remove leading 'v'
|
|
version = re.sub('^v', '', version)
|
|
|
|
setup(
|
|
name='anybadge',
|
|
description='Simple, flexible badge generator for project badges.',
|
|
long_description=long_description,
|
|
long_description_content_type='text/markdown',
|
|
version=version,
|
|
author='Jon Grace-Cox',
|
|
author_email='jongracecox@gmail.com',
|
|
packages=['anybadge'],
|
|
py_modules=['anybadge_server'],
|
|
setup_requires=['setuptools', 'wheel'],
|
|
tests_require=[],
|
|
install_requires=['packaging'],
|
|
package_data={'anybadge': ['templates/*.svg']},
|
|
options={
|
|
'bdist_wheel': {'universal': False}
|
|
},
|
|
python_requires='>=3.4',
|
|
url='https://github.com/jongracecox/anybadge',
|
|
entry_points={
|
|
'console_scripts': ['anybadge=anybadge.cli:main',
|
|
'anybadge-server=anybadge.server.cli:main'],
|
|
},
|
|
classifiers=[
|
|
'License :: OSI Approved :: MIT License'
|
|
]
|
|
)
|