PINFO(1)
π¦ PINFO(1) π¦
General Commands Manual β¨ so this whole thing lives in the General Commands Manual, section 1, and it's all about pinfo β bestie, you're gonna love her.
π NAME π
pinfo β she's a user-friendly, console-based viewer for Info documents. that's it, that's the whole vibe check. π
β¨ SYNTAX β¨
pinfo [options] [infopage]
πΈ DESCRIPTION πΈ
okay so. pinfo is a program for viewing info files. You tell it which page you wanna read by handing it an infopage argument. That argument holds the name of an info page (i.e. bash). Then the program will β by default β go hunting for it in the current directory, /usr/share/info, /usr/info, /usr/local/share/info, /usr/local/info, and /opt/info. π the search path can be adjusted by the INFOPATH environment variable, or in the configuration file. And pinfo will also automatically add the suffix -info, -info.Z, -info.gz, or -info.bz2. she's thorough like that π
When the search for info pages fails, man is called with the infopage argument, and its output gets parsed by pinfo. Which basically means: when you don't have the appropriate info page but you do have a man page instead, the man page will be viewed. no page left behind π«Ά
When no infopage is specified, the default dir page is shown. iconic default behavior fr fr.
Supported options are π
-h,--helpβ print help information and exit.-v,--versionβ print version information and exit.-m,--manualβ uses manual page instead of info by default. (pinfo -mcould be used as a manual pager.) β οΈ Warning: everything that follows this option is passed to themanprogram. Don't be confused ifpinfooptions that followed-mdon't work. When using this option,pinfodoes not parse the info options as usual! It invokes the man part of the program. it's giving "different mode entirely" π
You can also call the man function of pinfo in another way. When pinfo is called with an argv[0] (the program file name) which contains the word man in its name, the man functions are enabled automatically. sneaky but slay.
Previously there was a symlink to pinfo, called pman, but she had to be removed from the distribution, since her name was in conflict with some other utility. anyway, you can feel free to create such a link if you wish. π
-r,--raw-filenameβ uses a raw filename first (i.e. the name which you specified as infopage is considered to be a real file in the specified location).-f,--fileβ synonym for-r.-a,--aproposβ if this is set,aproposis called when no man or info page could be found.-c,--cut-man-headersβ if this is set, the man parsing code will try to cut out the repeated man headers. Use with care. ;)-s,--squeeze-linesβ cut empty lines from manual pages. This option enables auto cutting of every repeated newline in a manual page.-t,--force-manual-tag-tableβ forces manual detection of tag table. This allows you to view info pages which may be corrupted (as i.e. the version of jed's pages shipped with RH5.0). The tag table corruption usually appears in that the info links which you follow move you to quite unexpected nodes. π--node=nodename,--node nodenameβ Go to the nodenodenameof the info file. Since0.6.7it is also possible to specify nodes as in standalone info via file names, like(gcc)Introduction.--rcfile=filename,--rcfile filenameβ Use an alternate configuration file.--long-manual-links,-lβ Use long link names in manuals. On some systems the manual hierarchy is divided into subsections like3ncurses, etc, while on other systems all belongs to section3. If this option is what your system is like, feel free to use it.--clear-at-exit,-xβ Clear screen at exit.
The options are handled by GNU getopt, so you can here (as in other programs) abbreviate the option names to the minimal number of characters by which the options differ. β¨
Warning! If you do not have getopt, these options will not work! π
π DEFAULT KEYS WHEN BROWSING INFO FILE π
Just take a look at the example configuration file (below), and at the key descriptions. Keys available in the manual viewer differ a bit from the keys available in the info viewer. lowkey important, bestie π
π ENVIRONMENT π
There is a variable $INFOPATH, which can specify the paths to be searched for info files. Its format is similar to that of the $PATH variable. An example setting could look like:
/usr/info:/usr/somewhere/info:/not/even/in/usr/info
etc. Directories are separated by colons. π«Ά
π COLOR AND KEY DEFINITIONS π
There are configuration files called ~/.pinforc and [prefix]/etc/pinforc, for local and global configuration (where prefix is the prefix of the directory where pinfo is installed, i.e. /usr/local, or /). Here's an example of such a file; we'll discuss the contents below:
# Here are some color setting.
# Whitespace between the entries is optional.
COL_NORMAL = COLOR_WHITE, COLOR_BLACK, NO_BOLD, NO_BLINK
COL_MENUSELECTED = COLOR_RED, COLOR_BLACK, BOLD, NO_BLINK
COL_MENU=COLOR_BLUE,COLOR_BLACK,BOLD, NO_BLINK
COL_NOTESELECTED=COLOR_RED,COLOR_BLACK,BOLD, NO_BLINK
COL_NOTE=COLOR_GREEN,COLOR_BLACK,BOLD, NO_BLINK
COL_TOPLINE=COLOR_YELLOW,COLOR_BLUE,BOLD, NO_BLINK
COL_BOTTOMLINE=COLOR_YELLOW,COLOR_BLUE,BOLD, NO_BLINK
COL_MANUALBOLD=COLOR_WHITE,COLOR_BLACK,BOLD, NO_BLINK
COL_MANUALITALIC=COLOR_WHITE,COLOR_BLACK,BOLD, NO_BLINK
COL_URL=COLOR_MAGENTA,COLOR_BLACK,BOLD, NO_BLINK
COL_URLSELECTED=COLOR_RED,COLOR_BLACK,NO_BOLD, NO_BLINK
COL_INFOHIGHLIGHT=COLOR_WHITE,COLOR_BLACK,BOLD, NO_BLINK
#
# Here are some keybindings as well...
#
KEY_TOTALSEARCH_1 = 's'
KEY_TOTALSEARCH_2 = 'S'
KEY_SEARCH_1 = '/'
KEY_SEARCH_2 = '.'
KEY_GOTO_1='g'
KEY_GOTO_2='m'
KEY_HOME_1='h'
KEY_HOME_2='H'
KEY_PREVNODE_1='p'
KEY_PREVNODE_2='P'
KEY_NEXTNODE_1='n'
KEY_NEXTNODE_2='N'
KEY_UP_1=KEY_UP
KEY_UP_2='u'
KEY_END_1=
KEY_END_2='e'
KEY_PGDN_1=KEY_NPAGE
KEY_PGDN_2=' '
KEY_PGDN_AUTO_1=0
KEY_PGDN_AUTO_2=' '
KEY_PGUP_1=KEY_PPAGE
KEY_PGUP_2='b'
KEY_PGUP_AUTO_1=0
KEY_PGUP_AUTO_2='b'
KEY_DOWN_1=KEY_DOWN
KEY_DOWN_2='d'
KEY_TOP_1=KEY_HOME
KEY_TOP_2='t'
KEY_BACK_1=KEY_LEFT
KEY_BACK_2='l'
KEY_FOLLOWLINK_1=KEY_RIGHT
KEY_FOLLOWLINK_2='0
# 12 is a code for ctrl+l
KEY_REFRESH_1=12
KEY_REFRESH_2='~'
KEY_SHELLFEED_1='!'
KEY_SHELLFEED_2='1'
KEY_QUIT_1='q'
KEY_QUIT_2='Q'
KEY_DIRPAGE_1='d'
KEY_DIRPAGE_2='D'
KEY_GOLINE_1='l'
KEY_GOLINE_2=0
KEY_PRINT_1=']'
KEY_PRINT_2=0
#
# Some options, explained in the man page
#
MANUAL=false
CUT-MAN-HEADERS=true
CUT-EMPTY-MAN-LINES=true
RAW-FILENAME=false
APROPOS=false
DONT-HANDLE-WITHOUT-TAG-TABLE=false
LONG-MANUAL-LINKS=false
FILTER-0xB7=true
QUIT-CONFIRMATION=false
QUIT-CONFIRM-DEFAULT=no
CLEAR-SCREEN-AT-EXIT=true
STDERR-REDIRECTION="2> /dev/null"
HTTPVIEWER=lynx
FTPVIEWER=lynx
MAILEDITOR=pine
MANLINKS=1:8:2:3:4:5:6:7:9:n:p:o:3X11:3Xt
INFOPATH=/usr/info:/usr/share/info:/usr/local/info
HIGHLIGHTREGEXP=Bash.*has
SAFE-USER=nobody
SAFE-GROUP=nobody
As you can see, the format is simple. π
First I'll explain the color definitions. First you must enter a color name (all available color names are present in the example, and they're self explanatory, I think. There is also a special color COLOR_DEFAULT, which stands for transparency). Then you enter the foreground color, and the background color. The BOLD attribute means that we want the foreground color to be highlighted. (i.e. light blue, light green). The BLINK attribute is the blinking attribute, or highlighted background in some other configurations. β¨
Now let's move to the key definitions. Here we first put a key name (again all keys are present in the example); then we enter its value β either surrounded by apostrophes, or a keycode number (like in KEY_REFRESH_1), or its mnemonic code name if it's a special key (like i.e. in KEY_FOLLOWLINK_1). π
If you wish to specify a key by code value, use the supplied program testkey to obtain the needed value. It mainly is a feature when you want to add some CTRL+letter keybindings, and similar. π
For each function you can bind two keys, i.e. you could bind both Enter and Cursor Right to the FollowLink-function. As you can see in the example above, the two key names are KEY_FOLLOWLINK_1 and KEY_FOLLOWLINK_2. two keys per function? we love options π
Here's an explanation of the key names:
KEY_TOTALSEARCH_1β Key for searching through all nodes of info file.KEY_TOTALSEARCH_2β Alternate key for searching through all nodes of info file.KEY_SEARCH_1β Key for searching through current node (or manual).KEY_SEARCH_2β Alternate key for searching through current node (or manual).KEY_SEARCH_AGAIN_1β Key for repeating the last search.KEY_SEARCH_AGAIN_2β Alternate key for repeating the last search.KEY_GOTO_1β Key for explicitly going to a node (by specifying its name).KEY_GOTO_2β Alternate key for explicitly going to a node (by specifying its name).KEY_PREVNODE_1β Key for going to a node marked asPrevin the header. In man page viewer this goes to the previous man section.KEY_PREVNODE_2β Alternate key for going to a node marked asPrevin the header. In man page viewer this goes to the previous man section.KEY_NEXTNODE_1β Key for going to a node marked asNextin the header. In man page viewer this goes to the next man section.KEY_NEXTNODE_2β Alternate key for going to a node marked asNextin the header. In man page viewer this goes to the next man section.KEY_UP_1β Key for scrolling text one line up.KEY_UP_2β Alternate key for scrolling text one line up.KEY_END_1β Key for going to the end of the node.KEY_END_2β Alternate key for going to the end of the node.KEY_PGDN_1β Key for going one page down in the viewed node.KEY_PGDN_2β Alternate key for going one page down in the viewed node.KEY_PGDN_AUTO_1β Key for going to the next node when you're at the end of node (default is zero β turned off).KEY_PGDN_AUTO_2β Alternate key for going to the next node when you're at the end of node (default is space, as for pgdn_2).KEY_HOME_1β Key for going to the beginning of the node.KEY_HOME_2β Alternate key for going to the beginning of the node.KEY_PGUP_1β the key that yeets you one whole page up in the node you're viewing. πKEY_PGUP_2β alternate key for the exact same page-up glow-up. β¨KEY_PGUP_AUTO_1β when you're already at the very top of a node, this key takes you to the `up' node. (default value is zero -- turned off). π«ΆKEY_PGUP_AUTO_2β alternate key for that same top-of-node-to-up' move.</purple> <yellow>(default value is-, as forpgup_2`). πKEY_DOWN_1β scrolls the text down one line. πKEY_DOWN_2β alternate key for scrolling down one line. πKEY_TOP_1β goes to the top (first) node. πKEY_TOP_2β alternate key for going to the top (first) node. πKEY_BACK_1β goes back in the history of viewed nodes. π¦KEY_BACK_2β alternate key for going back in the history of viewed nodes. π¦KEY_FOLLOWLINK_1β follows a hypertext link. πKEY_FOLLOWLINK_2β alternate key for following a hypertext link. πKEY_REFRESH_1β refreshes the screen (hard coded is the^Lvalue). πKEY_REFRESH_2β alternate key for refreshing the screen. πKEY_SHELLFEED_1β calls a shell command, and passes the viewed node to the stdin of that command. πKEY_SHELLFEED_2β alternate key for calling a shell command, and passing the viewed node to the stdin of that command. πKEY_QUIT_1β exits the program. πKEY_QUIT_2β alternate key for exiting the program. πKEY_GOLINE_1β goes to a specified line in file. πKEY_GOLINE_2β alternate key for going to a specified line in file. πKEY_PRINT_1β prints the viewed node or man page. π¨οΈKEY_PRINT_2β alternate key for printing the viewed node or man page. π¨οΈ
okay bestie, the special mnemonics for keys that are defined at present are:
KEY_BREAKKEY_DOWNKEY_UPKEY_LEFTKEY_RIGHTKEY_DOWN(yes, it's listed again β the page said it twice, so we keep it twice π)KEY_HOMEKEY_BACKSPACEKEY_NPAGEKEY_PPAGEKEY_END[Note: this works probably ONLY with Linux ncurses]KEY_F(x)KEY_CTRL('c')β this assigns the key value to a ctrl+c combination.cmay be any letter you wish.KEY_ALT('c')β this assigns the key value to a alt+c combination.cmay be any letter you wish. If alt key won't work, you may use ESC+key combination.'c'β this means a printable characterc. The syntax is just like in C/C++ ;).[number]β you can also specify key as its code number. It is useful e.g. when specifying control keys, and some nonstandard keys. A numerical value of zero turns given key binding off.
for what all those mean, go peek at the manual page for curs_getch (3x). π
Warning! Try not to create some serious key binding conflicts! π¨π₯
the options in the last part of the example configuration file are pretty much self-explanatory, bestie. any variable you can set to true or false does the same thing as the command line argument with the same name. β¨
MANUALβ if this is set totrue, the default is to first check for a man page, instead of a texinfo file. πCUT-MAN-HEADERSβ if set totrue, then pinfo tries to cut off the repeated headers throughout man pages. βοΈCUT-EMPTY-MAN-LINESβ if set totrue, then pinfo tries to cut off the repeated newlines (i.e. it will shorten each set of consecutive newlines to one newline). π§ΉRAW-FILENAMEβ if set totrue, the file argument is taken to be the name of a file in the current working directory, i.e. the directories inINFOPATHwill only be searched if a file with this name is not in the working directory. πAPROPOSβ if set totrue,aproposis called if no info or man page is found. πDONT-HANDLE-WITHOUT-TAG-TABLEβ if set totrue, pinfo will not attempt to display texinfo pages without tag tables. π«HTTPVIEWERβ set this to the program you want to use to follow http links in documents. πFTPVIEWERβ set this to the program you want to use to follow ftp links in documents. π‘MAILEDITORβ set this to your favorite email program, and it will be started if you follow an email link in a document. π§PRINTUTILITYβ utility, which you use for printing. i.e.lpr'. if you don't use any, you may also try something likecat >/dev/lp1', or sth. ;) π¨οΈMANLINKSβ this specifies the section names, which may be referenced in your man pages (i.e. Xtoolkit man pages match the section3Xt(see for exampleXtVaCreateWidget) manpage), Xlib function pages match section3X11, etc. Such extensions may not be recognized by default, so it is a good idea to add them). πINFOPATHβ this allows you to override the default search path for info pages. the paths should be separated by colons. π€οΈMAN-OPTIONSβ this specifies the options, which should be passed to theman' program. (seeman(1)` for description of what they're like). πSTDERR-REDIRECTIONβ pinfo allows you to redirect the stderr output of called programs. for example if you don't want to see man's error messages about manual page formatting, you can useSTDER-REDIRECTION="2> /dev/null". this is the default. π°LONG-MANUAL-LINKSβ this is another true/false option, which decides whether your system supports long manual section names, or not. (i.e."3ncurses"instead of"3"). πFILTER-0xB7β this decides, whether you want to convert0xb7chars too', or not. for example foriso-8859-2` fonts this makes man's list marks a bit nicer ;) (look for example at perl's man page, to see how those marks look like). πQUIT-CONFIRMATIONβ this decides whether you want to use quit confirmation on exit, or not. πͺQUIT-CONFIRM-DEFAULTβ this yes/no option determines the default answer to theQUIT-CONFIRMATIONdialog. (default answer is when you press a key, that does not match the asked question). βCLEAR-SCREEN-AT-EXITβ this true/false option determines if you want to have your screen cleared at exit, or no. π§ΌCALL-READLINE-HISTORYβ this true/false option determines if you want to have a prompt of last history entry whenever calling readline wrapper, eg. in subsequent searches. πHIGHLIGHTREGEXPβ this is an option, through which you may pass to pinfo regexps, which should be highlighted when working with document. Warning! This may turn very slow if you use it without care! β οΈSAFE-USERβ this option is used to pass the name of user, to which suid when pinfo is run with root privileges. π€SAFE-GROUPβ this option is used to pass the name of group, to which suid when pinfo is run with root privileges. π₯
π INTERNATIONALIZATION SUPPORT π
pinfo implements general features of the gnu gettext library (the thing, which you need to see national messages ;). But it is not the end. Pinfo allows you to use national info pages! You only need to put them to your info directory, into a subdirectory, which is called `$LANG'.
π LICENSE π
This program is distributed under the terms of GPL.
π BUGS π
Please send bug reports to the author.
π AUTHOR π
Przemek Borys <pborys@dione.ids.pl> Bas Zoetekouw <bas@debian.org>
There was also a lot of other people, who contributed to this code. See the AUTHORS file.
π¬ COMMENTS π¬
The author would like to read some comments and suggestions from you, if any.
and that's a wrap on the PINFO(1) page, bestie β dated 01 Dec 2001. go forth and browse info like the main character you are π
β¨π
π¦ where this page comes from
- debian bookworm: pinfo 0.6.13-1.3
- nixos 26.05: pinfo 0.6.13
- nixpkgs unstable: pinfo 0.6.13
- ubuntu jammy: pinfo 0.6.13-1.1
- ubuntu noble: pinfo 0.6.13-1.3build2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms