Girocco/CLIUtil.pm: add setup_pager and setup_pager_stdout
The setup_pager function returns a pipe to a pager as determined
by the PAGER environment variable or what can be found in $PATH.
The setup_pager_stdout redirects STDOUT to a pager depending
on the arguments passed in, by default (with no arguments), it
redirects STDOUT to a pager only if STDOUT is a terminal.
But, if a known pager is already in use (tested courtesy of the new
pager_in_use function), then setup_pager_stdout does nothing.
If setup_pager_stdout activates a pager, also set the appropriate
known environment variables to discourage nested pagers.
The setup_pager_stdout function does some "magic" to make things
just work from the point of view of the caller, but those things
are quite possibly unworkable on a non-unixen system. But then
so too will likely be running Girocco on such a system.
Signed-off-by: Kyle J. McKay <mackyle@gmail.com>