feat(CLI):required arg parsing + first doit() call

We are parsing required scalar values and handle parse-errors correctly,
to the point were we make a simple, non-upload doit() call.

It shows that we seem to build invalid calls, for now,but that's nothing
we can't fix once the time is ripe.

Next goals will be related to finalizing the argument parsing code.

Fixes #60
This commit is contained in:
Sebastian Thiel
2015-04-14 17:17:21 +02:00
parent d6919f1eb6
commit e34e24e049
7 changed files with 87 additions and 18 deletions

View File

@@ -81,6 +81,10 @@ def ident(name):
def cmd_ident(name):
return 'cmd_' + ident(name)
# Similar to cmd_ident, but for arguments
def arg_ident(name):
return 'arg_' + ident(name)
# Returns identifier for method dealing with options for the given resource-method pair
def call_method_ident(resource, method):
return '_%s_%s' % (ident(resource), ident(method))