I'm working with a korn shell script and have data that looks like:
SPE-2 Bread Basket
Quantity: 2
Each: $12.00
I want the 1st line to read:
Quantity: 2 SPE-2 Bread Basket
I know how I can join or append the 1st two lines together
(sed -e '/^Quantity:/N;s/\n/ /g') but I don't know what to do if I want the second line to precede the first on the same line.
Any help would be appreciated!
SPE-2 Bread Basket
Quantity: 2
Each: $12.00
I want the 1st line to read:
Quantity: 2 SPE-2 Bread Basket
I know how I can join or append the 1st two lines together
(sed -e '/^Quantity:/N;s/\n/ /g') but I don't know what to do if I want the second line to precede the first on the same line.
Any help would be appreciated!