param can be one of the following
a,b 开发者_高级运维 , f, d
or
a, b , c, e
or
r , q ,c , d
but we want a,b,c,d without spaces
for example if we get: a , b ,c,d need to change it to a,b,c,d sytax to do that yael
what the best sed syntax to change it
Something like
s/ *, */,/g
I haven't tested it so you may need to fiddle a bit.
Try:
tr -d ' ' < inputfile
or
sed 's/ //g' inputfile
精彩评论