Replace string in files including subfolders
by Mohan[ Edit ] 2014-09-11 19:09:31
Replace string in files including subfolders
grep -rli 'oldstring' --include=*.php | xargs -i@ sed -i 's#oldstring#newstring#g' @
this command replaces the 'oldstring' with 'newstring' in all php files within the directory (includes sub directories )