Linefeeds are wrong when output is redirected to file
Metadata
Current evaluation
No evaluation has been recorded for this issue yet.
Issue body
When sending the output of a craft-cli application to a file we should translate CRs to LFs (and possibly remove the line padding), otherwise we end up with something like `Line 1 [padding] ^M Line 2 [padding] ^M Line3 [padding]`.
This is the real output of snapcraft redirected to a file:
```
Launching instance...
Initializing parts lifecycle ^MInstalling package repositories... Executing parts lifecycle... ^MInstalled package repositories
^MExecuting parts lifecycle: skip pull figlet (already ran) ^MExecuted: skip pull figlet (already ran) Executing parts lifecycle: skip overlay figlet (already ran)
^MExecuted: skip overlay figlet (already ran)
Executing parts lifecycle: skip build figlet (already ran) ^MExecuted: skip build figlet (already ran)
Executing parts lifecycle: skip stage figlet (already ran) ^MExecuted: skip stage figlet (already ran) Executing parts lifecycle: skip prime figlet (already ran)
^MExecuted: skip prime figlet (already ran)
Executed parts lifecycle
Generating snap metadata... ^MGenerated snap metadata
Creating snap package...
```
Evaluation history
No evaluation history available.