From owner-freebsd-questions Mon Dec 17 14: 6:18 2001 Delivered-To: freebsd-questions@freebsd.org Received: from mail8.carolina.rr.com (fe8.southeast.rr.com [24.93.67.55]) by hub.freebsd.org (Postfix) with ESMTP id C661D37B425 for ; Mon, 17 Dec 2001 14:05:48 -0800 (PST) Received: from snafu.enterit.com ([66.57.159.198]) by mail8.carolina.rr.com with Microsoft SMTPSVC(5.5.1877.537.53); Mon, 17 Dec 2001 16:08:46 -0500 Message-Id: <5.1.0.14.0.20011217163005.034eacc0@mail.enterit.com> X-Sender: jconner@enterit.com@mail.enterit.com X-Mailer: QUALCOMM Windows Eudora Version 5.1 Date: Mon, 17 Dec 2001 16:32:39 -0500 To: freebsd-questions@FreeBSD.ORG From: Jim Conner Subject: Re: rm a file named "-l"? ;-) Cc: swear@blarg.net (Gary W. Swearingen), rene@xs4all.nl In-Reply-To: <5.1.0.14.0.20011217162250.030b2cc8@mail.enterit.com> References: <20011217111215.I21241@xs4all.nl> <20011217111215.I21241@xs4all.nl> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG At 16:23 12.17.2001 -0500, Jim Conner wrote: >At 12:49 12.17.2001 -0800, Gary W. Swearingen wrote: >>One "last resort" for problem filenames of any kind is to do >> >> \rm -i * .* >> >>in it's directory, and then be sure to answer "n" for everything >>but the one you want to delete. (You usually don't need the ".*".) >> >>To Unsubscribe: send mail to majordomo@FreeBSD.org >>with "unsubscribe freebsd-questions" in the body of the message > > >A quicker way would be to use unlink(1) > >- Jim Thought I would give an example for clarity: [notjames@njkwan ~]$ echo "blah" > -f [notjames@njkwan ~]$ ls -f GNUstep/ bin/ images/ mail/ nsmail/ ports-supfile seti/ src/ tmp/ [notjames@njkwan ~]$ unlink -f [notjames@njkwan ~]$ ls GNUstep/ bin/ images/ mail/ nsmail/ ports-supfile seti/ src/ tmp/ [notjames@njkwan ~]$ >Philosophy is for those who have nothing better to do than wonder >why philosophy is for those who have nothing better to do than... > > > > >To Unsubscribe: send mail to majordomo@FreeBSD.org >with "unsubscribe freebsd-questions" in the body of the message - Jim Philosophy is for those who have nothing better to do than wonder why philosophy is for those who have nothing better to do than... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message