mirror of
https://github.com/robmcmullen/atrcopy.git
synced 2024-12-27 08:29:24 +00:00
Added error checking for python version & clarified README
This commit is contained in:
parent
956fd58294
commit
68b9e95512
@ -22,11 +22,8 @@ Supported Python versions:
|
||||
|
||||
* Python 3.6 (and later)
|
||||
|
||||
If you need Python 2 support, ``atrcopy`` 6.5 and earlier supports:
|
||||
|
||||
* Python 2.7
|
||||
* Python 3.5
|
||||
* Python 3.6
|
||||
If you need Python 2 support, ``atrcopy`` 6.5 and earlier supports Python 2.7,
|
||||
which you can install with ``pip install "atrcopy<7.0"``
|
||||
|
||||
Dependencies
|
||||
------------
|
||||
|
@ -1,6 +1,12 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
if __name__ == "__main__":
|
||||
import sys
|
||||
if sys.version_info < (3, 6, 0):
|
||||
print("atrcopy requires Python 3.6 or greater to run; this is Python %s" % ".".join([str(v) for v in sys.version_info[0:2]]))
|
||||
if sys.version_info[0] == 2:
|
||||
print("Python 2 support was dropped with atrcopy 7.0, so you can either use:\n\n pip install \"atrcopy<7.0\"\n\nto install a version compatible with Python 2, or install Python 3.6 or higher.")
|
||||
else:
|
||||
import atrcopy
|
||||
|
||||
atrcopy.run()
|
||||
|
Loading…
Reference in New Issue
Block a user