Skip to content

Line output is clipped to 80 columns #197

@ijustlovemath

Description

@ijustlovemath

Hi,

I'm trying to support running a python script that redirects stdout in git-bash. I've settled on a magic invocation that seems to work:

winpty -Xallow-non-tty -Xplain python.exe -u /path/to/script.py > my_output_file.txt

However, lines longer than 80 characters that python redirects from stdout are clipped and the remainder moved to new lines. I did a little digging, and it seems like the problem might be that the size is set to 80 at program start:

    winsize sz = { 0 };
    sz.ws_col = 80;
    sz.ws_row = 25;

   // later...
   winpty_config_set_initial_size(agentCfg, sz.ws_col, sz.ws_row);

Is this the root of my problem? If so, would it be possible to change these values, within reason, from the command line?

No rush on this, it's for a side project.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions