Re: [Cloud-init-dev] [Merge] ~daniel-thewatkins/cloud-init/+git/cloud-init:useradd into cloud-init:master

2019-08-12 Thread Dan Watkins
On Mon, Aug 12, 2019 at 02:31:18PM -, Ryan Harper wrote:
> The method is call add_user and the variables match the method.

If the variable matched the method, I'd expect it to be add_user_cmd.
I'd be fine with that, if that's what you would prefer?

> So now we have
> 
> def add_user()
>useradd_cmd = 
> 
> Isn't this the same confusion?

I don't think so; the name of the command we do actually use is
hardcoded in a string literal later on that line:

useradd_cmd = ['useradd', ...]

> The command to add a user could be something else.

Not without code changes, which I would expect to also change the
variable name.

> In cloudinit/distros/freebsd.py for example, the adduser_cmd , is 'pw
> useradd'.

Right, I didn't touch the variable name there.

-- 
https://code.launchpad.net/~daniel-thewatkins/cloud-init/+git/cloud-init/+merge/371203
Your team cloud-init commiters is requested to review the proposed merge of 
~daniel-thewatkins/cloud-init/+git/cloud-init:useradd into cloud-init:master.

___
Mailing list: https://launchpad.net/~cloud-init-dev
Post to : cloud-init-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~cloud-init-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Cloud-init-dev] [Merge] ~daniel-thewatkins/cloud-init/+git/cloud-init:useradd into cloud-init:master

2019-08-12 Thread Ryan Harper
The method is call add_user and the variables match the method.

So now we have

def add_user()
   useradd_cmd = 

Isn't this the same confusion?

The command to add a user could be something else. In 
cloudinit/distros/freebsd.py for example, the adduser_cmd , is 'pw useradd'.

-- 
https://code.launchpad.net/~daniel-thewatkins/cloud-init/+git/cloud-init/+merge/371203
Your team cloud-init commiters is requested to review the proposed merge of 
~daniel-thewatkins/cloud-init/+git/cloud-init:useradd into cloud-init:master.

___
Mailing list: https://launchpad.net/~cloud-init-dev
Post to : cloud-init-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~cloud-init-dev
More help   : https://help.launchpad.net/ListHelp