New line characters from command output in variable.
in man bash, section "Command Substitution" I read that new lines are removed from output:
The only way I know is to add an extra line and remove it later. In this way the trailing newlines are preserved since they become embedded, then you can strip the added chars using parameter substitution. This will demonstrate:
|All times are GMT -5. The time now is 04:38 AM.|