Skip to content
This repository has been archived by the owner on Nov 22, 2022. It is now read-only.

Table printer should take as much terminal space as it can #300

Closed
zemzale opened this issue Nov 12, 2020 · 1 comment
Closed

Table printer should take as much terminal space as it can #300

zemzale opened this issue Nov 12, 2020 · 1 comment

Comments

@zemzale
Copy link
Collaborator

zemzale commented Nov 12, 2020

Is your feature request related to a problem? Please describe.
When we are printing something with table printer we always default width of 70 cells. When we have long output like for example in #106, this output gets cut off while the terminal has still plenty of output space.

Describe the solution you'd like
We should query the terminal for it's width. There is https://godoc.org/golang.org/x/crypto/ssh/terminal#GetSize function from the terminal library. I have used it for one of my own helper programs, but have not tested how good it works on other OSes then Linux.

Describe alternatives you've considered
If querying terminal for it's size is not possible we could just allow user set their own terminal size somehow.

@profclems
Copy link
Owner

Resolved by this commit 7506a8a

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

No branches or pull requests

2 participants