Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var PassthroughPager = &Pager{ WriteCloser: os.Stdout, isCloseable: false, }
PassthroughPager is a Pager writing the content directly to stdout without pagination.
Functions ¶
This section is empty.
Types ¶
type Pager ¶
type Pager struct { io.WriteCloser // contains filtered or unexported fields }
Pager writes text to a terminal using the user's pager.
func (*Pager) Close ¶
Close terminates the pager, waiting for the process to be finished before returning.
We make sure Close is called only once, since we don't know how it is implemented in underlying writers.
func (*Pager) WriteString ¶
WriteString sends the given text to the pager, ending with a newline.
Click to show internal directories.
Click to hide internal directories.