Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!columbia!topaz!ll-xn!nike!ucbcad!ucbvax!hplabs!tektronix!tekgen!tektools!jerryp From: jerryp@tektools.UUCP (Jerry Peek) Newsgroups: net.unix Subject: Re: Warning about rm (really the shell) Message-ID: <1319@tektools.UUCP> Date: Tue, 29-Jul-86 13:09:46 EDT Article-I.D.: tektools.1319 Posted: Tue Jul 29 13:09:46 1986 Date-Received: Thu, 31-Jul-86 07:03:50 EDT References: <79@wanginst.UUCP> Reply-To: jerryp@tektools.UUCP (Jerry Peek) Distribution: net Organization: Tektronix, Inc., Beaverton, OR. Lines: 26 [Moved from net.unix-wizards...] In article <79@wanginst.UUCP>, tupper@wanginst.UUCP (John Tupper) writes: > Today I ran the following command: > rm -r /student/tupper/.dead/.* > The shell expanded my wild card to include /student/tupper/.dead/. > and (this is the important part -->) /student/tupper/.dead/.. (that's > "dot-dot")! For just that reason, I've gotten in the habit of using .??* instead of just .* One problem: .??* doesn't match things with names like .x -- but I usually don't use names that short, anyhow. To match all files and directories, try (with csh only): {*,.??*} as in: rm -r /student/tupper/.dead/{*,.??*} --Jerry Peek, Tektronix, Inc. US Mail: MS 74-222, P.O. Box 500, Beaverton, OR 97077 uucp: {allegra,decvax,hplabs,ihnp4,ucbvax}!tektronix!tektools!jerryp CS,ARPAnet: jerryp%tektools@tektronix.csnet Phone: +1 503 627-1603