[ale] chown options

Jason Day jasonday at worldnet.att.net
Wed Jan 19 13:45:08 EST 2005


On Wed, Jan 19, 2005 at 10:57:22AM -0500, Geoffrey wrote:
> Ryan Fish wrote:
> >Hello all,
> >
> >Is it possible to perform a recursive chown but exclude one
> >particular directory?  If so, how would it be done?  I have yet to
> >find any info on this online so I figured I would ask...
> 
> find . -print|grep -v $DIRECTORY_TO_EXCLUDE|xargs -n 10 chown foo.bar

A slightly faster way:

chown -R foo.bar `find . -type d -print | grep -v $DIRECTORY_TO_EXCLUDE`

-- 
Jason Day                                       jasonday at
http://jasonday.home.att.net                    worldnet dot att dot net
 
"Of course I'm paranoid, everyone is trying to kill me."
    -- Weyoun-6, Star Trek: Deep Space 9



More information about the Ale mailing list