Complete.Org: Mailing Lists: Archives: discussion: March 2000:
[aclug-L] Re: Working on file names
Home

[aclug-L] Re: Working on file names

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: discussion@xxxxxxxxx
Subject: [aclug-L] Re: Working on file names
From: Carl D Cravens <raven@xxxxxxxxxxx>
Date: Wed, 22 Mar 2000 10:43:43 -0600 (CST)
Reply-to: discussion@xxxxxxxxx

On Wed, 22 Mar 2000, Wayne White wrote:

> I need to remove the blank spaces from a bunch of file
> names (MP3z). I know if it was a list in a text file
> that it would be a simple thing to script bash to do it.
> What I don't know is how to get it to work on the file
> name themselves, or if that can even be done. Would
> anyone like to weigh in with advice?

In bash/ksh, cd to the directory containing the files, then...

for n in *; do mv "$n" `echo $n |tr -d " "`; done

--
Carl D Cravens (raven@xxxxxxxxxxx)
I buy you sigs, and I buy you sigs, but all you do is eat the bits!


-- This is the discussion@xxxxxxxxx list.  To unsubscribe,
visit http://tmp2.complete.org/cgi-bin/listargate-aclug.cgi


[Prev in Thread] Current Thread [Next in Thread]