install-info.8 8.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300
  1. .\" Install-info and this manpage are Copyright 1994 by Ian Jackson.
  2. .\"
  3. .\" This is free software; see the GNU General Public Licence version 2
  4. .\" or later for copying conditions. There is NO warranty.
  5. .TH install\-info 8 "2007-05-15" "Debian Project" "dpkg utilities"
  6. .SH NAME
  7. install\-info - create or update entry in Info dir file
  8. .
  9. .SH SYNOPSIS
  10. .B install\-info
  11. .RB [ \-\-version ]
  12. .RB [ \-\-help ]
  13. .RB [ \-\-debug ]
  14. .RB [ \-\-maxwidth=\fInnn\fP ]
  15. .RB [ "\-\-section \fIregexp\fP \fItitle\fP" ]
  16. .RB [ \-\-infodir=\fIxxx\fP ]
  17. .RB [ \-\-align=\fInnn\fP ]
  18. .RB [ \-\-quiet ]
  19. .RB [ \-\-menuentry=\fIxxx\fP ]
  20. .RB [ \-\-description=\fIxxx\fP ]
  21. .RB [ \-\-remove | \-\-remove\-exactly ]
  22. .RB [ \-\- ]
  23. .I filename
  24. .
  25. .SH DESCRIPTION
  26. .B install\-info
  27. creates, updates or removes entries in the Info
  28. .B dir
  29. file. When updating or creating entries, if no description is
  30. specified on the command line or in the Info file, it attempts to guess
  31. a description from the contents of the file.
  32. .PP
  33. See the description of the
  34. .B \-\-section
  35. option for details of where the entry will be placed and a description
  36. of the expected format of the
  37. .B dir
  38. file.
  39. .SH OPTIONS
  40. .TP
  41. .BI "[\-\-] " filename
  42. Gives the filename of the Info file whose menu entry is to be created,
  43. updated or removed. If
  44. .B \-\-remove\-exactly
  45. is specified, then
  46. .I filename
  47. should be the exact entry name to be removed (i.e. "emacs\-20/emacs" or
  48. "gcc"), otherwise the basename of this filename is used as the
  49. referent of the menu entry which is created, unless there's an
  50. overriding START-INFO-DIR entry inside the given file. This file must
  51. therefore exist (or be about to be installed, or have previously
  52. existed when removing an entry) in the same directory as the
  53. .B dir
  54. file (see the
  55. .B \-\-infodir
  56. option).
  57. If
  58. .I filename
  59. ends in
  60. .B .gz
  61. , it is taken to refer to a file compressed with GNU gzip; if it doesn't
  62. exist, but a corresponding
  63. .IB filename .gz
  64. does, the latter is used instead.
  65. When adding or updating entries, the file must exist at the path
  66. specified (possibly with an additional
  67. .B .gz
  68. extension).
  69. .TP
  70. .B \-\-remove
  71. Specifies that the entry for the file
  72. .I filename
  73. is to be removed; by default entries are created or updated.
  74. If the removal results in a section becoming empty, the section heading
  75. (and the spare blank line) will be removed as well, unless this is the
  76. last section in the file or
  77. .B \-\-keep\-old
  78. is specified. See the
  79. .B \-\-section
  80. option for details about the expected format of the
  81. .B dir
  82. file.
  83. If there are several suitable entries in the
  84. .B dir
  85. file, only those in the first matching contiguous group will be removed
  86. and the others silently ignored.
  87. It is not an error for no suitable entry to be found, though
  88. .B install\-info
  89. will issue a warning unless the
  90. .B \-\-quiet
  91. option was specified.
  92. When
  93. .B \-\-remove
  94. is specified the
  95. .BR \-\-maxwidth ", " \-\-align " and " \-\-calign
  96. formatting options are silently ignored.
  97. .TP
  98. .B \-\-remove\-exactly
  99. This option is essentially the same as
  100. .B \-\-remove
  101. except that
  102. .I filename
  103. is taken as the exact entry to be removed, rather than as the name
  104. of an existing file. This can be important when trying to remove
  105. entries that refer to info files in subdirectories
  106. (i.e. "emacs\-20/emacs") because
  107. .B \-\-remove
  108. will operate on the basename of the given
  109. .I filename
  110. rather than the exact name given. (i.e.
  111. .B \-\-remove
  112. "emacs\-20/emacs" would cause
  113. .B install\-info
  114. to look for "emacs", not "emacs\-20/emacs").
  115. .TP
  116. .BI "\-\-section " "regexp title"
  117. Specifies that if a new entry is to be made, it should be placed in a
  118. section of the
  119. .B dir
  120. file whose title matches
  121. .IR regexp .
  122. If no such section exists, one will be created as the second to last
  123. section in the file (see below) with title
  124. .IR title .
  125. A section is a part of the
  126. .B dir
  127. menu delimited by blank lines; the first line is assumed to be the
  128. title.
  129. If a new entry is to be created,
  130. .B install\-info
  131. will attempt to insert it within the section in alphabetic order. If
  132. the entries in the section aren't already sorted, the new location
  133. within the section will be unpredictable. The order of existing
  134. entries will not be changed.
  135. If the
  136. .B \-\-section
  137. option is not specified,
  138. .B install\-info
  139. will look for a title in the Info file itself by looking for an entry
  140. of the form
  141. .br
  142. .BI "INFO\-DIR\-SECTION" " title"
  143. .br
  144. If no section title is found, the default is to append new entries to
  145. the end of the file. The last section (even if it only consists of the
  146. title line) should always exist to ensure that new sections are
  147. created in the right place. The final section should be titled to
  148. reflect the fact that Info files with no better specified location
  149. are appended to it.
  150. If there is already an entry for the Info file being installed, it is
  151. replaced in situ with the new entry.
  152. If a section is specified when removing an entry, the section is
  153. ignored and a warning is issued.
  154. If a section is requested when adding an entry, but the file contains
  155. no section headings at all, then
  156. .B install\-info
  157. will create both the requested section and a Miscellaneous section at
  158. the end of the file.
  159. .TP
  160. .BI \-\-infodir= infodir
  161. Specifies that the
  162. .B dir
  163. file is, and the installed copy of the new Info file was, is or will
  164. be located in
  165. .IR infodir .
  166. The default is
  167. .BR /usr/share/info/ .
  168. .TP
  169. .BI \-\-align= nnn " [deprecated]"
  170. Specifies that the first line of the description should be indented at
  171. least
  172. .I nnn
  173. characters; extra spaces will be added as required. If necessary
  174. because of the length of the
  175. .B dir
  176. menu entry details, it may be offset more. The default is 27.
  177. .TP
  178. .BI \-\-calign= nnn " [deprecated]"
  179. Specifies that the second and subsequent lines of the description
  180. should be indented at least
  181. .I nnn
  182. characters. The default is 29.
  183. .TP
  184. .BI \-\-maxwidth= nnn " [deprecated]"
  185. Specifies that the maximum width for the Info file is
  186. .IR nnn .
  187. This is used when word-wrapping the descriptive text.
  188. The default is 79.
  189. .TP
  190. .B \-\-quiet
  191. Prevents the usual display of the new menu entry just before it is
  192. inserted and of the messages announcing the replacement and removal
  193. of existing entries and the creation and deletion of sections.
  194. .TP
  195. .B \-\-help
  196. Causes
  197. .B install\-info
  198. to display its usage information and exit.
  199. .TP
  200. .B \-\-version
  201. Causes
  202. .B install\-info
  203. to display its version and copyright information and exit.
  204. .TP
  205. .BI \-\-description= xxx
  206. Specifies that the description to use after the menu entry in new or
  207. updated entries be
  208. .IR xxx .
  209. The default is to use the the value specified in the Info file itself;
  210. this is found by searching for a section of the form
  211. .br
  212. .B START\-INFO\-DIR\-ENTRY
  213. .br
  214. .B * Auto-PGP: (auto-pgp). PGP under GNU Emacs.
  215. .br
  216. .B END\-INFO\-DIR\-ENTRY
  217. If the entry found in the Info file itself extends across several
  218. lines, each giving a menu entry, the text found in the file is used
  219. verbatim. In this case, the alphabetic ordering scheme is turned off,
  220. and the entries are inserted at the top of section in question. In
  221. this case, the
  222. .BR \-\-menuentry ", " \-\-maxwidth ", " \-\-align ", " \-\-calign
  223. .RB " and " \-\-menuentry
  224. options are ignored.
  225. If there is no
  226. .B dir
  227. entry in the file, the program will try to find a paragraph early in
  228. the file starting
  229. .BR "this file documents" .
  230. It will capitalise the first character of the remainder, and use that.
  231. It is an error for none of these methods to yield a description.
  232. If a description argument is given when
  233. .B \-\-remove
  234. is specified, it is ignored and a warning is issued.
  235. .TP
  236. .BI \-\-menuentry= xxx
  237. Specifies that the entry in the menu should be
  238. .IR xxx .
  239. The default is to use the the value specified in the Info file itself.
  240. If this is not present, the basename of the Info file is used
  241. .RB "(any " ".info " "is deleted, and the entry is made mixed case)."
  242. See above for details of the format expected for the menu entry in the
  243. Info file.
  244. When removing entries, the value of the
  245. .B \-\-menuentry
  246. option must match the actual menu entry field in the menu item to be
  247. removed (case not significant). If
  248. .B \-\-menuentry
  249. is omitted, no check on the menu entry is done.
  250. .TP
  251. .B \-\-keep\-old
  252. Inhibits the replacement of existing entries and the removal of empty
  253. sections.
  254. If the file being installed already has an entry in the Info \fBdir\fP file,
  255. the old entry will be left alone instead of being replaced; the default is
  256. to overwrite any old entry found with the newly generated one.
  257. If
  258. .BR \-\-remove " is specified, " \-\-keep\-old
  259. will prevent the removal of the section heading which would otherwise
  260. happen if the section is made empty by the removal.
  261. .TP
  262. .B \-\-test
  263. Enables test mode, which inhibits the update of the Info \fBdir\fP file.
  264. .TP
  265. .B \-\-debug
  266. Enables debugging mode, in which the results of some internal
  267. processing steps are shown.
  268. .
  269. .SH "SEE ALSO"
  270. .BR emacs (1),
  271. .BR info (1),
  272. .BR gzip(1).
  273. .SH COPYRIGHT
  274. Copyright 1994, Ian Jackson.
  275. .B install\-info
  276. is free software; see the GNU General Public Licence version 2 or
  277. later for copying conditions. There is
  278. .I no
  279. warranty.