The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #7 (permalink)  
Old 03-18-2008
antointoronto antointoronto is offline
Registered User
  
 

Join Date: Mar 2008
Posts: 28
Quote:
Originally Posted by joeyg View Post
The following does a copy; you can change to the move (mv) command

Code:
> cat copy_csv
#! /bin/bash

for i in *.csv
do
  var1=$(basename "$i" .csv)
  cp $i $var1
done
hi

Thanks for your reply.But I would like to use substring operation.


Thanks