[PATCH 6/9] Add action classes for container member set management.

Brian C. Lane bcl at redhat.com
Tue Mar 25 03:23:41 UTC 2014


On Mon, Mar 24, 2014 at 08:08:14AM -0400, Anne Mulhern wrote:
> 
> I tend to prefer not associating the indentation of the keys so closely with the
> number of characters in the variable to which they are assigned.
> If you need to change action_strings to device_action_strings and you want to keep
> indentation that screws up the git history of every key value pair.
> 
> Which is better:
> 
> action_strings = { ACTION_TYPE_NONE: "None",
>    ACTION_TYPE_DESTROY: "Destroy",
>    ...etc.
> or
> 
> action_strings = \
>    { ACTION_TYPE_NONE: "None",
>      ACTION_TYPE_DESTROY: "Destroy",
>      ...etc.
> 
> ?
> 
> I've tended to do the first...but now I'm thinking that the second is better.

I think worrying about git history is getting pretty close to painting
sheds -- But IMO the 2nd is weird, you just started the line and now you
are continuing it? The first is okish, but my preference is to just
indent them all to the same level as the first. That makes it easy for
your eye to scan the list.

-- 
Brian C. Lane | Anaconda Team | IRC: bcl #anaconda | Port Orchard, WA (PST8PDT)


More information about the anaconda-patches mailing list