Hi,
actually this is not really a serious current problem of mine, but I would really like to know the proper way. Here's the situation: Yesterday I downloaded a file which name began with a dash ('-'). And after I got the feeling that I didn't want this file any more, I tried to delete it and recognized, that this was a much tougher task than I thought: The original name was quite long so let's abstract a little bit and assume it was called '-bla'. I think I'm quite familiar with linux command line and bash but this is going to drive me crazy. My first try was:
$ rm -bla
of course this didn't work and I recognized it yet before I pressed enter. And then the trouble began..., I tried all of these:
Code:
$ rm "-bla"
$ rm \-bla
$ rm "\-bla"
$ rm ?bla
$ rm [-]bla
$ rm [\-]bla
$ rm *bla
... and I guess even some more, but none of them worked. I'm sure there is a vary bold solution that just doesn't come in my mind, so if you have an idea let me know. Btw, graphical file-browsers like nautilus don't have any problem with this, they create and delete such files like a breeze..., but how?
-flesym