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.

pvcstask.html 9.4 KiB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281
  1. <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
  2. <html>
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  5. <meta http-equiv="Content-Language" content="en-us">
  6. <link rel="stylesheet" type="text/css" href="../stylesheets/style.css"/>
  7. <title>PVCS task</title>
  8. </head>
  9. <body>
  10. <h1>
  11. Ant Pvcs Task User Manual</h1>
  12. <p><b>Note:</b>
  13. Before using this task, the user running ant must have access to the
  14. commands of PVCS (get and pcli) and must have access to the
  15. repository. Note that the way to specify the repository is platform
  16. dependent so use property to specify location of repository.
  17. </p>
  18. by
  19. <br><!-- Names are in alphabetical order, on last name -->
  20. <ul>
  21. <li>Thomas Christensen (<a href="mailto:tchristensen@nordija.com">tchristensen@nordija.com</a>)</li>
  22. <li>Don Jeffery (<a href="mailto:donj@apogeenet.com">donj@apogeenet.com</a>)</li>
  23. <li>Jon Dickinson (<a href="mailto:dickinson.j@ucles.org.uk">dickinson.j@ucles.org.uk</a>)</li>
  24. </ul>
  25. Version 1.1 - 2001/06/27<br>
  26. <p>Problems with UNC pathnames and the use of () in paths are fixed and an updateonly
  27. argument introduced.</p>
  28. Version 1.0 - 2001/01/31<br>
  29. <p>Initial release.</p>
  30. <hr>
  31. <h2>
  32. Table of Contents</h2>
  33. <ul>
  34. <li><a href="#introduction">Introduction</a></li>
  35. <li><a href="#pvcs">Pvcs Task</a></li>
  36. </ul>
  37. <hr>
  38. <h2><a NAME="introduction">Introduction</a></h2>
  39. The pvcs task allows the user of ant to extract the latest edition
  40. of the source code from a PVCS repository. PVCS is a version control system
  41. developed by <a href="http://www.merant.com/products/pvcs">Merant</a>.
  42. <br>
  43. This version has been tested against PVCS version 6.5 and 6.6 under Windows and Solaris.
  44. <hr>
  45. <h2><a NAME="pvcs">Pvcs Task</a></h2>
  46. <h3>Description</h3>
  47. The pvcs task is set to point at a PVCS repository and optionally a project
  48. within that repository, and can from that specification get the latest
  49. version of the files contained by the repository.
  50. <h3>
  51. Parameters</h3>
  52. <table BORDER CELLSPACING=0 CELLPADDING=2 >
  53. <tr>
  54. <td VALIGN=TOP WIDTH="12%"><b>Attribute</b></td>
  55. <td VALIGN=TOP WIDTH="78%"><b>Description</b></td>
  56. <td VALIGN=TOP WIDTH="10%"><b>Required</b></td>
  57. </tr>
  58. <tr>
  59. <td VALIGN=TOP WIDTH="12%">repository</td>
  60. <td VALIGN=TOP WIDTH="78%">The location of the repository (see your PVCS
  61. manuals)</td>
  62. <td VALIGN=TOP WIDTH="10%">Yes</td>
  63. </tr>
  64. <tr>
  65. <td VALIGN=TOP WIDTH="12%">pvcsproject</td>
  66. <td VALIGN=TOP WIDTH="78%">The project within the PVCS repository to extract
  67. files from (&quot;/&quot; is root project and that is default if this attribute isn't
  68. specified)</td>
  69. <td VALIGN=TOP WIDTH="10%">No</td>
  70. </tr>
  71. <tr>
  72. <td VALIGN=TOP WIDTH="12%">label</td>
  73. <td VALIGN=TOP WIDTH="78%">Only files marked with this label are extracted.</td>
  74. <td VALIGN=TOP WIDTH="10%">No</td>
  75. </tr>
  76. <tr>
  77. <td VALIGN=TOP WIDTH="12%">promotiongroup</td>
  78. <td VALIGN=TOP WIDTH="78%">Only files within this promotion group are extracted. Using
  79. both the <i>label</i> and the <i>promotiongroup</i> tag will cause the files in the
  80. promotion group and with that label to be extracted.
  81. </td>
  82. <td VALIGN=TOP WIDTH="10%">No</td>
  83. </tr>
  84. <tr>
  85. <td VALIGN=TOP WIDTH="12%">config</td>
  86. <td VALIGN=TOP WIDTH="78%">path of a non default .cfg file.
  87. Can be given absolute or relative to ant's base directory.
  88. </td>
  89. <td VALIGN=TOP WIDTH="10%">No</td>
  90. </tr>
  91. <tr>
  92. <td VALIGN=TOP WIDTH="12%">force</td>
  93. <td VALIGN=TOP WIDTH="78%">If set to <i>yes</i> all files that exists and are writable are overwritten. Default <i>no</i> causes the files that are writable to be ignored. This stops the PVCS command <i>get</i> to stop asking questions!</td>
  94. <td VALIGN=TOP WIDTH="10%">No</td>
  95. </tr>
  96. <tr>
  97. <td VALIGN=TOP WIDTH="12%">workspace</td>
  98. <td VALIGN=TOP WIDTH="78%">By specifying a workspace, the files are extracted to that location. A PVCS workspace is a
  99. name for a location of the workfiles and isn't as such the location itself. You define the location for a workspace
  100. using the PVCS GUI clients. If this isn't specified the default workspace for the current user is used.</td>
  101. <td VALIGN=TOP WIDTH="10%">No</td>
  102. </tr>
  103. <tr>
  104. <td VALIGN=TOP WIDTH="12%">pvcsbin</td>
  105. <td VALIGN=TOP WIDTH="78%">On some systems the PVCS executables <i>pcli</i>
  106. and <i>get</i> are not found in the PATH. In such cases this attribute
  107. should be set to the bin directory of the PVCS installation containing
  108. the executables mentioned before. If this attribute isn't specified the
  109. tag expects the executables to be found using the PATH environment variable.</td>
  110. <td VALIGN=TOP WIDTH="10%">No</td>
  111. </tr>
  112. <tr>
  113. <td VALIGN=TOP WIDTH="12%">ignorereturncode</td>
  114. <td VALIGN=TOP WIDTH="78%">If set to <i>true</i> the return value from executing
  115. the pvcs commands are ignored.</td>
  116. <td VALIGN=TOP WIDTH="10%">No</td>
  117. </tr>
  118. <tr>
  119. <td VALIGN=TOP WIDTH="12%">updateonly</td>
  120. <td VALIGN=TOP WIDTH="78%">If set to <i>true</i> files are gotten only if
  121. newer than existing local files.</td>
  122. <td VALIGN=TOP WIDTH="10%">No</td>
  123. </tr>
  124. <tr>
  125. <td valign="TOP">filenameformat</td>
  126. <td valign="TOP">The format of your folder names in a
  127. format suitable for <code>java.text.MessageFormat</code>.
  128. Defaults to <code>{0}-arc({1})</code>. Repositories where
  129. the archive extension is not <code>-arc</code> should set
  130. this.</td>
  131. <td valign="TOP">No</td>
  132. </tr>
  133. <tr>
  134. <td valign="TOP">linestart</td>
  135. <td valign="TOP">Used to parse the output of the pcli
  136. command. It defaults to <code>&quot;P:</code>. The parser already
  137. knows about / and \\, this property is useful in cases where the
  138. repository is accessed on a Windows platform via a drive letter
  139. mapping.</td>
  140. <td valign="TOP">No</td>
  141. </tr>
  142. <tr>
  143. <td valign="TOP">revision</td>
  144. <td valign="TOP">Retrieve the specified revision.</td>
  145. <td valign="TOP">No</td>
  146. </tr>
  147. <tr>
  148. <td valign="TOP">userid</td>
  149. <td valign="TOP">Use the specified userid.</td>
  150. <td valign="TOP">No</td>
  151. </tr>
  152. </table>
  153. <h3><a name="nested">Nested Elements</a></h3>
  154. <h3>pvcsproject element</h3>
  155. <p><code>pvcs</code> supports a nested
  156. <code>&lt;pvcsproject&gt;</code> element, that represents a project
  157. within the PVCS repository to extract files from. By nesting multiple
  158. <code>&lt;pvcsproject&gt;</code> elements under the
  159. <code>&lt;pvcs&gt;</code> task, multiple projects can be
  160. specified.</p>
  161. <h3>Parameters</h3>
  162. <table BORDER CELLSPACING=0 CELLPADDING=2 >
  163. <tr>
  164. <td VALIGN=TOP WIDTH="12%"><b>Attribute</b></td>
  165. <td VALIGN=TOP WIDTH="78%"><b>Description</b></td>
  166. <td VALIGN=TOP WIDTH="10%"><b>Required</b></td>
  167. </tr>
  168. <tr>
  169. <td VALIGN=TOP WIDTH="12%">name</td>
  170. <td VALIGN=TOP WIDTH="78%">The name of the pvcs project</td>
  171. <td VALIGN=TOP WIDTH="10%">Yes</td>
  172. </tr>
  173. </table>
  174. <h3>Examples</h3>
  175. The following set-up extracts the latest version of the files in the pvcs repository.
  176. <pre>
  177. &lt;!-- =================================================================== --&gt;
  178. &lt;!-- Get the latest version --&gt;
  179. &lt;!-- =================================================================== --&gt;
  180. &lt;target name=&quot;getlatest&quot;&gt;
  181. &lt;pvcs repository=&quot;/mnt/pvcs&quot; pvcsproject=&quot;/myprj&quot;/&gt;
  182. &lt;/target&gt;</ul>
  183. </pre>
  184. <p>Now run:</p>
  185. <code>ant getlatest</code>
  186. <p>This will cause the following output to appear:</p>
  187. <pre>
  188. getlatest:
  189. [pvcs] PVCS Version Manager (VMGUI) v6.6.10 (Build 870) for Windows NT/80x86
  190. [pvcs] Copyright 1985-2000 MERANT. All rights reserved.
  191. [pvcs] PVCS Version Manager (get) v6.6.10 (Build 870) for Windows NT/80x86
  192. [pvcs] Copyright 1985-2000 MERANT. All rights reserved.
  193. [pvcs] c:\myws\myprj\main.java &lt;- C:\mypvcs\archives\myprj\main.java-arc
  194. [pvcs] rev 1.1
  195. [pvcs] c:\myws\myprj\apache\tool.java &lt;- C:\mypvcs\archives\myprj\apache\tools.java-arc
  196. [pvcs] rev 1.5
  197. BUILD SUCCESSFUL
  198. Total time: 19 seconds</pre>
  199. This next example extracts the latest version of the files in the pvcs
  200. repository from two projects using nested <code>&lt;pvcsproject&gt;</code> elements.
  201. <pre>
  202. &lt;!-- ===================================================================--&gt;
  203. &lt;!-- Get latest from myprj and myprj2 --&gt;
  204. &lt;!-- ===================================================================--&gt;
  205. &lt;target name=&quot;getlatest2&quot;&gt;
  206. &lt;pvcs repository=&quot;/mnt/pvcs&quot;&gt;
  207. &lt;pvcsproject name=&quot;/myprj&quot;/&gt;
  208. &lt;pvcsproject name=&quot;/myprj2&quot;/&gt;
  209. &lt;/pvcs&gt;
  210. &lt;/target&gt;</ul>
  211. </pre>
  212. <p>Now run:</p>
  213. <code>ant getlatest2</code>
  214. <p>This will cause the following output to appear:</p>
  215. <pre>
  216. getlatest2:
  217. [pvcs] PVCS Version Manager (VMGUI) v6.6.10 (Build 870) for Windows NT/80x86
  218. [pvcs] Copyright 1985-2000 MERANT. All rights reserved.
  219. [pvcs] PVCS Version Manager (get) v6.6.10 (Build 870) for Windows NT/80x86
  220. [pvcs] Copyright 1985-2000 MERANT. All rights reserved.
  221. [pvcs] c:\myws\myprj\main.java &lt;- C:\mypvcs\archives\myprj\main.java-arc
  222. [pvcs] rev 1.1
  223. [pvcs] c:\myws\myprj\apache\tool.java &lt;- C:\mypvcs\archives\myprj\apache\tool.java-arc
  224. [pvcs] rev 1.5
  225. [pvcs] c:\myws\myprj2\apache\tool2.java &lt;- C:\mypvcs\archives\myprj2\apache\tool2.java-arc
  226. [pvcs] rev 1.2
  227. BUILD SUCCESSFUL
  228. Total time: 22 seconds</pre>
  229. <hr WIDTH="100%">
  230. <p align="center">Copyright &copy; 2001-2005 Apache Software
  231. Foundation. All rights Reserved.</p>
  232. <p>PVCS is a registered trademark of MERANT.</p>
  233. </body>
  234. </html>