From 2c4552a52837bd7914d3adf6afdfb5a35c76d30d Mon Sep 17 00:00:00 2001 From: Patrick Kanzler Date: Sat, 9 May 2020 02:14:23 +0200 Subject: [PATCH 1/4] mark as requiring at least python 3.5 --- setup.py | 1 + 1 file changed, 1 insertion(+) diff --git a/setup.py b/setup.py index f067fa2..6271205 100755 --- a/setup.py +++ b/setup.py @@ -54,6 +54,7 @@ setup( 'receipt,', ], platforms='any', + python_requires='>=3.5', package_dir={"": "src"}, packages=find_packages(where="src", exclude=["tests", "tests.*"]), package_data={'escpos': ['capabilities.json']}, From faa9414da5ef639512388a7330dfa3c18b822f9e Mon Sep 17 00:00:00 2001 From: Patrick Kanzler Date: Sat, 9 May 2020 02:15:13 +0200 Subject: [PATCH 2/4] move marker down to other requires --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 6271205..f2c69c7 100755 --- a/setup.py +++ b/setup.py @@ -54,7 +54,6 @@ setup( 'receipt,', ], platforms='any', - python_requires='>=3.5', package_dir={"": "src"}, packages=find_packages(where="src", exclude=["tests", "tests.*"]), package_data={'escpos': ['capabilities.json']}, @@ -75,6 +74,7 @@ setup( 'Topic :: Software Development :: Libraries :: Python Modules', 'Topic :: Office/Business :: Financial :: Point-Of-Sale', ], + python_requires='>=3.5', install_requires=[ 'pyusb>=1.0.0', 'Pillow>=2.0', From c14a414924727e3f565b217227828ee003e93a14 Mon Sep 17 00:00:00 2001 From: Patrick Kanzler Date: Sat, 9 May 2020 02:45:34 +0200 Subject: [PATCH 3/4] transition setup.py to setup.cfg --- setup.cfg | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++ setup.py | 63 ------------------------------------------------------- 2 files changed, 61 insertions(+), 63 deletions(-) diff --git a/setup.cfg b/setup.cfg index ea43f22..bf55928 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,3 +1,64 @@ +[metadata] +name = python-escpos +url = https://github.com/python-escpos/python-escpos +description = Python library to manipulate ESC/POS Printers +long_description = file: README.rst +license = MIT +license_file = LICENSE +author = Manuel F Martinez and others +author_email = dev@pkanzler.de +maintainer = Patrick Kanzler +maintainer_email = dev@pkanzler.de +keywords = ESC/POS, thermoprinter, voucher printer, printing, receipt +classifiers = + Development Status :: 4 - Beta + Environment :: Console + Intended Audience :: Developers + License :: OSI Approved :: MIT License + Operating System :: OS Independent + Programming Language :: Python + Programming Language :: Python :: 3 + Programming Language :: Python :: 3.5 + Programming Language :: Python :: 3.6 + Programming Language :: Python :: 3.7 + Programming Language :: Python :: 3.8 + Programming Language :: Python :: Implementation :: CPython + Topic :: Software Development :: Libraries :: Python Modules + Topic :: Office/Business :: Financial :: Point-Of-Sale +project_urls = + Bug Tracker = https://github.com/python-escpos/python-escpos/issues + Documentation = https://python-escpos.readthedocs.io/en/latest/ + Release Notes = https://github.com/python-escpos/python-escpos/releases + +[options] +python_requires = >=3.5 +zip_safe = false +include_package_data = true +install_requires = + pyusb>=1.0.0 + Pillow>=2.0 + qrcode>=4.0 + pyserial + six + appdirs + PyYAML + argparse + argcomplete + future + viivakoodi>=0.8 +setup_requires = setuptools_scm +tests_require = + jaconv + tox + pytest!=3.2.0,!=3.3.0 + pytest-cov + pytest-mock + nose + scripttest + mock + hypothesis>4 + flake8 + [nosetests] verbosity=3 with-doctest=1 diff --git a/setup.py b/setup.py index f2c69c7..daefee2 100755 --- a/setup.py +++ b/setup.py @@ -32,77 +32,14 @@ version = '{version}' setup( - name='python-escpos', use_scm_version={ 'write_to': 'src/escpos/version.py', 'write_to_template': setuptools_scm_template, }, - url='https://github.com/python-escpos/python-escpos', - download_url='https://github.com/python-escpos/python-escpos/archive/master.zip', - description='Python library to manipulate ESC/POS Printers', - license='MIT', - long_description=read('README.rst'), - author='Manuel F Martinez and others', - author_email='manpaz@bashlinux.com', - maintainer='Patrick Kanzler', - maintainer_email='dev@pkanzler.de', - keywords=[ - 'ESC/POS', - 'thermoprinter', - 'voucher printer', - 'printing', - 'receipt,', - ], platforms='any', package_dir={"": "src"}, packages=find_packages(where="src", exclude=["tests", "tests.*"]), package_data={'escpos': ['capabilities.json']}, - include_package_data=True, - classifiers=[ - 'Development Status :: 4 - Beta', - 'Environment :: Console', - 'Intended Audience :: Developers', - 'License :: OSI Approved :: MIT License', - 'Operating System :: OS Independent', - 'Programming Language :: Python', - 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.5', - 'Programming Language :: Python :: 3.6', - 'Programming Language :: Python :: 3.7', - 'Programming Language :: Python :: 3.8', - 'Programming Language :: Python :: Implementation :: CPython', - 'Topic :: Software Development :: Libraries :: Python Modules', - 'Topic :: Office/Business :: Financial :: Point-Of-Sale', - ], - python_requires='>=3.5', - install_requires=[ - 'pyusb>=1.0.0', - 'Pillow>=2.0', - 'qrcode>=4.0', - 'pyserial', - 'six', - 'appdirs', - 'PyYAML', - 'argparse', - 'argcomplete', - 'future', - 'viivakoodi>=0.8' - ], - setup_requires=[ - 'setuptools_scm', - ], - tests_require=[ - 'jaconv', - 'tox', - 'pytest!=3.2.0,!=3.3.0', - 'pytest-cov', - 'pytest-mock', - 'nose', - 'scripttest', - 'mock', - 'hypothesis>4', - 'flake8' - ], entry_points={ 'console_scripts': [ 'python-escpos = escpos.cli:main' From 6a60b6706e0dd7cbf5a4c28b971c13f669f822d5 Mon Sep 17 00:00:00 2001 From: Patrick Kanzler Date: Sat, 9 May 2020 02:48:24 +0200 Subject: [PATCH 4/4] apply black to setup.py --- setup.py | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/setup.py b/setup.py index daefee2..0d98b58 100755 --- a/setup.py +++ b/setup.py @@ -33,16 +33,12 @@ version = '{version}' setup( use_scm_version={ - 'write_to': 'src/escpos/version.py', - 'write_to_template': setuptools_scm_template, + "write_to": "src/escpos/version.py", + "write_to_template": setuptools_scm_template, }, - platforms='any', + platforms="any", package_dir={"": "src"}, packages=find_packages(where="src", exclude=["tests", "tests.*"]), - package_data={'escpos': ['capabilities.json']}, - entry_points={ - 'console_scripts': [ - 'python-escpos = escpos.cli:main' - ] - }, + package_data={"escpos": ["capabilities.json"]}, + entry_points={"console_scripts": ["python-escpos = escpos.cli:main"]}, )