This too.
Code:
vefatica@jj:~$ echo foo | sed -e 's/.*/prefix \0 postfix/g'
prefix foo postfix
vefatica@jj:~$ echo foo | sed -e 's/.*/[[ \0 ]]/g'
[[ foo ]]
But it gets all fouled up when I try to use it from windows. Below, the second is expected; the first seems wacky.
Code:
v:\> echo foo | (wsl sed -e 's/.*/[[ \0 ]]/g')
]]foo
v:\> echo foo | (wsl sed -e 's/.*/[[ \\0 ]]/g')
[[ \0 ]]