[PATCH] allow empty files creation with install

Garrett Cooper gcooper at FreeBSD.org
Sat Jul 17 21:22:49 UTC 2010


On Sat, Jul 17, 2010 at 6:34 AM, joris dedieu <joris.dedieu at gmail.com> wrote:
> This patch add a -t switch to install(3). This is a small feature for
> lazy sysadmins.
>
> before :
>
> touch /usr/home/foo/.history /usr/home/foo/.bash_history
> chown foo /usr/home/foo/.history /usr/home/foo/.bash_history
> chmod 600 /usr/home/foo/.history /usr/home/foo/.bash_history
> chflags sappend /usr/home/foo/.history /usr/home/foo/.bash_history
>
> after :
>
> install -o foo -g foo -m 600 -f sappend /usr/home/foo/.history
> /usr/home/foo/.bash_history

    And why isn't creating a 4-command bourne shell script which does
all of these operations an option? install is used a lot in the build
process both on the FreeBSD side and the ports side, so I'd prefer if
it was as minimalist as possible.
Thanks,
-Garrett


More information about the freebsd-hackers mailing list