Date: Fri, 20 Sep 2002 10:08:11 +0200 (CEST) From: Oliver Fromme <olli@secnetix.de> To: freebsd-questions@FreeBSD.ORG Subject: Re: weird files Message-ID: <200209200808.g8K88Bc7094699@lurza.secnetix.de> In-Reply-To: <20020920023650.65864.qmail@web14805.mail.yahoo.com>
next in thread | previous in thread | raw e-mail | index | archive | help
mingo lu <freebiebsd@yahoo.com> wrote: > i have two weird files under my home directory; one is > file named "-bash.gmon" and another one is "xy ds". > how could i remove them? rm just won't work ... Filenames that start with a dash can be disarmend by prepending the directory (just "./" if it's the current working directory). Spaces can be used by enclosing the name in quotes. Thus: rm ./-bash.gmon "xy ds" Or use shell wildcards. In this case use -i, so you don't accidentally remove more files than you intended (unless you're sure that no other files will match): rm -i ?bash.gmon xy?ds If you use the zsh shell, it has the nice feature that it expands expressions containing wildcards when you press the TAB key, including proper quoting. I have made a habit of using that feature when appropriate, so I see exactly which files will be affected before pressing the ENTER key. That has saved my day a few times. ;-) Regards Oliver -- Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "All that we see or seem is just a dream within a dream" (E. A. Poe) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200209200808.g8K88Bc7094699>