Skip to content

Forcetty#158

Merged
vbauerster merged 12 commits into
masterfrom
forcetty
Jul 11, 2026
Merged

Forcetty#158
vbauerster merged 12 commits into
masterfrom
forcetty

Conversation

@vbauerster

Copy link
Copy Markdown
Owner

Address issue #157

vbauerster and others added 12 commits July 4, 2026 14:49
If forceTTY requested and underlying out is not a terminal failsafe to:

termSize: func(_ int) (int, int, error) {
   return defaultWidth, defaultWidth, nil
}
That way (*Writer).IsTerminal maintains its promise.
No need as cw.GetTermSize will failsafe to default witdh and height if
underlying io.Writer is not a tty.
- move const defaultWidth to cwriter package
- drop termSize func pointer on *Writer struct
- prefer named returns
@vbauerster
vbauerster merged commit bd7f46d into master Jul 11, 2026
8 checks passed
@vbauerster
vbauerster deleted the forcetty branch July 11, 2026 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant