mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-05 04:36:52 +00:00
Incorporate patch review on Flake8Command
* add a note about the setuptools command to README * don't install the Flake8Command entry point without setuptools * fix a bug in Flake8Command that might cause double checking of files in 'packages'
This commit is contained in:
parent
2e04e30d51
commit
c6ac38cd70
3 changed files with 44 additions and 9 deletions
12
setup.py
12
setup.py
|
|
@ -1,12 +1,14 @@
|
|||
import sys
|
||||
|
||||
ispy3 = sys.version_info[0] == 3
|
||||
issetuptools = False
|
||||
|
||||
if ispy3:
|
||||
from distutils.core import setup # NOQA
|
||||
else:
|
||||
try:
|
||||
from setuptools import setup # NOQA
|
||||
issetuptools = True
|
||||
except ImportError:
|
||||
from distutils.core import setup # NOQA
|
||||
|
||||
|
|
@ -14,6 +16,10 @@ from flake8 import __version__
|
|||
|
||||
README = open('README').read()
|
||||
|
||||
entry_points = {}
|
||||
if issetuptools:
|
||||
entry_points["distutils.commands"] = ["flake8 = flake8.run:Flake8Command"]
|
||||
|
||||
setup(
|
||||
name="flake8",
|
||||
license="MIT",
|
||||
|
|
@ -24,11 +30,7 @@ setup(
|
|||
url="http://bitbucket.org/tarek/flake8",
|
||||
packages=["flake8", "flake8.tests"],
|
||||
scripts=["flake8/flake8"],
|
||||
entry_points = {
|
||||
"distutils.commands": [
|
||||
"flake8 = flake8.run:Flake8Command",
|
||||
],
|
||||
},
|
||||
entry_points=entry_points,
|
||||
long_description=README,
|
||||
classifiers=[
|
||||
"Environment :: Console",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue