Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ponysay on TTY *always* truncates on height / no color reset #260

Open
lapsio opened this issue Jun 23, 2017 · 4 comments
Open

Ponysay on TTY *always* truncates on height / no color reset #260

lapsio opened this issue Jun 23, 2017 · 4 comments

Comments

@lapsio
Copy link

lapsio commented Jun 23, 2017

Ponysay under TTY always truncates terminal output. It breaks my rc scripts which are printing server status info above pony. It's especially annoying if you consider that bare TTY in production environment is only accessed when something bad happens so truncating log makes already bad mood even worse, no matter how much stress ponies in terminal release.

Whereas there is option to force enable truncate under non-TTY there's no option to disable it under TTY. I tried explicitly setting set -x PONYSAY_TRUNCATE_HEIGHT 0 but it doesn't work.

Also ponysay seems to improperly reset color palete on TTY (it's actually good tho because some machines have really dark colors in fish shell so ponysay makes highlighted output actually readable, that's tbh why I use it on TTY in the first place)

@JotaRandom
Copy link
Collaborator

The 'no color reset' is unintentional but I think the infopage mention a workaround that maybe can be applied to other programs too.

Now the truncation maybe @maandree could enlightenment us if that intentional or not (I think the variable ignoring is a bug) since he write the python script.

@JotaRandom
Copy link
Collaborator

I did the PR #263 but as I mentioned in it BSD and ToaruOS dont look like have those files, for the other side a simple solution should be the old if linux else a fallback,

@lapsio
Copy link
Author

lapsio commented Jul 24, 2017

how about truncate?

@JotaRandom
Copy link
Collaborator

Truncating work using the exposed stty as talked on #254 but aparently set -x PONYSAY_TRUNCATE_HEIGHT 0 got override somewhere.

I'm waiting for comments on #254 about using TIOCGWINSZ against os.get_terminal_size() and hope probably we can find if was stty the culprint on the overriding or just the issue is on how ponysay detect the environments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants