Subject: Re: Strange shell interaction
To: Mike Cheponis <mac@Wireless.Com>
From: Tim Lupfer <tlupfer@online.no>
List: netbsd-help
Date: 07/31/2001 02:46:01
add a "--" and you should be fine regardless of what shell you're using.

$ ls
- test  Mail/  files/  www/
$ rm -- "- test"
$ ls
Mail/  files/  www/
$

On Tue, 31 Jul 2001 00:29:54 -0700 (PDT)
Mike Cheponis <mac@Wireless.Com> wrote:

# I have a funny-named file that apparently got there from an "mput" from
# a Windows machine.  The file is:
# 
# -X-Ray Spex- Oh Bondage.mp3
# 
# Now, my problem is that I am trying to rename this file to remove the
# "-"
# character at the beginning.
# 

[snipped failed attempts ;P]

# I suppose I can do this with Emacs dired, but the fact that this is a
# problem at all seems to point to a fundamental issue of the shell. (zsh
# here)
# (Or my lack of understanding!  Hence this email!)
# 
# But, doesn't this behavior violate The Principle of Least Astonishment?
# 
# 
# Thanks, gang, as usual.  -Mike

-- 
tim lupfer       tlupfer@online.no
gnupg 0x4905183C (pgpkeys.mit.edu)
http://home.no.net/~tlupfer

When we are planning for posterity, we ought to remember that virtue is
not hereditary.
		-- Thomas Paine