Re: A handy utility (at least for me)



Rick C. Petty wrote:
Mario Lobo wrote:
My /usr/ports directory was occuping 24 gigs, of which 20 was just from the
'work' directories !

You should type "make clean" more often. ;-)

Removing them one by one was a pain so I wrote this little utility to wipe
them off.

I find that the following command works just fine for me:

find /usr/ports -type d -name work -prune -print -delete

The following is probably the most efficient solution.
It doesn't run into all subdirectories (and works with
an arbitrary numebr of subdirectories).

cd /usr/ports; echo */*/work | xargs rm -rf

Best regards
Oliver

--
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing
Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd
Any opinions expressed in this message may be personal to the author
and may not necessarily reflect the opinions of secnetix in any way.

"I started using PostgreSQL around a month ago, and the feeling is
similar to the switch from Linux to FreeBSD in '96 -- 'wow!'."
-- Oddbjorn Steffensen
_______________________________________________
freebsd-hackers@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@xxxxxxxxxxx"



Relevant Pages