Re: [Hampshire] how do I delete a file named -n

Top Page

Reply to this message
Author: Chris Liddell
Date:  
To: Hampshire LUG Discussion List
Subject: Re: [Hampshire] how do I delete a file named -n
At 14:43 31/01/2007 +0000, you wrote:

>I have managed to create a file named "-n" without the quotes. Any clues
>on how to delete it from the command line?
>I've tried
>rm -n
>rm "-n"
>rm '-n'
>rm `-n`


If there aren't other files it would impact, you could try:

rm ?n

That should match any file whose name contains exactly two characters, the
second of which is "n".

Chris


--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.432 / Virus Database: 268.17.17/661 - Release Date: 30/01/2007 23:30