mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-03-29 10:16:52 +00:00
Require a newer version of autopep8
This commit is contained in:
parent
c847dd3f2e
commit
ef7c425a3e
3 changed files with 5 additions and 4 deletions
|
|
@ -25,7 +25,8 @@ Add this to your `.pre-commit-config.yaml`
|
|||
|
||||
- `autopep8-wrapper` - Runs autopep8 over python source.
|
||||
- Ignore PEP 8 violation types with `args: ['-i', '--ignore=E000,...']` or
|
||||
through configuration of the `[pep8]` section in setup.cfg / tox.ini.
|
||||
through configuration of the `[pycodestyle]` section in
|
||||
setup.cfg / tox.ini.
|
||||
- `check-added-large-files` - Prevent giant files from being committed.
|
||||
- Specify what is "too large" with `args: ['--maxkb=123']` (default=500kB).
|
||||
- `check-ast` - Simply check whether files parse as valid python.
|
||||
|
|
|
|||
4
setup.py
4
setup.py
|
|
@ -24,9 +24,9 @@ setup(
|
|||
|
||||
packages=find_packages(exclude=('tests*', 'testing*')),
|
||||
install_requires=[
|
||||
# quickfix to prevent pep8 conflicts
|
||||
# quickfix to prevent pycodestyle conflicts
|
||||
'flake8!=2.5.3',
|
||||
'autopep8>=1.1',
|
||||
'autopep8>=1.3',
|
||||
'pyyaml',
|
||||
'simplejson',
|
||||
'six',
|
||||
|
|
|
|||
|
|
@ -23,6 +23,6 @@ def test_main_failing(tmpdir, input_src, expected_ret, output_src):
|
|||
|
||||
def test_respects_config_file(tmpdir):
|
||||
with tmpdir.as_cwd():
|
||||
tmpdir.join('setup.cfg').write('[pep8]\nignore=E221')
|
||||
tmpdir.join('setup.cfg').write('[pycodestyle]\nignore=E221')
|
||||
tmpdir.join('test.py').write('print(1 + 2)\n')
|
||||
assert main(['test.py', '-i', '-v']) == 0
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue