Xref: utzoo comp.unix.xenix:6008 comp.unix.questions:13635 comp.unix.wizards:16162 Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!husc6!osf!rdb From: rdb@osf.OSF.ORG (Ron Birnbaum) Newsgroups: comp.unix.xenix,comp.unix.questions,comp.unix.wizards Subject: Re: Ugly file name Keywords: rm cat mv regexp Message-ID: <881@osf.OSF.ORG> Date: 16 May 89 19:25:39 GMT References: <128@tdl.UUCP> <7170@bsu-cs.bsu.edu> <1614@auspex.auspex.com> <448@hsi86.hsi.UUCP> <1233@oswego.Oswego.EDU> Reply-To: rdb@osf.org (Ron Birnbaum) Distribution: usa Organization: Open Software Foundation Lines: 20 In article <1233@oswego.Oswego.EDU> stjohn@oswego.oswego.edu.Oswego.EDU (Dave St. John) writes: >In article <448@hsi86.hsi.UUCP> derek@hsi86.UUCP (Derek Lee-Wo) writes: >> >>This doesn't work for filenames that start with a minus. eg -badfile >>Anyone know how to erase such files with whipping up a short C program? > >RTM, it says to use a - for file names that begin with a -. >So you would type > % rm - -badfile Or else you can remove another file with -badfile on the same line: rm another -badfile will remove the files 'another' and '-badfile'. >US Mail: Dave St. John -Ron Birnbaum rdb@osf.org