Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] How to cope with strange filenames in bash?
- Date: Tue, 3 Jul 2007 04:05:19 -0400
- From: Scott Robbins <scottro@example.com>
- Subject: Re: [tlug] How to cope with strange filenames in bash?
- References: <20070703072842.GG3938@wasi.karlov.mff.cuni.cz>
- User-agent: mutt-ng/devel-r804 (FreeBSD)
On Tue, Jul 03, 2007 at 09:28:42AM +0200, Michal Hajek wrote: > > Hello, > > a simple question: > > how do I cope in bash with filenames containing "-" character (i.e. > dash) ? > > In my case, I have downloaded this file: > -umai-Doremi--Kenichi-10--B36CAB67-.avi.part1.rar > > What is so special about it? This: > Depending upon the command, one or the other of these should work. mv ./-umai-Doremi-blah-blah With some other commands (though not mv) prefacing the command with another - will work. touch - -stupidname rm - -stupidname The ./ seems to work in more circumstances. (Of course, you have to be in the directory containing the file.) Actually, if you're in a directory above it, using tab completion might work. mkdir test touch test/-stupidname mv test/- <hit tab key, it will complete -stupidname> bettername ls test bettername >From the directory containing the rar file, say the directory's name is rar cd ../ -- Scott Robbins PGP keyID EB3467D6 ( 1B48 077D 66F6 9DB0 FDC2 A409 FA54 EB34 67D6 ) gpg --keyserver pgp.mit.edu --recv-keys EB3467D6 Buffy: See, this is a school. And we have students and they check out books and then they learn things. Giles: I was beginning to suspect that was a myth.
- References:
- [tlug] How to cope with strange filenames in bash?
- From: Michal Hajek
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] [Announcement] TLUG Technical Meeting 2007-7-14
- Next by Date: Re: [tlug] How to cope with strange filenames in bash?
- Previous by thread: [tlug] [SOLVED] How to cope with strange filenames in bash?
- Next by thread: Re: [tlug] How to cope with strange filenames in bash?
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links