Commits

mrtheb  committed aea08a8

added entry_point for flake8 on py3

  • Participants
  • Parent commits 98ae302

Comments (0)

Files changed (2)

File MANIFEST.in

-include CONTRIBUTORS.txt
-include README
-include LICENSE
-recursive-include scripts flake8.*
 kwargs = {}
 scripts = ["flake8/flake8"]
 if ispy3:
-    from distutils.core import setup    # NOQA
-    if iswin:
-        scripts.append("scripts/flake8.cmd")
+    try:
+        from setuptools import setup    # NOQA
+        kwargs = {
+            'entry_points': {
+                'console_scripts': ['flake8 = flake8.main:main']
+            },
+        }
+    except ImportError:
+        from distutils.core import setup    # NOQA
+        if iswin:
+            scripts.append("scripts/flake8.cmd")
 else:
     try:
         from setuptools import setup    # NOQA