How to remove a file whose name begins with a dash

Paul Dow CRI-UK paul at sequoia.cray.com
Wed Mar 6 23:32:25 AEST 1991


In article <HOPKINS.91Mar6021429 at poit.sun.com>, hopkins at sun.com (Don Hopkins) writes:
|> The heavily encoded contents of this message may be used to effectivly
|> remove a file whose name begins with a dash.  It's like the garbage
|> can paradigm of the Mac, but the other way around: you drop this file
|> onto other files to dispose of them! Please be careful! No warranty
|> expressed or implied, not responsible for any damages, etc...
|> 
|> 	-Don
|> 
|> Instructions: 
|> 
|> # touch ./-rf
|> # ls -l ./-rf
|> -rw-rw-r--  1 root            0 Mar  6 01:56 ./-rf
|> # ls -l README
|> -rw-rw-r--  1 root           34 Mar  6 01:56 README
|> # mv README ./-rf
|> # cat ./-rf
|> README: No such file or directory
|> # echo Volia!
|> Volia!
|> 

OK, I may be being dumb, but it looks to me as if the "README" file
contains the text "README: No such file or directory".  I know the 
"How to remove a file..." discussion has been going on for some time,
and that some people, will tire of it.  Was this submission intended
to be helpful or just to confuse some poor critter who did not know much
about the system ?

Paul.



More information about the Comp.unix.wizards mailing list