[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]

Re: [LI] How to change the extension of many files at a time



On Fri, Jan 14, 2000 at 05:13:23PM +0530, Binand Raj S. wrote:
> One method is to run the script (in bash):
> 
> for i in *cc; do base=$(basename $i .cc); newname=${base}.cpp; mv $i $newname; done
> 


And a second method is

$  mmv "*.cc" "#1.cpp"

--mvm

> 
> > 
> > > Hi everybody,
> > > I am having many files of .cc extension. Now I want to change the
> > > extension to .cpp. Can I do this at a time without going for each file.
-- 
Do you support 'free software'?  Visit http://mvm.linuxbox.com
Manoj Victor Mathew  (GPG#: 3D96A9B9)
Cochin, India.
--------------------------------------------------------------------
The Linux India Mailing List Archives are now available.  Please search
the archive at http://lists.linux-india.org/ before posting your question
to avoid repetition and save bandwidth.