News for hackers. Stuff that matters.
Re:Batch editing files with ed by KC8ZKF on Saturday May 12, 2018 @02:23PM (#17055312)

  sed s/baz/baz\\nelephants/
Re:Batch editing files with ed by shabble on Saturday May 12, 2018 @03:37PM (#17055638)
that doesn't match the indentation on the subsequent line though, does it?
Re:Batch editing files with ed by yani on Saturday May 12, 2018 @03:39PM (#17055645)
You are missing the dash that the line starts with
Re:Batch editing files with ed by KC8ZKF on Saturday May 12, 2018 @04:07PM (#17055761)

  sed -i.bak s/baz/"baz\\n  - elephants"/ *.txt
Re:Batch editing files with ed by bewuethr on Saturday May 12, 2018 @06:19PM (#17056304)
The article says that the indentation can be two or four spaces, though.