On Tue, 11 Jun 2002, Jeff Waugh wrote:

> > I have all my users home directories under /home/popusers/
> > it turns out I may need to add a directory and set permissions on it in each
> > users directory (there are over 900 of them).
> > Is there a simple way to do this? Say the directory needs to be called
> > 'attach' in an existing 'dot' directory.
>
> cd /home
> for i in *; do
>     mkdir -p $i/dot/attach;
>     chown -R $i:$i $i/dot/attach;
>     chmod -R 0755 $i/dot/attach;
> done

Bugga. Finally, a scripting question I know how to answer, and Jeff beats
me to it.

:-)

DaZZa

-- 
SLUG - Sydney Linux User's Group - http://slug.org.au/
More Info: http://lists.slug.org.au/listinfo/slug

Reply via email to