]> git.phdru.name Git - cookiecutter.git/blobdiff - project_template/setup.py
setup.py: Add long_description_content_type
[cookiecutter.git] / project_template / setup.py
index 3c7dc16a007180448698180a19c68d1d0a722da6..d02a035e58c66289d9cb15da641eebdedf4c5cec 100755 (executable)
@@ -2,33 +2,34 @@
 
 from imp import load_source
 from os.path import abspath, dirname, join
+from setuptools import setup
 
-try:
-    from ez_setup import use_setuptools
-    use_setuptools()
-except ImportError:
-    pass
-try:
-    from setuptools import setup
-    is_setuptools = True
-except ImportError:
-    from distutils.core import setup
-    is_setuptools = False
+versionpath = join(abspath(dirname(__file__)), '{project}', '__version__.py')
+{project}_version = load_source('{project}_version', versionpath)
 
-versionpath = join(abspath(dirname(__file__)), 'project', '__version__.py')
-load_source('m_librarian_version', versionpath)
-from m_librarian_version import __version__
-
-setup(name='Template project',
-      version=__version__,
-      description='Broytman Template Project',
-      long_description=open('README.txt', 'rtU').read(),
+setup(name='{project}',
+      version={project}_version.__version__,
+      description='Broytman {project}',
+      long_description=open('README.rst', 'rU').read(),
+      long_description_content_type="text/x-rst",
       author='Oleg Broytman',
       author_email='phd@phdru.name',
-      url='http://phdru.name/Software/Python/',
+      url='http://phdru.name/Software/Python/{project}',
+      download_url='http://phdru.name/Software/Python/{project}',
+      project_urls={
+          'Homepage': 'http://phdru.name/Software/Python/{project}',
+          'Documentation':
+              'http://phdru.name/Software/Python/{project}/docs/',
+          'Russian docs':
+              'http://phdru.name/Software/Python/{project}/docs/ru/',
+          'Download': 'http://phdru.name/Software/Python/{project}',
+          'Git repo': 'http://git.phdru.name/{project}.git/',
+          'Github repo': 'https://github.com/phdru/{project}',
+          'Issue tracker': 'https://github.com/phdru/{project}/issues',
+      },
       license='GPL',
-      platforms=['any'],
       keywords=[''],
+      platforms='Any',
       classifiers=[
           'Development Status :: 1 - Planning',
           'Environment :: Console',
@@ -37,12 +38,16 @@ setup(name='Template project',
           'License :: OSI Approved :: GNU General Public License (GPL)',
           'Operating System :: OS Independent',
           'Programming Language :: Python :: 2',
-          'Programming Language :: Python :: 2.6',
           'Programming Language :: Python :: 2.7',
-          'Programming Language :: Python :: 2 :: Only',
+          'Programming Language :: Python :: 3',
+          'Programming Language :: Python :: 3.3',
+          'Programming Language :: Python :: 3.4',
+          'Programming Language :: Python :: 3.5',
+          'Programming Language :: Python :: 3.6',
       ],
-      packages=['project'],
-      package_data={'project': []},
+      packages=['{project}'],
+      package_data={'{project}': []},
       scripts=[],
+      python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*',
       requires=[],
       )