1+ import io
2+ import os
3+
4+ from setuptools import find_packages , setup
5+
6+ # Package meta-data.
7+ NAME = 'blueprint'
8+ DESCRIPTION = 'Blueprint/Boilerplate For Python Projects'
9+ URL = 'https://github.com/MartinHeinz/python-project-blueprint'
10+ EMAIL = 'martin7.heinz@gmail.com'
11+ AUTHOR = 'Martin Heinz'
12+ REQUIRES_PYTHON = '>=3.8.0'
13+ VERSION = '0.0.1'
14+
15+ # What packages are required for this module to be executed?
16+ REQUIRED = [
17+ 'pytest' ,
18+ ]
19+
20+ # What packages are optional?
21+ EXTRAS = {
22+ # 'fancy feature': ['django'],
23+ }
24+
25+ here = os .path .abspath (os .path .dirname (__file__ ))
26+
27+ # Import the README and use it as the long-description.
28+ # Note: this will only work if 'README.md' is present in your MANIFEST.in file!
29+ try :
30+ with io .open (os .path .join (here , 'README.md' ), encoding = 'utf-8' ) as f :
31+ long_description = '\n ' + f .read ()
32+ except FileNotFoundError :
33+ long_description = DESCRIPTION
34+
35+ # Load the package's __version__.py module as a dictionary.
36+ about = {}
37+ if not VERSION :
38+ project_slug = NAME .lower ().replace ("-" , "_" ).replace (" " , "_" )
39+ with open (os .path .join (here , project_slug , '__version__.py' )) as f :
40+ exec (f .read (), about )
41+ else :
42+ about ['__version__' ] = VERSION
43+
44+ setup (
45+ name = NAME ,
46+ version = about ['__version__' ],
47+ description = DESCRIPTION ,
48+ long_description = long_description ,
49+ long_description_content_type = 'text/markdown' ,
50+ author = AUTHOR ,
51+ author_email = EMAIL ,
52+ python_requires = REQUIRES_PYTHON ,
53+ url = URL ,
54+ packages = find_packages (exclude = ["tests" , "*.tests" , "*.tests.*" , "tests.*" ]),
55+ # If your package is a single module, use this instead of 'packages':
56+ # py_modules=['mypackage'],
57+
58+ # entry_points={
59+ # 'console_scripts': ['mycli=mymodule:cli'],
60+ # },
61+ install_requires = REQUIRED ,
62+ extras_require = EXTRAS ,
63+ include_package_data = True ,
64+ license = 'MIT' ,
65+ classifiers = [
66+ # Trove classifiers
67+ # Full list: https://pypi.python.org/pypi?%3Aaction=list_classifiers
68+ 'License :: OSI Approved :: MIT License' ,
69+ 'Programming Language :: Python' ,
70+ 'Programming Language :: Python :: 3' ,
71+ 'Programming Language :: Python :: 3.8' ,
72+ 'Programming Language :: Python :: Implementation :: CPython' ,
73+ ],
74+ )
75+
76+ # TODO add option to upload to PyPI
0 commit comments