From 62af81e45f65f45d663f4e5c760c198460b76a7f Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Mon, 11 Dec 2017 21:03:30 +0300 Subject: [PATCH] Build(setup.py): Use python_requires keyword --- project_template/setup.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/project_template/setup.py b/project_template/setup.py index 6089728..f988f7c 100755 --- a/project_template/setup.py +++ b/project_template/setup.py @@ -10,6 +10,10 @@ except ImportError: from distutils.core import setup is_setuptools = False +kw = {} +if is_setuptools: + kw['python_requires'] = '>=2.7, !=3.0.*, !=3.1.*, !=3.2.*' + versionpath = join(abspath(dirname(__file__)), '{project}', '__version__.py') load_source('{project}_version', versionpath) # Ignore: E402 module level import not at top of file @@ -44,4 +48,5 @@ setup(name='{project}', package_data={'{project}': []}, scripts=[], requires=[], + **kw ) -- 2.39.5