Closed lefty01 closed 8 years ago
Looks like a great change! I'll review this in detail in a little bit, but I like the idea of using argparse. Thank you!
:+1: ! Much nicer interface, and nice to have --help as well.
Sorry I'm just now getting around to reviewing this. I've been busy working on my dissertation! In any case, I made a few minor changes, mainly just to be consistent with the rest of the code. Feel free to comment on any of my proposed changes. Likewise, I have a question or two I'll comment on in-line. Thanks again!
Merged. Thanks!
using argparse which changes the existing interface. interface could be kept in place (i.e. requiring the 1, 2, or three arguments) but decided it might be better to have these switches so one could for example only specify a directory without need to to have a count and format. eg. ./gcexport.py -d MyActivities/ instead of ./gcexport.py 1 origin MyActivities/ as additional benefit help page (-h|--help) is automatically generated. in case of format origin one can use -u|--unzip to unzip the zip file and then the .zip will be removed (the check for existing file is extended for the unzipped .fit filename)
feel free to merge some stuff or ignore if you not like it ;)