Patchwork [V3,0/3] Add a method for image level user/group configuration

login
register
mail settings
Submitter Qi.Chen@windriver.com
Date July 11, 2013, 11:11 a.m.
Message ID <cover.1373540849.git.Qi.Chen@windriver.com>
Download mbox
Permalink /patch/53495/
State New
Headers show

Pull-request

git://git.pokylinux.org/poky-contrib ChenQi/user_group_settings

Comments

Qi.Chen@windriver.com - July 11, 2013, 11:11 a.m.
From: Chen Qi <Qi.Chen@windriver.com>

This patchset mainly does two things:
1. code refactor to avoid code duplication
2. add a method for image level user/group configuration

The following changes since commit a63229917a5708de2d161aba0d67168ce0da6365:

  meta-yocto-bsp: update reference board SRCREVs (2013-07-10 09:45:51 +0100)

are available in the git repository at:

  git://git.pokylinux.org/poky-contrib ChenQi/user_group_settings
  http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=ChenQi/user_group_settings

Chen Qi (3):
  userbase.bbclass: add a new bbclass
  useradd.bbclass: code refactor
  usersettings.bbclass: add a new bbclass

 meta/classes/useradd.bbclass      |  103 ++---------------
 meta/classes/userbase.bbclass     |  230 +++++++++++++++++++++++++++++++++++++
 meta/classes/usersettings.bbclass |   48 ++++++++
 3 files changed, 290 insertions(+), 91 deletions(-)
 create mode 100644 meta/classes/userbase.bbclass
 create mode 100644 meta/classes/usersettings.bbclass
Paul Eggleton - July 11, 2013, 12:49 p.m.
Hi Qi,

On Thursday 11 July 2013 19:11:36 Qi.Chen@windriver.com wrote:
> From: Chen Qi <Qi.Chen@windriver.com>
> 
> This patchset mainly does two things:
> 1. code refactor to avoid code duplication
> 2. add a method for image level user/group configuration
> 
> The following changes since commit a63229917a5708de2d161aba0d67168ce0da6365:
> 
>   meta-yocto-bsp: update reference board SRCREVs (2013-07-10 09:45:51 +0100)
> 
> are available in the git repository at:
> 
>   git://git.pokylinux.org/poky-contrib ChenQi/user_group_settings
>  
> http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=ChenQi/user_group_set
> tings
> 
> Chen Qi (3):
>   userbase.bbclass: add a new bbclass
>   useradd.bbclass: code refactor
>   usersettings.bbclass: add a new bbclass
> 
>  meta/classes/useradd.bbclass      |  103 ++---------------
>  meta/classes/userbase.bbclass     |  230
> +++++++++++++++++++++++++++++++++++++ meta/classes/usersettings.bbclass |  
> 48 ++++++++
>  3 files changed, 290 insertions(+), 91 deletions(-)
>  create mode 100644 meta/classes/userbase.bbclass
>  create mode 100644 meta/classes/usersettings.bbclass

In terms of naming I'd rather see the base class be called useradd_base to
match the naming of similar existing classes. For the new class, I'm not sure
usersettings is really an appropriate name, perhaps something like
"useradd_real" or "useraccount" or something else that more accurately reflects 
what it is for?

Cheers,
Paul
Saul Wold - July 11, 2013, 4 p.m.
On 07/11/2013 05:49 AM, Paul Eggleton wrote:
> Hi Qi,
>
> On Thursday 11 July 2013 19:11:36 Qi.Chen@windriver.com wrote:
>> From: Chen Qi <Qi.Chen@windriver.com>
>>
>> This patchset mainly does two things:
>> 1. code refactor to avoid code duplication
>> 2. add a method for image level user/group configuration
>>
>> The following changes since commit a63229917a5708de2d161aba0d67168ce0da6365:
>>
>>    meta-yocto-bsp: update reference board SRCREVs (2013-07-10 09:45:51 +0100)
>>
>> are available in the git repository at:
>>
>>    git://git.pokylinux.org/poky-contrib ChenQi/user_group_settings
>>
>> http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=ChenQi/user_group_set
>> tings
>>
>> Chen Qi (3):
>>    userbase.bbclass: add a new bbclass
>>    useradd.bbclass: code refactor
>>    usersettings.bbclass: add a new bbclass
>>
>>   meta/classes/useradd.bbclass      |  103 ++---------------
>>   meta/classes/userbase.bbclass     |  230
>> +++++++++++++++++++++++++++++++++++++ meta/classes/usersettings.bbclass |
>> 48 ++++++++
>>   3 files changed, 290 insertions(+), 91 deletions(-)
>>   create mode 100644 meta/classes/userbase.bbclass
>>   create mode 100644 meta/classes/usersettings.bbclass
>
> In terms of naming I'd rather see the base class be called useradd_base to
> match the naming of similar existing classes. For the new class, I'm not sure
> usersettings is really an appropriate name, perhaps something like
> "useradd_real" or "useraccount" or something else that more accurately reflects
> what it is for?
>

I think this is a better approach than what you had orignally.

I agree the naming is not correct currently, useraccount or maybe 
extrausers, also when you rename the class the USER_GROUP_SETTING should 
also be renamed to reflect that, something like EXTRA_USERS_PARAMS or 
USER_ACCOUNT_PARAMS to match the class name.

You also need to provide full documentation on this new variable, please 
send details to Scott Rifenbark.


> Cheers,
> Paul
>