Merging upstream version 1.4.19.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
5c3aea9c4f
commit
e7d2ed8206
6 changed files with 23 additions and 9 deletions
|
@ -1,6 +1,6 @@
|
||||||
repos:
|
repos:
|
||||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
rev: v2.1.0
|
rev: v2.5.0
|
||||||
hooks:
|
hooks:
|
||||||
- id: trailing-whitespace
|
- id: trailing-whitespace
|
||||||
- id: end-of-file-fixer
|
- id: end-of-file-fixer
|
||||||
|
@ -14,16 +14,16 @@ repos:
|
||||||
- id: check-byte-order-marker
|
- id: check-byte-order-marker
|
||||||
- id: fix-encoding-pragma
|
- id: fix-encoding-pragma
|
||||||
- repo: https://gitlab.com/pycqa/flake8
|
- repo: https://gitlab.com/pycqa/flake8
|
||||||
rev: 3.7.7
|
rev: 3.8.0
|
||||||
hooks:
|
hooks:
|
||||||
- id: flake8
|
- id: flake8
|
||||||
exclude: ^identify/vendor/licenses\.py$
|
exclude: ^identify/vendor/licenses\.py$
|
||||||
- repo: https://github.com/pre-commit/mirrors-autopep8
|
- repo: https://github.com/pre-commit/mirrors-autopep8
|
||||||
rev: v1.4.3
|
rev: v1.5.2
|
||||||
hooks:
|
hooks:
|
||||||
- id: autopep8
|
- id: autopep8
|
||||||
- repo: https://github.com/asottile/reorder_python_imports
|
- repo: https://github.com/asottile/reorder_python_imports
|
||||||
rev: v1.4.0
|
rev: v2.3.0
|
||||||
hooks:
|
hooks:
|
||||||
- id: reorder-python-imports
|
- id: reorder-python-imports
|
||||||
args: [
|
args: [
|
||||||
|
@ -31,6 +31,6 @@ repos:
|
||||||
'--add-import', 'from __future__ import unicode_literals',
|
'--add-import', 'from __future__ import unicode_literals',
|
||||||
]
|
]
|
||||||
- repo: https://github.com/asottile/add-trailing-comma
|
- repo: https://github.com/asottile/add-trailing-comma
|
||||||
rev: v1.0.0
|
rev: v2.0.1
|
||||||
hooks:
|
hooks:
|
||||||
- id: add-trailing-comma
|
- id: add-trailing-comma
|
||||||
|
|
|
@ -8,6 +8,8 @@ matrix:
|
||||||
python: 3.6
|
python: 3.6
|
||||||
- env: TOXENV=pypy
|
- env: TOXENV=pypy
|
||||||
python: pypy
|
python: pypy
|
||||||
|
- env: TOXENV=pre-commit
|
||||||
|
python: 3.6
|
||||||
install: pip install coveralls tox
|
install: pip install coveralls tox
|
||||||
script: tox
|
script: tox
|
||||||
after_success: coveralls
|
after_success: coveralls
|
||||||
|
|
|
@ -16,6 +16,9 @@ EXTENSIONS = {
|
||||||
'cc': {'text', 'c++'},
|
'cc': {'text', 'c++'},
|
||||||
'cu': {'text', 'cuda'},
|
'cu': {'text', 'cuda'},
|
||||||
'cfg': {'text'},
|
'cfg': {'text'},
|
||||||
|
'clj': {'text', 'clojure'},
|
||||||
|
'cljc': {'text', 'clojure'},
|
||||||
|
'cljs': {'text', 'clojure', 'clojurescript'},
|
||||||
'cmake': {'text', 'cmake'},
|
'cmake': {'text', 'cmake'},
|
||||||
'cnf': {'text'},
|
'cnf': {'text'},
|
||||||
'coffee': {'text', 'coffee'},
|
'coffee': {'text', 'coffee'},
|
||||||
|
@ -23,6 +26,7 @@ EXTENSIONS = {
|
||||||
'cpp': {'text', 'c++'},
|
'cpp': {'text', 'c++'},
|
||||||
'crt': {'text', 'pem'},
|
'crt': {'text', 'pem'},
|
||||||
'cs': {'text', 'c#'},
|
'cs': {'text', 'c#'},
|
||||||
|
'csh': {'text', 'shell', 'csh'},
|
||||||
'cson': {'text', 'cson'},
|
'cson': {'text', 'cson'},
|
||||||
'css': {'text', 'css'},
|
'css': {'text', 'css'},
|
||||||
'csv': {'text', 'csv'},
|
'csv': {'text', 'csv'},
|
||||||
|
@ -31,6 +35,7 @@ EXTENSIONS = {
|
||||||
'def': {'text', 'def'},
|
'def': {'text', 'def'},
|
||||||
'dtd': {'text', 'dtd'},
|
'dtd': {'text', 'dtd'},
|
||||||
'ear': {'binary', 'zip', 'jar'},
|
'ear': {'binary', 'zip', 'jar'},
|
||||||
|
'edn': {'text', 'clojure', 'edn'},
|
||||||
'ejs': {'text', 'ejs'},
|
'ejs': {'text', 'ejs'},
|
||||||
'eot': {'binary', 'eot'},
|
'eot': {'binary', 'eot'},
|
||||||
'eps': {'binary', 'eps'},
|
'eps': {'binary', 'eps'},
|
||||||
|
@ -44,6 +49,7 @@ EXTENSIONS = {
|
||||||
'go': {'text', 'go'},
|
'go': {'text', 'go'},
|
||||||
'gotmpl': {'text', 'gotmpl'},
|
'gotmpl': {'text', 'gotmpl'},
|
||||||
'gpx': {'text', 'gpx', 'xml'},
|
'gpx': {'text', 'gpx', 'xml'},
|
||||||
|
'graphql': {'text', 'graphql'},
|
||||||
'gradle': {'text', 'groovy'},
|
'gradle': {'text', 'groovy'},
|
||||||
'groovy': {'text', 'groovy'},
|
'groovy': {'text', 'groovy'},
|
||||||
'gyb': {'text', 'gyb'},
|
'gyb': {'text', 'gyb'},
|
||||||
|
@ -150,6 +156,7 @@ EXTENSIONS = {
|
||||||
'tiff': {'binary', 'image', 'tiff'},
|
'tiff': {'binary', 'image', 'tiff'},
|
||||||
'toml': {'text', 'toml'},
|
'toml': {'text', 'toml'},
|
||||||
'tf': {'text', 'terraform'},
|
'tf': {'text', 'terraform'},
|
||||||
|
'tfvars': {'text', 'terraform'},
|
||||||
'ts': {'text', 'ts'},
|
'ts': {'text', 'ts'},
|
||||||
'tsx': {'text', 'tsx'},
|
'tsx': {'text', 'tsx'},
|
||||||
'ttf': {'binary', 'ttf'},
|
'ttf': {'binary', 'ttf'},
|
||||||
|
@ -192,6 +199,7 @@ NAMES = {
|
||||||
'.bash_profile': EXTENSIONS['bash'],
|
'.bash_profile': EXTENSIONS['bash'],
|
||||||
'.bowerrc': EXTENSIONS['json'] | {'bowerrc'},
|
'.bowerrc': EXTENSIONS['json'] | {'bowerrc'},
|
||||||
'.coveragerc': EXTENSIONS['ini'] | {'coveragerc'},
|
'.coveragerc': EXTENSIONS['ini'] | {'coveragerc'},
|
||||||
|
'.cshrc': EXTENSIONS['csh'],
|
||||||
'.dockerignore': {'text', 'dockerignore'},
|
'.dockerignore': {'text', 'dockerignore'},
|
||||||
'.editorconfig': {'text', 'editorconfig'},
|
'.editorconfig': {'text', 'editorconfig'},
|
||||||
'.gitconfig': EXTENSIONS['ini'] | {'gitconfig'},
|
'.gitconfig': EXTENSIONS['ini'] | {'gitconfig'},
|
||||||
|
|
|
@ -4,6 +4,7 @@ from __future__ import unicode_literals
|
||||||
|
|
||||||
INTERPRETERS = {
|
INTERPRETERS = {
|
||||||
'bash': {'shell', 'bash'},
|
'bash': {'shell', 'bash'},
|
||||||
|
'csh': {'shell', 'csh'},
|
||||||
'dash': {'shell', 'dash'},
|
'dash': {'shell', 'dash'},
|
||||||
'node': {'javascript'},
|
'node': {'javascript'},
|
||||||
'nodejs': {'javascript'},
|
'nodejs': {'javascript'},
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[metadata]
|
[metadata]
|
||||||
name = identify
|
name = identify
|
||||||
version = 1.4.15
|
version = 1.4.19
|
||||||
description = File identification library for Python
|
description = File identification library for Python
|
||||||
long_description = file: README.md
|
long_description = file: README.md
|
||||||
long_description_content_type = text/markdown
|
long_description_content_type = text/markdown
|
||||||
|
|
9
tox.ini
9
tox.ini
|
@ -1,5 +1,5 @@
|
||||||
[tox]
|
[tox]
|
||||||
envlist = py27,py35,py36,pypy
|
envlist = py27,py35,py36,pypy,pre-commit
|
||||||
tox_pip_extensions_ext_venv_update = true
|
tox_pip_extensions_ext_venv_update = true
|
||||||
|
|
||||||
[testenv]
|
[testenv]
|
||||||
|
@ -9,8 +9,11 @@ commands =
|
||||||
coverage erase
|
coverage erase
|
||||||
coverage run -m pytest {posargs:tests}
|
coverage run -m pytest {posargs:tests}
|
||||||
coverage report --fail-under 100
|
coverage report --fail-under 100
|
||||||
pre-commit install -f --install-hooks
|
|
||||||
pre-commit run --all-files
|
[testenv:pre-commit]
|
||||||
|
skip_install = true
|
||||||
|
deps = pre-commit
|
||||||
|
commands = pre-commit run --all-files --show-diff-on-failure
|
||||||
|
|
||||||
[flake8]
|
[flake8]
|
||||||
max-line-length = 119
|
max-line-length = 119
|
||||||
|
|
Loading…
Add table
Reference in a new issue