I'd like to create a script that handles a number of verbs with mandatory and 
/or optional parameters like listed in the table below.

Can ARGPARSE do this and how?

Thanks for all help!





Script      Verb        Mandatory parameters                         Optional 
parameters 
------------------------------------------------------------------------------
myprog.py   list        ---                                          verbose 

myprog.py   add         sid(string), type (string), memory (int)     comment 
(string), autostart (bool, default=TRUE)

myprog.py   memory      sid (string), memory (integer)

myprog.py   comment     sid(string), comment (string)

myprog.py   restore     sid(string), srcpath (string)

myprog.py   backup      sid(string), dstpath(string) 

myprog.py   remove      sid (string)
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to