REMOVING CONTROL CHARACTERS Have you ever faced problem of removing Control Characters from Multiple Files, Here is the solution create script file with following entries, vi -c "%s/^M//g" -c "wq" junk1.c vi -c "%s/^M//g" -c "wq" junk2.c vi -c "%s/^M//g" -c "wq" junk3.c vi -c "%s/^M//g" -c "wq" junk4.c vi -c "%s/^M//g" -c "wq" junk5.c vi -c "%s/^M//g" -c "wq" junk6.c If the filename of this script file is "xyz": #./xyz This will remove the control characters(^M) from all the files junk1.c ... junk6.c To create ^M = Holding the control press 'v' & 'm'. To create ^H = Holding the control press 'v' & 'h'.