Skip to main content
replaced http://unix.stackexchange.com/ with https://unix.stackexchange.com/
Source Link

Cuonglm gave the best answerCuonglm gave the best answer, but for the record here's what GNU sed does:

echo foo | sed 'i\ This line starts with spaces.' 

Output:

 This line starts with spaces. foo 

Cuonglm gave the best answer, but for the record here's what GNU sed does:

echo foo | sed 'i\ This line starts with spaces.' 

Output:

 This line starts with spaces. foo 

Cuonglm gave the best answer, but for the record here's what GNU sed does:

echo foo | sed 'i\ This line starts with spaces.' 

Output:

 This line starts with spaces. foo 
Added URL.
Source Link
agc
  • 7.4k
  • 4
  • 25
  • 54

Cuonglm gave the best answerCuonglm gave the best answer, but for the record here's what GNUGNU sed does:

echo foo | sed 'i\ This line starts with spaces.' 

Output:

 This line starts with spaces. foo 

Cuonglm gave the best answer, but for the record here's what GNU sed does:

echo foo | sed 'i\ This line starts with spaces.' 

Output:

 This line starts with spaces. foo 

Cuonglm gave the best answer, but for the record here's what GNU sed does:

echo foo | sed 'i\ This line starts with spaces.' 

Output:

 This line starts with spaces. foo 
Source Link
agc
  • 7.4k
  • 4
  • 25
  • 54

Cuonglm gave the best answer, but for the record here's what GNU sed does:

echo foo | sed 'i\ This line starts with spaces.' 

Output:

 This line starts with spaces. foo