[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Fab-user] put() and command line args
From: |
Christian Vest Hansen |
Subject: |
Re: [Fab-user] put() and command line args |
Date: |
Mon, 20 Oct 2008 23:21:00 +0200 |
On Mon, Oct 20, 2008 at 10:51 PM, Jeff Forcier <address@hidden> wrote:
> Or am I getting it wrong somewhere? :)
Riiiight....
>
> def _parse_args(args):
> cmds = []
> for cmd in args:
> cmd_args = {}
> if ':' in cmd:
> cmd, cmd_str_args = cmd.split(':', 1)
> for cmd_arg_kv in cmd_str_args.split(','):
> k, _, v = partition(cmd_arg_kv, '=')
> cmd_args[k] = (v % ENV)
... here, in this last line.
If there are no values at command-line, then the call to partition
will leave 'v' with the empty string, causing cmd_args[k] to be "".
Also, I verified my writings before pressing send :o)
--
Venlig hilsen / Kind regards,
Christian Vest Hansen.