The UNIX and Linux Forums  

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 -->
  #4 (permalink)  
Old 06-23-2006
vino's Avatar
vino vino is offline Forum Staff  
Supporter (in vino veritas)
  
 

Join Date: Feb 2005
Location: Bangalore, India
Posts: 2,798
I am not aware of any shell-builtins' (except for the ones Ygor posted) which carries out string replacement.

Try sed


Code:
echo "$variable" | sed -e "s_car_dog_g"

awk can do it as well. Look into the gsub method.