It’s possible to run several commands in a sed one-liner. All you have to do is separate the instructions with a semicolon:
echo '123456' | sed 's/1/a/g; s/a2/x/g' output: x3456
A Software Blog from Marcos Savoury
It’s possible to run several commands in a sed one-liner. All you have to do is separate the instructions with a semicolon:
echo '123456' | sed 's/1/a/g; s/a2/x/g' output: x3456