Subject: Re: mk/install/usergroup and FreeBSD and DragonFly
To: Jeremy C. Reed <>
From: Roland Illig <>
List: tech-pkg
Date: 09/07/2005 19:57:38
Jeremy C. Reed wrote:
> On Wed, 7 Sep 2005, Johnny Lam wrote:
>> Actually, it's probably not so bad just to have shell functions 
>> defined in a file that get directly inserted into the head of the 
>> +USERGROUP script.  That would remove the need for the extra helper 
>> scripts.  The file defining the shell functions useradd() and 
>> groupadd() would be unique to each platform.
> An untested idea for NetBSD:
> # useradd user group descr home shell [userid]
> useradd()
> {

I would prefer saving the useradd() functions in separate files. This 
keeps them more readable when being integrated into the +USERGROUP script.

What about mk/install/usergroup.${PLATFORM}.sh?

I wouldn't call the function "useradd". It might lead to confusion, as 
there is already a tool named useradd(1) on some platforms. Maybe 
useradd_fn or pkgsrc_useradd.