xilun / cbwin

Launch Windows programs from "Bash on Ubuntu on Windows" (WSL)
Other
327 stars 25 forks source link

Text is not aligning right. #16

Closed TheAggressive closed 8 years ago

TheAggressive commented 8 years ago

its hard to read because the out put text looks like this.

ult: TASK [wordpress-install : include] *********************************************
                                                                                     ==> default: included: /vagrant/roles/wordpress-install/tasks/directories.yml for 192.168.50.5
                                     ==> default:
                                                  ==> default: TASK [wordpress-install : Create web root of sites] ****************************
 ==> default: ok: [192.168.50.5] => (item=example.com)
                                                      ==> default:
                                                                   ==> default: TASK [wordpress-install : Create shared folder of sites] ***********************
                  ==> default: changed: [192.168.50.5] => (item=example.com)
                                                                            ==> default:
                                                                                         ==> default: TASK [wordpress-install : Change site owner to user] ***************************
                                        ==> default: changed: [192.168.50.5] => (item=example.com)
                                                                                                  ==> default:
                                                                                                               ==> default: TASK [wordpress-install : Create .env file] ************************************
                                                              ==> default: changed: [192.168.50.5] => (item=example.com)
                                                                                                                        ==> default:
                                                                                                                                     ==> default: TASK [wordpress-install : Copy .env file into web root] ************************
                                                                                    ==> default: changed: [192.168.50.5] => (item=example.com)
                                                                                                                                             ==> default:
            ==> default: TASK [wordpress-install : Install Dependencies with Composer] ******************

anyone know how to fix this??

Thank you!!

xilun commented 8 years ago

Hi,

Did you remember the commands you used before reaching this state?

In my experience, there are some Win32 tools that disturb the console config used by WSL programs, for example cygwin tools tend to do that. For now cbwin do not try to do any trick in regard to the Windows Console configuration (neither the caller, nor outbash.exe), so the end result depends a bit on luck about the programs you are using...

A workaround could be to call your Win32 tools with the --force-redirects option of wcmd, example:

wcmd --force-redirects evil_win32_program_that_usually_changes_your_console_config

Redirections are not forced by default, because there would be other drawbacks.

Cheers!

TheAggressive commented 8 years ago

I did wcmd vagrant up.

using that flag made alignment correct again.

xilun commented 8 years ago

Ok. I'll try to write some better doc, hopefully soon, and will include the description of this common problem and the --force-redirects option.

xilun commented 8 years ago

wcmd --help now explains the --force-redirects option.