Changeset 53819cbb
- Timestamp:
- 05/12/2005 08:01:05 PM (18 years ago)
- Branches:
- 10.0, 10.1, 11.0, 11.1, 11.2, 11.3, 12.0, 6.1, 6.2, 6.2.0, 6.2.0-rc1, 6.2.0-rc2, 6.3, 6.3-rc1, 6.3-rc2, 6.3-rc3, 7.10, 7.4, 7.5, 7.6, 7.6-blfs, 7.6-systemd, 7.7, 7.8, 7.9, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, basic, bdubbs/svn, elogind, gnome, kde5-13430, kde5-14269, kde5-14686, kea, ken/inkscape-core-mods, krejzi/svn, lazarus, lxqt, nosym, perl-modules, plabs/python-mods, qt5new, systemd-11177, systemd-13485, trunk, upgradedb, xry111/intltool, xry111/soup3, xry111/test-20220226, xry111/xf86-video-removal
- Children:
- 254bd5c8
- Parents:
- 1e247d1
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
postlfs/config/compressdoc.xml
r1e247d1 r53819cbb 7 7 8 8 <sect1 id="compressdoc" xreflabel="Compressing man and info pages"> 9 <sect1info> 10 <othername>$LastChangedBy$</othername> 11 <date>$Date$</date> 12 </sect1info> 13 <?dbhtml filename="compressdoc.html"?> 14 <title>Compressing man and info pages</title> 15 <indexterm zone="compressdoc"> 16 <primary sortas="b-compressdoc">compressdoc</primary></indexterm> 17 18 <para>Man and info reader programs can transparently process gzip'ed or 19 bzip2'ed pages, a feature you can use to free some disk space while keeping 20 your documentation available. However, things are not that simple; man 21 directories tend to contain links—hard and symbolic—which defeat 22 simple ideas like recursively calling <command>gzip</command> on them. A 23 better way to go is to use the script below. 24 </para> 25 26 <screen><userinput><command>cat > /usr/sbin/compressdoc << "EOF"</command> 27 #!/bin/bash 9 <?dbhtml filename="compressdoc.html"?> 10 11 <sect1info> 12 <othername>$LastChangedBy$</othername> 13 <date>$Date$</date> 14 </sect1info> 15 16 <title>Compressing Man and Info Pages</title> 17 18 <indexterm zone="compressdoc"> 19 <primary sortas="b-compressdoc">compressdoc</primary> 20 </indexterm> 21 22 <para>Man and info reader programs can transparently process gzip'ed or 23 bzip2'ed pages, a feature you can use to free some disk space while keeping 24 your documentation available. However, things are not that simple; man 25 directories tend to contain links—hard and symbolic—which defeat 26 simple ideas like recursively calling <command>gzip</command> on them. A 27 better way to go is to use the script below.</para> 28 29 <screen role="root"><userinput>cat > /usr/sbin/compressdoc << "EOF" 30 <literal>#!/bin/bash 28 31 # VERSION: 20050112.0027 29 32 # … … 489 492 fi 490 493 done # for FILE 491 done # for DIR 492 493 <command>EOF494 chmod 755 /usr/sbin/compressdoc</ command></userinput></screen>495 496 <para>Now, as root, you can issue a497 <command>compressdoc --bz2</command> to compress all your system man498 pages. You can also run <command>compressdoc --help</command> to get499 comprehensive help about what the script is able to do.</para>500 501 <para> Don't forget that a few programs, like the <application>X</application>502 Window System and <application>XEmacs</application> also install their503 documentation in non standard places (such as504 <filename class="directory">/usr/X11R6/man</filename>, etc...). Be sure to add505 these locations to the file <filename>/etc/man.conf</filename>, as a506 <envar>MANPATH</envar>=<replaceable>[/path]</replaceable> section.</para>507 508 <para> Example:</para>509 510 <screen>< userinput> ...494 done # for DIR</literal> 495 496 EOF 497 chmod 755 /usr/sbin/compressdoc</userinput></screen> 498 499 <para>Now, as <systemitem class="username">root</systemitem>, you can issue a 500 <command>compressdoc --bz2</command> to compress all your system man 501 pages. You can also run <command>compressdoc --help</command> to get 502 comprehensive help about what the script is able to do.</para> 503 504 <para> Don't forget that a few programs, like the <application>X Window 505 System</application> and <application>XEmacs</application> also 506 install their documentation in non standard places (such as 507 <filename class="directory">/usr/X11R6/man</filename>, etc...). Be sure 508 to add these locations to the file <filename>/etc/man.conf</filename>, as a 509 <envar>MANPATH</envar>=<replaceable>[/path]</replaceable> section.</para> 510 511 <para> Example:</para> 512 513 <screen><literal> ... 511 514 MANPATH=/usr/share/man 512 515 MANPATH=/usr/local/man 513 516 MANPATH=/usr/X11R6/man 514 517 MANPATH=/opt/qt/doc/man 515 ...</ userinput></screen>516 517 <para>Generally, package installation systems do not compress man/info pages,518 which means you will need to run the script again if you want to keep the size519 of your documentation as small as possible. Also, note that running the script520 after upgrading a package is safe; when you have several versions of a page521 (for example, one compressed and one uncompressed), the most recent one is kept522 and the others deleted.</para>518 ...</literal></screen> 519 520 <para>Generally, package installation systems do not compress man/info pages, 521 which means you will need to run the script again if you want to keep the size 522 of your documentation as small as possible. Also, note that running the script 523 after upgrading a package is safe; when you have several versions of a page 524 (for example, one compressed and one uncompressed), the most recent one is kept 525 and the others deleted.</para> 523 526 524 527 </sect1>
Note:
See TracChangeset
for help on using the changeset viewer.