You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

changelog.html 8.0 KiB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228
  1. <html>
  2. <head>
  3. <meta http-equiv="Content-Language" content="en-us">
  4. <title>ChangeLog Task</title>
  5. </head>
  6. <body>
  7. <h2><a name="changelog">CvsChangeLog</a></h2>
  8. <h3>Description</h3>
  9. <p>Generates an XML-formatted report file of the change logs recorded in a
  10. <a href="http://www.cvshome.org/" target="_top">CVS</a> repository. </p>
  11. <p><b>Important:</b> This task needs "cvs" on the path. If it isn't, you will get
  12. an error (such as error 2 on windows). If &lt;cvs&gt; doesn't work, try to execute cvs.exe
  13. from the command line in the target directory in which you are working.
  14. <h3>Parameters</h3>
  15. <table border="1" cellpadding="2" cellspacing="0">
  16. <tr>
  17. <td valign="top"><b>Attribute</b></td>
  18. <td valign="top"><b>Description</b></td>
  19. <td align="center" valign="top"><b>Required</b></td>
  20. </tr>
  21. <tr>
  22. <td colspan="3">Attributes from parent Cvs task which are meaningful here<br/>
  23. Since ant 1.6.1</td>
  24. </tr>
  25. <tr>
  26. <td valign="top">cvsRoot</td>
  27. <td valign="top">the <code>CVSROOT</code> variable.</td>
  28. <td align="center" valign="top">No</td>
  29. </tr>
  30. <tr>
  31. <td valign="top">cvsRsh</td>
  32. <td valign="top">the <code>CVS_RSH</code> variable.</td>
  33. <td align="center" valign="top">No</td>
  34. </tr>
  35. <tr>
  36. <td valign="top">package</td>
  37. <td valign="top">the package/module to check out.</td>
  38. <td align="center" valign="top">No</td>
  39. </tr>
  40. <tr>
  41. <td valign="top">port</td>
  42. <td valign="top">Port used by CVS to communicate with the server.</td>
  43. <td align="center" valign="top">No, default port 2401.</td>
  44. </tr>
  45. <tr>
  46. <td valign="top">passfile</td>
  47. <td valign="top">Password file to read passwords from.</td>
  48. <td align="center" valign="top">No, default file ~/.cvspass.</td>
  49. </tr>
  50. <tr>
  51. <td valign="top">failonerror</td>
  52. <td valign="top">Stop the build process if the command exits with a
  53. return code other than <code>0</code>. Defaults to false</td>
  54. <td align="center" valign="top">No</td>
  55. </tr>
  56. <tr>
  57. <td valign="top">tag</td>
  58. <td valign="top">query the changelog for a specific branch.</td>
  59. <td align="center" valign="top">No</td>
  60. </tr>
  61. <tr>
  62. <td colspan="3">Specific attributes</td>
  63. </tr>
  64. <tr>
  65. <td valign="top">dir</td>
  66. <td valign="top">The directory from which to run the CVS <em>log</em>
  67. command.</td>
  68. <td align="center" valign="top">No; defaults to ${basedir}.</td>
  69. </tr>
  70. <tr>
  71. <td valign="top">destfile</td>
  72. <td valign="top">The file in which to write the change log report.</td>
  73. <td align="center" valign="top">Yes</td>
  74. </tr>
  75. <tr>
  76. <td valign="top">usersfile</td>
  77. <td valign="top">Property file that contains name-value pairs mapping
  78. user IDs and names that should be used in the report in place of
  79. the user ID.</td>
  80. <td align="center" valign="top">No</td>
  81. </tr>
  82. <tr>
  83. <td valign="top">daysinpast</td>
  84. <td valign="top">Sets the number of days into the past for which the
  85. change log information should be retrieved.</td>
  86. <td align="center" valign="top">No</td>
  87. </tr>
  88. <tr>
  89. <td valign="top">start</td>
  90. <td valign="top">The earliest date from which change logs are to be
  91. included in the report.</td>
  92. <td align="center" valign="top">No</td>
  93. </tr>
  94. <tr>
  95. <td valign="top">end</td>
  96. <td valign="top">The latest date to which change logs are to be
  97. included in the report.</td>
  98. <td align="center" valign="top">No</td>
  99. </tr>
  100. </table>
  101. <h3>Parameters specified as nested elements</h3>
  102. <h4><a name="user">user</a></h4>
  103. <p>The nested <code>&lt;user&gt;</code> element allows you to specify a
  104. mapping between a user ID as it appears on the CVS server and a name to
  105. include in the formatted report.
  106. Anytime the specified user ID has made a change in the repository, the
  107. <code>&lt;author&gt;</code> tag in the report file will include
  108. the name specified in <code>displayname</code> rather than the user ID.
  109. </p>
  110. <table border="1" cellpadding="2" cellspacing="0">
  111. <tr>
  112. <td valign="top"><b>Attribute</b></td>
  113. <td valign="top"><b>Description</b></td>
  114. <td align="center" valign="top"><b>Required</b></td>
  115. </tr>
  116. <tr>
  117. <td valign="top">displayname</td>
  118. <td valign="top">The name to be used in the CVS change log report.</td>
  119. <td valign="top" align="center">Yes</td>
  120. </tr>
  121. <tr>
  122. <td valign="top">userid</td>
  123. <td valign="top">The userid of the person as it exists on the CVS server.
  124. </td>
  125. <td valign="top" align="center">Yes</td>
  126. </tr>
  127. </table>
  128. <h3>Examples</h3>
  129. <pre> &lt;cvschangelog dir=&quot;dve/network&quot;
  130. destfile=&quot;changelog.xml&quot;
  131. /&gt;</pre>
  132. <p>Generates a change log report for all the changes that have been made
  133. under the <code>dve/network</code> directory.
  134. It writes these changes into the file <code>changelog.xml</code>.</p>
  135. <pre> &lt;cvschangelog dir=&quot;dve/network&quot;
  136. destfile=&quot;changelog.xml&quot;
  137. daysinpast=&quot;10&quot;
  138. /&gt;</pre>
  139. <p>Generates a change log report for any changes that were made
  140. under the <code>dve/network</code> directory in the past 10 days.
  141. It writes these changes into the file <code>changelog.xml</code>.</p>
  142. <pre> &lt;cvschangelog dir=&quot;dve/network&quot;
  143. destfile=&quot;changelog.xml&quot;
  144. start=&quot;20 Feb 2002&quot;
  145. end=&quot;20 Mar 2002&quot;
  146. /&gt;</pre>
  147. <p>Generates a change log report for any changes that were made
  148. between February 20, 2002 and March 20, 2002
  149. under the <code>dve/network</code> directory.
  150. It writes these changes into the file <code>changelog.xml</code>.</p>
  151. <pre> &lt;cvschangelog dir=&quot;dve/network&quot;
  152. destfile=&quot;changelog.xml&quot;
  153. start=&quot;20 Feb 2002&quot;
  154. /&gt;</pre>
  155. <p>Generates a change log report for any changes that were made
  156. after February 20, 2002 under the <code>dve/network</code> directory.
  157. It writes these changes into the file <code>changelog.xml</code>.</p>
  158. <pre> &lt;cvschangelog dir=&quot;dve/network&quot;
  159. destfile=&quot;changelog.xml&quot;&gt;
  160. &lt;user displayname=&quot;Peter Donald&quot; userid=&quot;donaldp&quot;/&gt;
  161. &lt;/cvschangelog&gt;</pre>
  162. <p>Generates a change log report for all the changes that were made
  163. under the <code>dve/network</code> directory, substituting the name
  164. &quot;Peter Donald&quot; in the <code>&lt;author&gt;</code> tags
  165. anytime it encounters a change made by the user ID &quot;donaldp&quot;.
  166. It writes these changes into the file <code>changelog.xml</code>.</p>
  167. <p>Generates a change log report on the <code>ANT_16_BRANCH</code>.</p>
  168. <pre>
  169. &lt;cvschangelog dir=&quot;c:/dev/asf/ant.head&quot; passfile=&quot;c:/home/myself/.cvspass&quot;
  170. destfile=&quot;changelogant.xml&quot; tag=&quot;ANT_16_BRANCH&quot; /&gt;
  171. </pre>
  172. <h4>Generate Report</h4>
  173. <p>Ant includes a basic XSLT stylesheet that you can use to generate
  174. a HTML report based on the xml output. The following example illustrates
  175. how to generate a HTML report from the XML report.</p>
  176. <pre>
  177. &lt;style in="changelog.xml"
  178. out="changelog.html"
  179. style="${ant.home}/etc/changelog.xsl"&gt;
  180. &lt;param name="title" expression="Ant ChangeLog"/&gt;
  181. &lt;param name="module" expression="ant"/&gt;
  182. &lt;param name="cvsweb" expression="http://cvs.apache.org/viewcvs/"/&gt;
  183. &lt;/style&gt;
  184. </pre>
  185. <h4>Sample Output</h4>
  186. <pre>
  187. &lt;changelog&gt;
  188. &lt;entry&gt;
  189. &lt;date&gt;2002-03-06&lt;/date&gt;
  190. &lt;time&gt;12:00&lt;/time&gt;
  191. &lt;author&gt;Peter Donald&lt;/author&gt;
  192. &lt;file&gt;
  193. &lt;name&gt;org/apache/myrmidon/build/AntlibDescriptorTask.java&lt;/name&gt;
  194. &lt;revision&gt;1.3&lt;/revision&gt;
  195. &lt;prevrevision&gt;1.2&lt;/prevrevision&gt;
  196. &lt;/file&gt;
  197. &lt;msg&gt;&lt;![CDATA[Use URLs directly rather than go via a FIle.
  198. This allows temp[lates to be stored inside jar]]&gt;&lt;/msg&gt;
  199. &lt;/entry&gt;
  200. &lt;/changelog&gt;
  201. </pre>
  202. <hr><p align="center">Copyright &copy; 2002-2004 Apache Software Foundation. All rights
  203. Reserved.</p>
  204. </body>
  205. </html>