Use pycodestyle instead of pep8, fix its warnings and config
This commit is contained in:
parent
49b8acac6e
commit
68d9caef5a
@ -12,11 +12,11 @@ matrix:
|
||||
language: generic
|
||||
|
||||
install:
|
||||
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo pip2 install pyflakes pep8 coverage coveralls nose; fi
|
||||
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then pip install pyflakes pep8 coverage coveralls nose; fi
|
||||
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo pip2 install pyflakes pycodestyle coverage coveralls nose; fi
|
||||
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then pip install pyflakes pycodestyle coverage coveralls nose; fi
|
||||
|
||||
script:
|
||||
- pyflakes .
|
||||
- pep8 .
|
||||
- pycodestyle .
|
||||
- nosetests
|
||||
- coveralls
|
||||
|
||||
@ -7,11 +7,11 @@ environment:
|
||||
|
||||
build_script:
|
||||
- PATH %CD%\here\bin;C:\mingw\bin;C:\python%Python%;C:\python%Python%\scripts;%PATH%
|
||||
- pip install pyflakes pep8 coverage coveralls nose
|
||||
- pip install pyflakes pycodestyle coverage coveralls nose
|
||||
|
||||
test_script:
|
||||
- pyflakes .
|
||||
- pep8 .
|
||||
- pycodestyle .
|
||||
- nosetests
|
||||
- coverage report
|
||||
- if not "%COVERALLS_REPO_TOKEN%"=="" coveralls
|
||||
|
||||
@ -154,7 +154,7 @@ def write_activation_scripts():
|
||||
"LOCATION_DQ": opts.location.replace("\\", "\\\\").replace('"', '\\"'),
|
||||
"LOCATION_SQ": opts.location.replace("'", "'\\''"),
|
||||
"LOCATION_NESTED_SQ": opts.location.replace("'", "'\\''").replace("'", "'\\''"),
|
||||
"LOCATION_PAREN": re.sub("[&,=()]", "^\g<0>", opts.location)
|
||||
"LOCATION_PAREN": re.sub("[&,=()]", r"^\g<0>", opts.location)
|
||||
}
|
||||
|
||||
for template_name in template_names:
|
||||
@ -165,9 +165,7 @@ def write_activation_scripts():
|
||||
script_handle.write(script)
|
||||
|
||||
def is_executable(path):
|
||||
return (os.path.exists(path) and
|
||||
os.access(path, os.F_OK | os.X_OK) and
|
||||
not os.path.isdir(path))
|
||||
return os.path.exists(path) and os.access(path, os.F_OK | os.X_OK) and not os.path.isdir(path)
|
||||
|
||||
def program_exists(prog):
|
||||
path = os.environ.get("PATH", os.defpath)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user