add flake8-checks to travis
This commit is contained in:
parent
81028f9a35
commit
337e8ee19e
|
@ -25,6 +25,8 @@ matrix:
|
|||
env: TOXENV=pypy3
|
||||
- python: 2.7
|
||||
env: TOXENV=docs
|
||||
- python: 3.4
|
||||
env: TOXENV=flake8
|
||||
allow_failures:
|
||||
- python: 3.5-dev
|
||||
- python: nightly
|
||||
|
|
|
@ -9,3 +9,4 @@ universal=1
|
|||
[flake8]
|
||||
exclude = .git,.tox,.github,.eggs,__pycache__,doc/conf.py,build,dist,capabilities-data,test,src/escpos/constants.py
|
||||
max-line-length = 120
|
||||
# future-imports = absolute_import, division, print_function, unicode_literals # we are not there yet
|
||||
|
|
3
setup.py
3
setup.py
|
@ -50,6 +50,9 @@ setuptools_scm_template = """\
|
|||
# coding: utf-8
|
||||
# file generated by setuptools_scm
|
||||
# don't change, don't track in version control
|
||||
from __future__ import absolute_import
|
||||
from __future__ import division
|
||||
from __future__ import print_function
|
||||
from __future__ import unicode_literals
|
||||
|
||||
version = '{version}'
|
||||
|
|
|
@ -33,9 +33,11 @@ def str_to_bool(string):
|
|||
"""
|
||||
return string.lower() in ('y', 'yes', '1', 'true')
|
||||
|
||||
|
||||
# A list of functions that work better with a newline to be sent after them.
|
||||
REQUIRES_NEWLINE = ('qr', 'barcode', 'text', 'block_text')
|
||||
|
||||
|
||||
# Used in demo method
|
||||
# Key: The name of escpos function and the argument passed on the CLI. Some
|
||||
# manual translation is done in the case of barcodes_a -> barcode.
|
||||
|
@ -568,5 +570,6 @@ def demo(printer, **kwargs):
|
|||
command(**params)
|
||||
printer.cut()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
|
@ -20,4 +20,5 @@ class CodePageManager:
|
|||
def get_encoding(self, encoding):
|
||||
return self.data[encoding]
|
||||
|
||||
|
||||
CodePages = CodePageManager(CAPABILITIES['encodings'])
|
||||
|
|
Loading…
Reference in New Issue