conref-task.dita 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
  3. <!-- This file is part of the DITA Open Toolkit project. See the accompanying LICENSE file for applicable license. -->
  4. <task id="ID">
  5. <title>Conref file for tasks</title>
  6. <taskbody>
  7. <context>
  8. <p id="semver-info">DITA-OT releases follow
  9. <xref keyref="semver"/> guidelines. Version numbers use the
  10. <codeph><varname>major</varname>.<varname>minor</varname>.<varname>patch</varname></codeph> syntax, where
  11. <varname>major</varname> versions may include incompatible API changes, <varname>minor</varname> versions add
  12. functionality in a backwards-compatible manner and <varname>patch</varname> versions are maintenance releases
  13. that include backwards-compatible bug fixes.</p>
  14. <p id="semver-plugins">Custom plug-ins developed for a previous <varname>major</varname> version may require
  15. changes to work correctly with recent toolkit versions. Most plug-ins should be compatible with subsequent
  16. <varname>minor</varname> and <varname>patch</varname> versions of the <varname>major</varname> release for
  17. which they were originally developed.</p>
  18. <dl>
  19. <dlentry>
  20. <dt>Standard Path / Directory Names</dt>
  21. <dd><filepath id="ot-dir"><varname>dita-ot-dir</varname></filepath></dd>
  22. <dd><filepath id="dita-cmd"><varname>dita-ot-dir</varname>/bin/<cmdname>dita</cmdname></filepath></dd>
  23. <dd><filepath id="docsrc-dir"><varname>dita-ot-dir</varname>/docsrc</filepath></dd>
  24. <dd><filepath id="samples-dir"><varname>dita-ot-dir</varname>/docsrc/samples</filepath></dd>
  25. <dd><filepath id="samples-absolute"
  26. ><varname>/absolute/path/to/dita-ot-dir</varname>/docsrc/samples</filepath></dd>
  27. </dlentry>
  28. <dlentry>
  29. <dt>Plug-In Info</dt>
  30. <dd>
  31. <ul>
  32. <li id="plug-in-id"><filepath><varname>&lt;plug-in-id&gt;</varname></filepath> is the unique ID of the
  33. plug-in, as defined in the plug-in’s configuration file (<filepath>plugin.xml</filepath>).</li>
  34. <li id="plug-in-zip"><filepath><varname>plug-in-zip</varname></filepath> is the
  35. <varname>filename</varname> or <varname>URL</varname> of the plug-in’s distribution ZIP file
  36. (optional).</li>
  37. <li id="plug-in">the optional <filepath><varname>&lt;plug-in&gt;</varname></filepath> argument is one of
  38. the following:
  39. <ul>
  40. <li>the unique <varname>ID</varname> of the plug-in as defined in the plug-in registry at
  41. <xref keyref="site-plugin-registry"/> (or a local registry)</li>
  42. <li>the remote <varname>URL</varname> of the plug-in’s distribution ZIP file</li>
  43. <li>the name of a local ZIP <varname>file</varname></li>
  44. </ul>
  45. </li>
  46. <li><ph id="plugin-integrate-all">If no <varname>ID</varname>, <varname>URL</varname>, or
  47. <varname>file</varname> argument is provided, the installation process reloads the current set of
  48. plug-ins from the <filepath>plugins</filepath> directory. This approach can be used to add or remove
  49. multiple plug-ins at once, or any individual plug-ins you have already copied to (or removed from) the
  50. <filepath>plugins</filepath> directory. Any plug-ins added or removed in the process will be listed
  51. by their plug-in ID.</ph></li>
  52. <li><note id="plugin-remove-subdir" type="attention">The <cmdname>uninstall</cmdname> subcommand also
  53. removes the corresponding plug-in directory from the <filepath>plugins</filepath> folder.
  54. <indexterm>uninstalling</indexterm></note></li>
  55. <li><note>
  56. <ph id="pre-subcommands-2-4-ph">In earlier versions of DITA-OT (2.4–3.4), use the double-hyphen option
  57. syntax <cmdname>dita</cmdname></ph>
  58. <parmname>--uninstall</parmname>. <ph id="pre-subcommands-2-0-ph">In DITA-OT 2.0–2.3, use the
  59. single-hyphen form: <cmdname>dita</cmdname></ph>
  60. </note></li>
  61. </ul>
  62. </dd>
  63. </dlentry>
  64. </dl>
  65. </context>
  66. <steps>
  67. <step>
  68. <cmd>
  69. <!-- Used in installation topic & Release Notes -->
  70. <ph id="download-ot">Download the <filepath>dita-ot-<keyword keyref="maintenance-version"/>.zip</filepath>
  71. package from the project website at
  72. <xref keyref="download.dita-ot"/>.</ph>
  73. </cmd>
  74. </step>
  75. <step>
  76. <cmd id="open-terminal">Open a command prompt or terminal session, and then change to the directory where DITA
  77. Open Toolkit is installed.</cmd>
  78. <info>
  79. <ul id="basic-variables">
  80. <li id="novice-variables-1"><filepath conref="#ID/ot-dir"/> is the DITA-OT installation directory.</li>
  81. <li id="novice-variables-2"><varname>input-file</varname> is the DITA map or DITA file that you want to
  82. process.</li>
  83. <!-- ↓ excerpt-variables ↓ -->
  84. <li id="novice-variables-last" audience="novice">
  85. <p id="common-format-info">
  86. <varname>format</varname> is the output format (transformation type). This argument corresponds to the
  87. common parameter <parmname>transtype</parmname>. Use the same values as for the
  88. <parmname>transtype</parmname> build parameter, for example <option>html5</option> or
  89. <option>pdf</option>. </p>
  90. </li>
  91. <!-- ↑ end-excerpt ↑ -->
  92. <li id="expert-variables-last" audience="expert">
  93. <p conref="#ID/common-format-info"/>
  94. <p id="transtypes">You can create plug-ins to add new output formats; by default, the following values are
  95. available:
  96. <indexterm>transtype
  97. <indexterm>list</indexterm></indexterm>
  98. <ul>
  99. <li><option>dita</option></li>
  100. <li><option>eclipsehelp</option></li>
  101. <li><option>html5</option></li>
  102. <li platform="windows"><option>htmlhelp</option></li>
  103. <li><option>markdown</option>, <option>markdown_gitbook</option>, and
  104. <option>markdown_github</option></li>
  105. <li><option>pdf</option></li>
  106. <li><option>xhtml</option></li>
  107. </ul>
  108. <note type="tip">See
  109. <xref keyref="output-formats"/> for sample command line syntax and more information on each
  110. transformation. </note>
  111. </p>
  112. </li>
  113. <li id="options">[<varname>options</varname>] include the following optional build parameters:
  114. <parml conkeyref="dita-command-arguments/dita_build_options">
  115. <plentry>
  116. <pt/>
  117. <pd/>
  118. </plentry>
  119. </parml></li>
  120. </ul>
  121. </info>
  122. <stepresult id="running-ditaot-results">
  123. <p>If processing is successful, nothing is printed in the terminal window. The built output is written to the
  124. specified output directory (by default, in the <filepath>out</filepath> subdirectory of the current
  125. directory).</p>
  126. <note id="dita-in-path" type="tip">Add the absolute path for <filepath conref="#ID/ot-dir"
  127. /><filepath>/bin</filepath> to the <varname>PATH</varname> environment variable to run the
  128. <cmdname>dita</cmdname> command from any location on the file system without typing the path.
  129. <indexterm><cmdname>dita</cmdname> command
  130. <indexterm>PATH environment variable</indexterm></indexterm>
  131. </note>
  132. </stepresult>
  133. </step>
  134. <step>
  135. <cmd>Extending pre-processing</cmd>
  136. <info>
  137. <note id="tip-extend-before-after-preprocessing" type="tip">For maximum compatibility with future versions of
  138. DITA-OT, most plug-ins should use the extension points that run <b>before</b> or <b>after</b>
  139. pre-processing.</note>
  140. <note id="caution-extend-within-preprocessing" type="caution">The internal order of preprocessing steps is
  141. subject to change between versions of DITA-OT. New versions may remove, reorder, combine, or add steps to
  142. the process, so the extension points <b>within</b> the preprocessing stage should only be used if absolutely
  143. necessary.</note>
  144. </info>
  145. </step>
  146. </steps>
  147. <postreq>
  148. <note type="tip" id="template-properties">Copy <filepath conref="#ID/samples-dir"
  149. /><filepath>/properties/template.properties</filepath>; this template describes each of the properties you can
  150. set.</note>
  151. <note type="tip" id="pass-input-dir">If you are building in different environments where the location of the input
  152. files is not consistent, set <option>args.input.dir</option> with the <cmdname>dita</cmdname> command and
  153. reference its value with <codeph>${args.input.dir}</codeph> in your <filepath>.properties</filepath> file.
  154. <indexterm><cmdname>dita</cmdname> command
  155. <indexterm><option>args.input.dir</option></indexterm>
  156. <indexterm>.properties file</indexterm></indexterm>
  157. <indexterm>args.input.dir</indexterm>
  158. </note>
  159. </postreq>
  160. </taskbody>
  161. </task>