While programming using Emacs, you frequently consult manual pages. My environment is text-based Emacs via SSH.
While I can open "Normal" manual pages in Emacs using the man
command ((man MAN-ARGS)
function), I wonder how to use perldoc
for Perl POD documentation from within Emacs: When I run it (e.g.: perldoc -f pack
) from a shell
((shell &optional BUFFER)
function), I get a message saying:
WARNING: terminal is not fully functional
Specifically, the number of terminal lines is less than what the Emacs windows offers. The terminal seems to be set to dumb
, but even when I use TERM=emacs perldoc -f pack
only 24 lines are used, and I see a lines 1-23
prompt (pager asking to continue). I also see that LINES
is set to 24, even though my (outer) terminal has 103 lines.
Obviously, as the window can be resized, counting the number of lines and setting LINES
accordingly does not look like a smart answer for this problem. Despite of that, using TERM=emacs LINES=100 perldoc -f pack
still stopped output at line 24.
So maybe it's an Emacs question, actually.
tmux
orscreen
so you can have one pane with emacs open and another with a regular shell?man perlfunc
in emacs, then search forpack T
(for "pack TEMPLATE") which takes you to the relevant entry. Is that a good enough workaround?man perlfunc
does not actually help.