What is use of sed command?
Sed command in UNIX is commonly used for processing of files. Sed stands for Stream Editor which parses text files and used for making textual transformations to a file. The command specified to Sed, is applied on the file line by line.
Example:To replace all matching occurrences of some text to another.
sed -e 's/olddata/newdata/g' inputFileName > outputFileName
Here, g is global which replaces ALL occurrences.
What is use of sed command?
Sed command reads from a standard input and places it into the pattern space. It performs various editing commands on that pattern space in a sequential manner. Later the pattern space is written onto the STDOUT.