55import sys
66from distutils .core import Command
77try :
8- from setuptools import setup
9- except ImportError :
10- from distutils .core import setup
8+ from setuptools import setup
9+ except ImportError :
10+ from distutils .core import setup
1111
1212with open ('requirements.txt' ) as f :
13- requires = f .readlines ()
13+ requires = f .readlines ()
1414if sys .version_info [0 ] == 2 and sys .version_info [1 ] <= 6 :
1515 tests_require = ['unittest2' ]
1616 test_command = ['unit2' , 'discover' ]
2424
2525class RunUnitTests (Command ):
2626 """ run unit tests """
27-
27+
2828 user_options = []
2929 description = __doc__ [1 :]
3030
3131 def initialize_options (self ):
3232 pass
33-
33+
3434 def finalize_options (self ):
3535 pass
36-
36+
3737 def run (self ):
3838 import subprocess
3939 errno = subprocess .call (test_command )
4040 raise SystemExit (errno )
41-
41+
4242class RunUnitTestsCoverage (Command ):
4343 """ run unit tests and report on code coverage using the 'coverage' tool """
44-
44+
4545 user_options = []
4646 description = __doc__ [1 :]
4747
4848 def initialize_options (self ):
4949 pass
50-
50+
5151 def finalize_options (self ):
5252 pass
53-
53+
5454 def run (self ):
5555 import subprocess
5656 errno = subprocess .call (coverage_command )
@@ -60,14 +60,14 @@ def run(self):
6060
6161setup (name = 'python-gsmmodem-new' ,
6262 version = '{0}' .format (VERSION ),
63- description = 'Control an attached GSM modem: send/receive SMS messages, handle calls, etc' ,
63+ description = 'Control an attached GSM modem: send/receive SMS messages, handle calls, etc' ,
6464 license = 'LGPLv3+' ,
6565 author = 'Francois Aucamp' ,
6666 author_email = 'francois.aucamp@gmail.com' ,
67-
67+
6868 url = 'https://github.com/babca/python-gsmmodem' ,
6969 download_url = 'https://github.com/babca/python-gsmmodem/archive/{0}.tar.gz' .format (VERSION ),
70-
70+
7171 long_description = """\
7272 python-gsmmodem is a module that allows easy control of a GSM modem attached
7373to the system. It also includes a couple of useful commandline utilities for
@@ -92,9 +92,9 @@ def run(self):
9292- identify-modem.py: simple utility to identify attached modem. Can also be used to
9393 provide debug information used for development of python-gsmmodem.
9494""" ,
95-
95+ long_description_content_type = 'text/markdown' ,
9696 classifiers = ['Development Status :: 4 - Beta' ,
97- 'Environment :: Console' ,
97+ 'Environment :: Console' ,
9898 'Intended Audience :: Developers' ,
9999 'Intended Audience :: Telecommunications Industry' ,
100100 'License :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)' ,
@@ -109,7 +109,7 @@ def run(self):
109109 'Topic :: Terminals :: Serial' ,
110110 'Topic :: Utilities' ],
111111 keywords = ['gsm' , 'sms' , 'modem' , 'mobile' , 'phone' , 'usb' , 'serial' ],
112-
112+
113113 packages = ['gsmmodem' , 'gsmtermlib' ],
114114 package_dir = {'gsmtermlib' : 'tools/gsmtermlib' },
115115 scripts = ['tools/gsmterm.py' , 'tools/sendsms.py' , 'tools/identify-modem.py' ],
0 commit comments