mks - SED { command fail -
on mks sed windows, this
type q:\temp\curtainssetspread.m3u | sed -e "/z/{s_a_b_}" fails with
sed: garbage after command why?
this usage accords correctly docs:
a,b{ groups commands until next matching }, sed executes entire group if { command selected address(es).
according posix, } must preceded newline. i'm not sure mks does, beauty of having standard following should work on all systems (using multiple -es joins each string newlines in between):
sed -e "/z/{s_a_b_" -e "}" if doesn't work, it's bug in mks , should reported, sed posix-compliant.
i suggest following benjamin's advice , doing
sed -e '/z/s_a_b_' if possible, though.
Comments
Post a Comment