To inset a keyword, after a token in the input line.
am 22.10.2007 16:32:34 von Khan
Hi,
I am new to scripting; How to insert a keyword, after a particular
token in the input line.
Ex:
Input Line: Shell scripting is a programming language
output line: Shell scripting is a powerful programming language
Input Line: C is a programming language
Output Line:C is a powerful programming language
That is, i want insert keyword "powerful" before the token
"programming ".
Please let me know the commands to do in it shell script or awk
scripting.
Thanks,
-Khan
Re: To inset a keyword, after a token in the input line.
am 22.10.2007 17:09:31 von Cyrus Kriticos
khan wrote:
>
> How to insert a keyword, after a particular
> token in the input line.
> Ex:
> Input Line: Shell scripting is a programming language
> output line: Shell scripting is a powerful programming language
> Input Line: C is a programming language
> Output Line:C is a powerful programming language
>
> That is, i want insert keyword "powerful" before the token
> "programming ".
echo "C is a programming language" | sed "s/programming/powerful &/"
--
Best regards | Be nice to America or they'll bring democracy to
Cyrus | your country.