Search Results

Search: Posts Made By: Creems
1,618
Posted By guruprasadpr
Hi basename is unix command, dont replace...
Hi

basename is unix command, dont replace it. The command loops through all the files and does the needful.

If you are little doubtful about this, just create a temporary directory, create...
1,618
Posted By guruprasadpr
Hi $ ls a1.txt.dat a2.txt.dat a3.txt ...
Hi

$ ls
a1.txt.dat a2.txt.dat a3.txt


$ for i in *.dat
> do
> j=`basename $i .dat`
> mv $i $j
> done


$ ls
a1.txt a2.txt a3.txt

Guru.
Showing results 1 to 2 of 2

 
All times are GMT -4. The time now is 06:14 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy