sean finney on Thu, 10 Oct 2002 09:50:05 -0400


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

Re: [PLUG] list by owner


On Thu, Oct 10, 2002 at 06:08:33AM -0400, Paul wrote:
> How could I sort a list of files by owner?  I have a bunch of session 
> files in /tmp that I want to delete without affecting files that I don't 
> own.

how about

find /tmp -type -f -user username

that prints everything in /tmp that's a file owned by username.  you
could also take this a step further and delete them in the same
command:

find /tmp -type -f -user username -exec rm \{\} \;

hth
--sean

Attachment: pgpRFvXNBK1XA.pgp
Description: PGP signature