5

Problem with Shell Scripts deleting text in files.

view full story
linux-howto

http://www.unix.com – Me and a friend are working on a project, and We have to create a script that can go into a file, and replace all occurances of a certain expression/word/letter with another using Sed. It is designed to go through multiple tests replacing all these occurances, and we don't know what they will be so we have to anticipate anything. We are having trouble on a certain test where we need to replace 'l*' with 'L' in different files using a loop. The code that i have is Code: #!/bin/sh  p1="$1" #first parameter shift  p2="$1" shift for file in "$@" #f (HowTos)