autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: set owner/group on FreeBSD


From: Paul Eggert
Subject: Re: set owner/group on FreeBSD
Date: Thu, 19 Sep 2002 16:51:01 -0700 (PDT)

> From: Bill Moseley <address@hidden>
> Date: Thu, 19 Sep 2002 15:01:50 -0700

> >is there some command you can issue after the mkdir but before the
> >touch, which will fix the problem?
> 
> I'm not sure.  Could chgrp the file in /tmp before moving, I suppose, but
> is that portable?

We can ignore the error if it is not.  E.g., something like this?

tmp=$TMPDIR/cs123456
(umask 077 && mkdir $tmp) || exit
(set X`ls -dln` && chgrp $4 $tmp) 2>/dev/null
touch $tmp/foo
mv $tmp/foo .




reply via email to

[Prev in Thread] Current Thread [Next in Thread]