Printing Info Pages
When I want to print out documentation, I usually find myself going to the package's website and hoping there is a nice HTML or PDF file out there I can print, but when worst comes to worse I find myself copying and pasting from the info file into a text editor and printing it out
Please tell me there is a better way! Thanks a Mucho |
You can use command line:
info foo | lpr info foo | lprint See for more info http://blogs.cyberciti.biz/hm/index....nd-info-pages/ |
One option is to install the source package. This will give you access to the topic.tex source.
For example: rpm -Uhv core-utils-<version>.src.rpm cd /usr/src/packages/SPECS # The "packages" part may be different on your system. rpmbuild -bp core-utils.spec # This may apply patches to the document sources cd ../BUILD cd core-utils-<version>/ ./configure # There may by targets to produce the documentation such as make dvi or make ps or make pdf As a last resort, cd to the "doc" subdirectory, and if a core-utils.tex file exists: tex core-utils.tex This will produce a .dvi file which you can print out from kdvi or xdvi, or you could use dvips to convert it to postscript. This may seem like a lot of work, but will become routine after a few times. The documents produced look very good. Also, many of the documents you will discover this way are lengthy manuals. The bashref, and core-utils manual s are long enough to fill a 3 ring binder. Having them nicely typeset makes using them easier. Also consider printing out man pages this way: man -t <topic> | lp -d <printername> You might want to preview an example this way: man -t tar | gv -scale 2 -antialias -media letter - |
To print man pages:
In this example, using tar man pages. man -t tar | lpr -Pdraft Print man pages for tar (will be formatted by troff or groff, usually for PostScript) Pipe to lpr Send to printer <draft> [optional]. The command will print to the default printer if given as: man -t tar | lpr =============================== To print info pages: In this example, using tar info pages. cp /usr/share/info/tar.info.gz /home/<user> Copy the info page to another location to avoid breaking your on-line documentation. gunzip /home/<user>/tar.info.gz After decompressing the file, use a2ps to convert to PostScript. a2ps tar.info This produces a PostScript formatted file called tar.info. Open in your favorite editor and print from there. =============================== To convert output to PDF format man -t tar | ps2pdf > tar.pdf =============================== I've tried info2html and didn't like the result. |
All times are GMT -5. The time now is 11:20 AM. |