Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 6 Apr 2009 21:09:24 +0000 (UTC)
From:      Anton Yuzhaninov <citrin@citrin.ru>
To:        freebsd-questions@freebsd.org
Subject:   Re: How to remove all files with a certain extension
Message-ID:  <grdr24$lag$2@ger.gmane.org>
References:  <5BF30BAA-2B35-46C8-8257-56B077D00A8C@identry.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 6 Apr 2009 16:57:39 -0400, John Almberg wrote:
JA> This is a real newbie question, but I can't figure it out...
JA> 
JA> I want to remove all .tar files from a directory tree. I think  
JA> something like the following should work, but I must have something  
JA> wrong, because it doesn't:
JA> 
JA> find . -name *.tar -exec rm /dev/null {} \;

find . -type f -name '*.tar' -delete

-- 
 Anton Yuzhaninov




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?grdr24$lag$2>