I have a line with spaces in the start for example \" Hello world\". I want to insert this line to a specific line in a file. for example insert \" hello world\" to the next f
It can be done by splitting the expression like this:
sed -i $file -e '2i\' -e " $text"
This is a GNU extension for easier scripting.