Date: Thu, 26 Jan 2006 20:15:21 +0000 From: Matthew Seaman <m.seaman@infracaninophile.co.uk> To: Graham Bentley <gbentley@uk2.net> Cc: freebsd-questions@freebsd.org Subject: Re: Elegant delete of word ~tmp files in all sub / dirs Message-ID: <43D92DD9.1080304@infracaninophile.co.uk> In-Reply-To: <000901c622b2$03b3dcc0$0807a8c0@admin> References: <20060126081925.5085916A443@hub.freebsd.org> <000901c622b2$03b3dcc0$0807a8c0@admin>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
Graham Bentley wrote:
> Hi All,
>
> I once found a very elegant method of recursively
> removing all the word ~tmp files on our Samba
> server (many hundereds of subs)
>
> It involved find rm xargs and some {}
>
> It worked very quickly indeed. I have tried to
> find this again but cant and have used alternatives
> that are alot slower.
>
> Any CLI Gurus point me in the path of enlightenment ?
find /your/file-system -type f -name '*~tmp*' -print0 | xargs -0 rm -f
or something like that.
Cheers,
Matthew
--
Dr Matthew J Seaman MA, D.Phil. 7 Priory Courtyard
Flat 3
PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate
Kent, CT11 9PW
[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFD2S3Z8Mjk52CukIwRA6vPAJ9s5dO98vgaTDCLr/DPa4FLSnyBdgCeMBxO
gKk0IVB+aAucabT8S4o8o9s=
=vpbj
-----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?43D92DD9.1080304>
