xmlcatalog.1 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229
  1. .\" ** You probably do not want to edit this file directly **
  2. .\" It was generated using the DocBook XSL Stylesheets (version 1.69.1).
  3. .\" Instead of manually editing it, you probably should edit the DocBook XML
  4. .\" source for it and then use the DocBook XSL Stylesheets to regenerate it.
  5. .TH "XMLCATALOG" "1" "$Date$" "libxml2" ""
  6. .\" disable hyphenation
  7. .nh
  8. .\" disable justification (adjust text to left margin only)
  9. .ad l
  10. .SH "NAME"
  11. xmlcatalog \- Command line tool to parse and manipulate XML or SGML catalog files.
  12. .SH "SYNOPSIS"
  13. .HP 11
  14. \fBxmlcatalog\fR [\fB\-\-sgml\fR \fB\-\-shell\fR \fB\-\-create\fR \fB\-\-del\ \fR\fB\fIVALUE(S)\fR\fR [\ \fB\-\-add\ \fR\fB\fITYPE\fR\fR\fB\ \fR\fB\fIORIG\fR\fR\fB\ \fR\fB\fIREPLACE\fR\fR\fB\ \fR\ \fB\-\-add\ \fR\fB\fIFILENAME\fR\fR] \fB\-\-noout\fR \fB\-\-no\-super\-update\fR [\fB\-v\fR\ \fB\-\-verbose\fR]] {\fICATALOGFILE\fR} {\fIENTITIES\fR...}
  15. .SH "DESCRIPTION"
  16. .PP
  17. \fBxmlcatalog\fR
  18. is a command line application allowing users to monitor and manipulate
  19. XML
  20. and
  21. SGML
  22. catalogs. It is included in
  23. \fBlibxml\fR(3).
  24. .PP
  25. Its functions can be invoked from a single command from the command line, or it can perform multiple functions in interactive mode. It can operate on both
  26. XML
  27. and
  28. SGML
  29. files.
  30. .SH "OPTIONS"
  31. .PP
  32. \fBxmlcatalog\fR
  33. accepts the following options (in alphabetical order):
  34. .TP
  35. \fB\-\-add \fR\fB\fITYPE\fR\fR\fB \fR\fB\fIORIG\fR\fR\fB \fR\fB\fIREPLACE\fR\fR\fB \fR
  36. Add an entry to
  37. \fICATALOGFILE\fR.
  38. \fITYPE\fR
  39. indicates the type of entry. Possible types are:
  40. \fIpublic\fR, \fIsystem\fR, \fIrewriteSystem\fR, \fIrewriteURI\fR, \fIdelegatePublic\fR, \fIdelegateSystem\fR, \fInextCatalog\fR.
  41. \fIORIG\fR
  42. is the original reference to be replaced, and
  43. \fIREPLACE\fR
  44. is the
  45. URI
  46. of the replacement entity to be used. The
  47. \fB\-\-add\fR
  48. option will not overwrite
  49. \fICATALOGFILE\fR, outputting to
  50. \fIstdout\fR, unless
  51. \fB\-\-noout\fR
  52. is used. The
  53. \fB\-\-add\fR
  54. will always take three parameters even if some of the
  55. XML
  56. catalog constructs will have only a single argument.
  57. .TP
  58. \fB\-\-add \fR\fB\fIFILENAME\fR\fR
  59. If the
  60. \fB\-\-add\fR
  61. option is used following the
  62. \fB\-\-sgml\fR
  63. option, only a single argument, a
  64. \fIFILENAME\fR, is used. This is used to add the name of a catalog file to an
  65. SGML
  66. supercatalog, a file that contains references to other included
  67. SGML
  68. catalog files.
  69. .TP
  70. \fB\-\-create\fR
  71. Create a new
  72. XML
  73. catalog. Outputs to
  74. \fIstdout\fR, ignoring
  75. \fIfilename\fR
  76. unless
  77. \fB\-\-noout\fR
  78. is used, in which case it creates a new catalog file
  79. \fIfilename\fR.
  80. .TP
  81. \fB\-\-del \fR\fB\fIVALUE(S)\fR\fR
  82. Remove entries from
  83. \fICATALOGFILE\fR
  84. matching
  85. \fIVALUE(S)\fR. The
  86. \fB\-\-del\fR
  87. option will not overwrite
  88. \fICATALOGFILE\fR, outputting to
  89. \fIstdout\fR, unless
  90. \fB\-\-noout\fR
  91. is used.
  92. .TP
  93. \fB\-\-noout\fR
  94. Save output to the named file rather than outputting to
  95. \fIstdout\fR.
  96. .TP
  97. \fB\-\-no\-super\-update\fR
  98. Do not update the
  99. SGML
  100. super catalog.
  101. .TP
  102. \fB\-\-shell\fR
  103. Run a shell allowing interactive queries on catalog file
  104. \fICATALOGFILE\fR. For the set of available commands see
  105. the section called \(lqSHELL COMMANDS\(rq.
  106. .TP
  107. \fB\-\-sgml\fR
  108. Uses
  109. SGML
  110. super catalogs for
  111. \fB\-\-add\fR
  112. and
  113. \fB\-\-del\fR
  114. options.
  115. .TP
  116. \fB\-v\fR, \fB\-\-verbose\fR
  117. Output debugging information.
  118. .SH "SHELL COMMANDS"
  119. .PP
  120. Invoking
  121. \fBxmlcatalog\fR
  122. with the
  123. \fB\-\-shell \fR\fB\fICATALOGFILE\fR\fR
  124. option opens a command line shell allowing interactive access to the catalog file identified by
  125. \fICATALOGFILE\fR. Invoking the shell provides a command line prompt after which the following commands (described in alphabetical order) can be entered.
  126. .TP
  127. \fBadd \fR\fB\fITYPE\fR\fR\fB \fR\fB\fIORIG\fR\fR\fB \fR\fB\fIREPLACE\fR\fR\fB \fR
  128. Add an entry to the catalog file.
  129. \fITYPE\fR
  130. indicates the type of entry. Possible types are:
  131. \fIpublic\fR, \fIsystem\fR, \fIrewriteSystem\fR, \fIrewriteURI\fR, \fIdelegatePublic\fR, \fIdelegateSystem\fR, \fInextCatalog\fR.
  132. \fIORIG\fR
  133. is the original reference to be replaced, and
  134. \fIREPLACE\fR
  135. is the
  136. URI
  137. of the replacement entity to be used. The
  138. \fB\-\-add\fR
  139. option will not overwrite
  140. \fICATALOGFILE\fR, outputting to
  141. \fIstdout\fR, unless
  142. \fB\-\-noout\fR
  143. is used. The
  144. \fB\-\-add\fR
  145. will always take three parameters even if some of the
  146. XML
  147. catalog constructs will have only a single argument.
  148. .TP
  149. \fBdebug\fR
  150. Print debugging statements showing the steps
  151. \fBxmlcatalog\fR
  152. is executing.
  153. .TP
  154. \fBdel \fR\fB\fIVALUE(S)\fR\fR
  155. Remove the catalog entry corresponding to
  156. \fIVALUE(S)\fR.
  157. .TP
  158. \fBdump\fR
  159. Print the current catalog.
  160. .TP
  161. \fBexit\fR
  162. Quit the shell.
  163. .TP
  164. \fBpublic \fR\fB\fIPUBLIC\-ID\fR\fR
  165. Execute a Formal Public Identifier look\-up of the catalog entry for
  166. \fIPUBLIC\-ID\fR. The corresponding entry will be output to the command line.
  167. .TP
  168. \fBquiet\fR
  169. Stop printing debugging statements.
  170. .TP
  171. \fBsystem \fR\fB\fISYSTEM\-ID\fR\fR
  172. Execute a Formal Public Identifier look\-up of the catalog entry for
  173. \fISYSTEM\-ID\fR. The corresponding entry will be output to the command line.
  174. .SH "ENVIRONMENT"
  175. .TP
  176. \fBXML_CATALOG_FILES\fR
  177. XML
  178. catalog behavior can be changed by redirecting queries to the user's own set of catalogs. This can be done by setting the
  179. \fBXML_CATALOG_FILES\fR
  180. environment variable to a list of catalogs. An empty one should deactivate loading the default
  181. \fI/etc/xml/catalog\fR
  182. catalog.
  183. .SH "DIAGNOSTICS"
  184. .PP
  185. \fBxmlcatalog\fR
  186. return codes provide information that can be used when calling it from scripts.
  187. .TP
  188. \fB0\fR
  189. No error
  190. .TP
  191. \fB1\fR
  192. Failed to remove an entry from the catalog
  193. .TP
  194. \fB2\fR
  195. Failed to save to the catalog, check file permissions
  196. .TP
  197. \fB3\fR
  198. Failed to add an entry to the catalog
  199. .TP
  200. \fB4\fR
  201. Failed to look up an entry in the catalog
  202. .SH "SEE ALSO"
  203. .PP
  204. \fBlibxml\fR(3)
  205. .PP
  206. More information can be found at
  207. .TP 3
  208. \(bu
  209. \fBlibxml\fR(3)
  210. web page
  211. \fI\%http://www.xmlsoft.org/\fR
  212. .TP
  213. \(bu
  214. \fBlibxml\fR(3)
  215. catalog support web page at
  216. \fI\%http://www.xmlsoft.org/catalog.html\fR
  217. .TP
  218. \(bu
  219. James Clark's
  220. SGML
  221. catalog page
  222. \fI\%http://www.jclark.com/sp/catalog.htm\fR
  223. .TP
  224. \(bu
  225. OASISXML
  226. catalog specification
  227. \fI\%http://www.oasis\-open.org/committees/entity/spec.html\fR
  228. .SH "AUTHOR"
  229. John Fleck <jfleck@inkstain.net>.