Re: Unable to del an OS file with special char - need ideas

From: William Robertson <william_at_williamrobertson.net>
Date: Wed, 09 Jul 2008 19:26:07 +0100
Message-ID: <487502BF.6080705@williamrobertson.net>


One way:

    $ touch C.dat
    $ echo > -C
    $ ls -l | grep C
    -rw-r--r--     1 williamr  staff        1 Jul  9 19:21 -C
    -rw-r--r--     1 williamr  staff        0 Jul  9 19:21 C.dat

    $ rm nosuchfile -C
    rm: nosuchfile: No such file or directory

    $ ls -l | grep C
    -rw-r--r-- 1 williamr staff 0 Jul 9 19:21 C.dat

Another way:

    find . -name -C -exec rm {} \;

-----Original message-----
From: vikram singh
Date: 9/7/08 19:04
>
> Hi All,
>
> I have this file by name '-C' created by mistake. I am unable to
> delete this. Any ideas?
>
> /[oraapp_at_greece app]# ls -l
> total 457636
> -rw-r--r-- 1 oraapp oraapp 435824640 Oct 4 2007 -C
> -rw------- 1 oraapp oraapp 32271367 Oct 4 2007 nohup.out/
>
> How can i delete the '-C' file?
>
> Thanks,
>
> Vikram
>

--
http://www.freelists.org/webpage/oracle-l
Received on Wed Jul 09 2008 - 13:26:07 CDT

Original text of this message