File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -100,16 +100,17 @@ def _execute(args):
100
100
101
101
def main (arv = None ):
102
102
"""lambda-uploader command line interface."""
103
- # Check for Python 2.7 (required for Lambda)
104
- if not ( sys .version_info [0 ] == 2 and sys .version_info [1 ] == 7 ) :
105
- raise RuntimeError ('lambda-uploader requires Python 2.7' )
103
+ # Check for Python 2.7 or later
104
+ if sys .version_info [0 ] < 3 and not sys .version_info [1 ] == 7 :
105
+ raise RuntimeError ('lambda-uploader requires Python 2.7 or later ' )
106
106
107
107
import argparse
108
108
109
109
parser = argparse .ArgumentParser (
110
- version = ('version %s' % lambda_uploader .__version__ ),
111
110
description = 'Simple way to create and upload python lambda jobs' )
112
111
112
+ parser .add_argument ('--version' , '-v' , action = 'version' ,
113
+ version = lambda_uploader .__version__ )
113
114
parser .add_argument ('--no-upload' , dest = 'no_upload' ,
114
115
action = 'store_const' , help = 'dont upload the zipfile' ,
115
116
const = True )
You can’t perform that action at this time.
0 commit comments