On Fri, Jul 20, 2012 at 6:23 PM, Ian Stakenvicius <a...@gentoo.org> wrote: > enewuser won't create a home directory if you don't specify one (ie > it's set to /dev/null or it's unset). Also, you can use 'esethome' to > set the home directory to an existing directory. With both of these > options I don't think that a --do-not-create-homedir option is necessary.
Well, with this approach there will now be three separate code blocks, just to create user's home directory: enewuser in pkg_preinst(), fperms / fowners in src_install(), and esethome in pkg_postinst(). Changing permissions as suggested by Kevin Pyle [1] looks more attractive then, since everything is in one code block. Moreover, if you want to keep the same semantics with esethome (only set the home directory when the user is created), you will need to keep a variable across ebuild phases. Also, it looks like pkg_postinst() is on the way out [2]. All-in-all, I think that a --do-not-create-homedir (or a shorter equivalent) is a good idea. [1] https://bugs.gentoo.org/show_bug.cgi?id=395961#c1 [2] http://archives.gentoo.org/gentoo-dev/msg_ed43ed0df212ea26ef953fb061e9e860.xml -- Maxim Kammerer Liberté Linux: http://dee.su/liberte