replace at specifcposition

Hi

#xxxxx abced

xxx_hij=

The above are two lines in a file. I would like to parse the file write a text line between the above two lines...like

#xxxxx abced
<write a text line here>
xxx_hij=

How can I do this using sed or awk? also if there is any other easy way apart from sed and awk pls. let me know

Thanks!

try the i command in sed

sed '/^xxx_hij/i\
<write a text line here>' filename

input

#xxxxx abced
xxx_hij=

output

#xxxxx abced
<write a text line here>
xxx_hij=