Mercurial > bitten > bitten-test
annotate doc/commands.txt @ 414:aa34d82b2c9a
The build slave can now run locally against a recipe file, which is useful for testing recipes. Simply pass the path to the recipe instead of the URL of the build master to the script.
author | cmlenz |
---|---|
date | Wed, 08 Aug 2007 12:10:46 +0000 |
parents | fa72698e7477 |
children | b4ec24092b54 |
rev | line source |
---|---|
412 | 1 .. -*- mode: rst; encoding: utf-8 -*- |
2 | |
3 ===================== | |
4 Build Recipe Commands | |
5 ===================== | |
6 | |
7 Build recipes are represented by XML documents. This page describes what | |
8 commands are generally available in recipes. Please note, though, that | |
9 third-party packages can add additional commands, which would then be | |
10 documented by that third party. | |
11 | |
12 .. contents:: Contents | |
13 :depth: 2 | |
14 .. sectnum:: | |
15 | |
16 | |
17 Generic Commands | |
18 ================ | |
19 | |
20 These are commands that are used without a namespace prefix. | |
21 | |
22 | |
23 ------------ | |
24 ``<report>`` | |
25 ------------ | |
26 | |
27 Parse an XML file and send it to the master as a report with a given category. | |
28 Use this command in conjunction with the ``<sh:pipe>`` or ``<x:transform>`` | |
29 commands to send custom reports to the build master. | |
30 | |
31 Parameters | |
32 ---------- | |
33 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
34 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
35 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
36 +==============+=============================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
37 | ``category`` | Category of the report (for example "test" or "coverage"). | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
38 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
39 | ``file`` | Path to the XML file containing the report data, relative | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
40 | | to the project directory. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
41 +--------------+-------------------------------------------------------------+ |
412 | 42 |
43 Both parameters must be specified. | |
44 | |
45 | |
46 Shell Tools | |
47 =========== | |
48 | |
49 A bundle of generic tools that are not specific to any programming language or | |
50 tool-chain. | |
51 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
52 :Namespace: ``http://bitten.cmlenz.net/tools/sh`` |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
53 :Common prefix: ``sh`` |
412 | 54 |
55 | |
56 ------------- | |
57 ``<sh:exec>`` | |
58 ------------- | |
59 | |
60 Executes a program or script. | |
61 | |
62 Parameters | |
63 ---------- | |
64 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
65 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
66 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
67 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
68 | ``executable`` | The name of the executable program. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
69 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
70 | ``file`` | Path to the script to execute, relative to the project | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
71 | | directory | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
72 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
73 | ``output`` | Path to the output file | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
74 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
75 | ``args`` | Any arguments to pass to the executable or script | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
76 +----------------+-----------------------------------------------------------+ |
412 | 77 |
78 Either ``executable`` or ``file`` must be specified. | |
79 | |
80 Examples | |
81 -------- | |
82 | |
83 TODO | |
84 | |
85 | |
86 ------------- | |
87 ``<sh:pipe>`` | |
88 ------------- | |
89 | |
90 Pipes the content of a file through a program or script. | |
91 | |
92 Parameters | |
93 ---------- | |
94 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
95 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
96 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
97 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
98 | ``executable`` | The name of the executable program. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
99 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
100 | ``file`` | Path to the script to execute, relative to the project | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
101 | | directory | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
102 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
103 | ``input`` | Path to the input file | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
104 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
105 | ``output`` | Path to the output file | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
106 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
107 | ``args`` | Any arguments to pass to the executable or script | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
108 +----------------+-----------------------------------------------------------+ |
412 | 109 |
110 Either ``executable`` or ``file`` must be specified. | |
111 | |
112 Examples | |
113 -------- | |
114 | |
115 TODO | |
116 | |
117 | |
118 C/Unix Tools | |
119 ============ | |
120 | |
121 These commands provide support for tools commonly used for development of C/C++ | |
122 applications on Unix platforms, such as ``make``. | |
123 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
124 :Namespace: ``http://bitten.cmlenz.net/tools/c`` |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
125 :Common prefix: ``c`` |
412 | 126 |
127 | |
128 ----------------- | |
129 ``<c:configure>`` | |
130 ----------------- | |
131 | |
132 Executes a configure script as generated by Autoconf. | |
133 | |
134 Parameters | |
135 ---------- | |
136 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
137 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
138 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
139 +==============+=============================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
140 | ``file`` | Name of the configure script (defaults to "configure") | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
141 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
142 | ``enable`` | List of features to enable, separated by spaces. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
143 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
144 | ``disable`` | List of features to disable, separated by spaces. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
145 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
146 | ``with`` | List of packages to include, separated by spaces. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
147 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
148 | ``without`` | List of packages to exclude, separated by spaces. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
149 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
150 | ``cflags`` | Value of the `CFLAGS` variable to pass to the script. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
151 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
152 | ``cxxflags`` | Value of the `CXXFLAGS` variable to pass to the script. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
153 +--------------+-------------------------------------------------------------+ |
412 | 154 |
155 Examples | |
156 -------- | |
157 | |
158 .. code-block:: xml | |
159 | |
160 <c:configure enable="threadsafe" cflags="O"/> | |
161 | |
162 Runs the `configure` script in the base directory, enable the `threadsafe` | |
163 feature, and passing `-O` as `CFLAGS`. This is equivalent to:: | |
164 | |
165 ./configure --enable-threadsafe CFLAGS="-O" | |
166 | |
167 | |
168 ------------ | |
169 ``<c:make>`` | |
170 ------------ | |
171 | |
172 Executes a Makefile. | |
173 | |
174 Parameters | |
175 ---------- | |
176 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
177 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
178 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
179 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
180 | ``target`` | Name of the target to execute (defaults to "all") | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
181 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
182 | ``file`` | Path to the Makefile that should be used. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
183 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
184 | ``keep-going`` | Whether `make` should try to continue even after | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
185 | | encountering errors. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
186 +----------------+-----------------------------------------------------------+ |
412 | 187 |
188 Examples | |
189 -------- | |
190 | |
191 .. code-block:: xml | |
192 | |
193 <c:make target="compile" file="build/Makefile" /> | |
194 | |
195 Runs the target "compile" of the ``Makefile`` located in the sub-directory | |
196 ``build``. | |
197 | |
198 | |
199 --------------- | |
200 ``<c:cppunit>`` | |
201 --------------- | |
202 | |
203 Report the test output generated by the CppUnit_ unit testing framework. The | |
204 output from CppUnit must be in XML format and in already, specified by the | |
205 ``file`` argument of this recipe. | |
206 | |
207 .. _cppunit: http://cppunit.sourceforge.net | |
208 | |
209 Parameters | |
210 ---------- | |
211 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
212 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
213 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
214 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
215 | ``file`` | Path to the cppunit XML output file. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
216 +----------------+-----------------------------------------------------------+ |
412 | 217 |
218 Examples | |
219 -------- | |
220 | |
221 .. code-block:: xml | |
222 | |
223 <sh:exec executable="run_unit_tests" output="test_results.xml" /> | |
224 <c:cppunit file="test_results.xml" /> | |
225 | |
226 Runs the program ``run_unit_tests`` to gather the data output by CppUnit in the | |
227 ``test_results.xml`` file and then reports it. | |
228 | |
229 | |
230 Java Tools | |
231 ========== | |
232 | |
233 A bundle of recipe commands that support tools commonly used by Java projects. | |
234 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
235 :Namespace: ``http://bitten.cmlenz.net/tools/java`` |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
236 :Common prefix: ``java`` |
412 | 237 |
238 | |
239 -------------- | |
240 ``<java:ant>`` | |
241 -------------- | |
242 | |
243 Runs an Ant_ build. | |
244 | |
245 .. _ant: http://ant.apache.org/ | |
246 | |
247 Parameters | |
248 ---------- | |
249 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
250 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
251 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
252 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
253 | ``file`` | Path of the build file, relative to the project source | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
254 | | directory (default is ``build.xml``). | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
255 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
256 | ``target`` | Name of the build target(s) to execute. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
257 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
258 | ``args`` | Additional arguments to pass to Ant, separated by | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
259 | | whitespace. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
260 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
261 | ``keep_going`` | Tell Ant to continue even when errors are in encountered | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
262 | | in the build. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
263 +----------------+-----------------------------------------------------------+ |
412 | 264 |
265 Examples | |
266 -------- | |
267 | |
268 .. code-block:: xml | |
269 | |
270 <java:ant target="compile" /> | |
271 | |
272 Executes the target `compile` of the `build.xml` buildfile at the top of the | |
273 project source directory. | |
274 | |
275 | |
276 ---------------- | |
277 ``<java:junit>`` | |
278 ---------------- | |
279 | |
280 Extracts information about unit test results from a file in JUnit_ XML format. | |
281 | |
282 .. _junit: http://junit.org/index.htm | |
283 | |
284 Parameters | |
285 ---------- | |
286 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
287 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
288 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
289 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
290 | ``file`` | Path to the JUnit XML test results file. This can include | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
291 | | wildcards, in which case all the file matching the | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
292 | | pattern will be included. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
293 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
294 | ``srcdir`` | Path of the directory unit test sources. Used to link the | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
295 | | test cases to files. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
296 +----------------+-----------------------------------------------------------+ |
412 | 297 |
298 The ``file`` attribute is required. | |
299 | |
300 Examples | |
301 -------- | |
302 | |
303 .. code-block:: xml | |
304 | |
305 <java:junit file="build/tests/results/TEST-*.xml" srcdir="src/tests" /> | |
306 | |
307 Collects the test results from all files in the `build/tests/results` directory | |
308 that match the pattern `TEST-*.xml`. Also, maps the class names in the results | |
309 files to Java source files in the directory `src/tests`. | |
310 | |
311 | |
312 Python Tools | |
313 ============ | |
314 | |
315 A bundle of recipe commands that support tools commonly used by Python_ | |
316 projects. | |
317 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
318 :Namespace: ``http://bitten.cmlenz.net/tools/python`` |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
319 :Common prefix: ``python`` |
412 | 320 |
321 .. _python: http://www.python.org/ | |
322 | |
323 | |
324 ----------------- | |
325 ``<python:exec>`` | |
326 ----------------- | |
327 | |
328 Executes a Python script. | |
329 | |
330 Parameters | |
331 ---------- | |
332 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
333 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
334 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
335 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
336 | ``file`` | Path of the script to execute, relative to the project | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
337 | | source directory. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
338 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
339 | ``module`` | Name of the Python module to execute. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
340 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
341 | ``function`` | Name of the function in the Python module to run. Only | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
342 | | works when also specifying the `module` attribute. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
343 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
344 | ``args`` | Any arguments that should be passed to the script. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
345 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
346 | ``output`` | Path to a file where any output by the script should be | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
347 | | recorded. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
348 +----------------+-----------------------------------------------------------+ |
412 | 349 |
350 Either `file` or `module` must be specified. | |
351 | |
352 Examples | |
353 -------- | |
354 | |
355 .. code-block:: xml | |
356 | |
357 <python:exec module="pylint.lint" output="pylint-report.txt" args="myproj" /> | |
358 | |
359 Executes Pylint_ on the module/package ``myproj`` and stores the output into a | |
360 file named ``pylint-report.txt``. | |
361 | |
362 | |
363 ---------------------- | |
364 ``<python:distutils>`` | |
365 ---------------------- | |
366 | |
367 Executes a distutils_ script. | |
368 | |
369 .. _distutils: http://docs.python.org/lib/module-distutils.html | |
370 | |
371 Parameters | |
372 ---------- | |
373 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
374 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
375 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
376 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
377 | `command` | The name of the `distutils` command that should be run | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
378 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
379 | `options` | Additional options to pass to the command, separated by | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
380 | | spaces | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
381 +----------------+-----------------------------------------------------------+ |
412 | 382 |
383 Examples | |
384 -------- | |
385 | |
386 .. code-block:: xml | |
387 | |
388 <python:distutils command="sdist" /> | |
389 | |
390 Instructs `distutils` to produce a source distribution. | |
391 | |
392 | |
393 --------------------- | |
394 ``<python:unittest>`` | |
395 --------------------- | |
396 | |
397 Extracts information from unittest_ results recorded in an XML file. | |
398 | |
399 .. _unittest: http://docs.python.org/lib/module-unittest.html | |
400 .. note:: This report must be used in conjunction with the ``distutils`` command | |
401 "unittest" that comes with Bitten. | |
402 | |
403 Parameters | |
404 ---------- | |
405 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
406 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
407 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
408 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
409 | ``file`` | Path to the XML results file, relative to the project | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
410 | | source directory. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
411 +----------------+-----------------------------------------------------------+ |
412 | 412 |
413 Examples | |
414 -------- | |
415 | |
416 .. code-block:: xml | |
417 | |
418 <python:unittest file="build/test-results.xml"/> | |
419 | |
420 Extracts the test results from the XML file located at | |
421 ``build/test-results.xml``. | |
422 | |
423 | |
424 ------------------ | |
425 ``<python:trace>`` | |
426 ------------------ | |
427 | |
428 Extracts coverage information recorded by the built-in Python module | |
429 ``trace.py``. | |
430 | |
431 Parameters | |
432 ---------- | |
433 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
434 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
435 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
436 +==============+=============================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
437 | ``summary`` | Path to the summary file written by ``trace.py``, | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
438 | | relative to the project source directory. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
439 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
440 | ``coverdir`` | Path to the directory containing the coverage files written | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
441 | | by ``trace.py``, relative to the project source directory. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
442 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
443 | ``include`` | List of glob patterns (separated by space) that specify | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
444 | | which Python file should be included in the coverage report | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
445 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
446 | ``exclude`` | List of glob patterns (separated by space) that specify | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
447 | | which Python file should be excluded from the coverage | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
448 | | report | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
449 +--------------+-------------------------------------------------------------+ |
412 | 450 |
451 Examples | |
452 -------- | |
453 | |
454 .. code-block:: xml | |
455 | |
456 <python:trace summary="build/trace.out" coverdir="build/coverage" /> | |
457 | |
458 ------------------- | |
459 ``<python:pylint>`` | |
460 ------------------- | |
461 | |
462 Extracts information from Pylint_ reports. | |
463 | |
464 .. _pylint: http://www.logilab.org/projects/pylint | |
465 | |
466 Parameters | |
467 ---------- | |
468 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
469 +--------------+-------------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
470 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
471 +==============+=============================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
472 | ``file`` | Path to the file containing the Pylint output, relative to | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
473 | | the project source directory. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
474 +--------------+-------------------------------------------------------------+ |
412 | 475 |
476 Examples | |
477 -------- | |
478 | |
479 .. code-block:: xml | |
480 | |
481 <python:pylint file="build/pylint.out" /> | |
482 | |
483 | |
484 XML Tools | |
485 ========= | |
486 | |
487 A collection of recipe commands for XML processing. | |
488 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
489 :Namespace: ``http://bitten.cmlenz.net/tools/xml`` |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
490 :Common prefix: ``x`` |
412 | 491 |
492 | |
493 ----------------- | |
494 ``<x:transform>`` | |
495 ----------------- | |
496 | |
497 Apply an XSLT stylesheet . | |
498 | |
499 .. note:: that this command requires either libxslt_ (with `Python bindings`_) | |
500 or, on Windows platforms, MSXML (version 3 or later) to be installed | |
501 on the slave machine. | |
502 | |
503 .. _libxslt: http://xmlsoft.org/XSLT/ | |
504 .. _`python bindings`: http://xmlsoft.org/XSLT/python.html | |
505 | |
506 Parameters | |
507 ---------- | |
508 | |
413
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
509 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
510 | Name | Description | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
511 +================+===========================================================+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
512 | ``src`` | Path of the source XML file. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
513 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
514 | ``dest`` | Path of the destition XML file. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
515 +----------------+-----------------------------------------------------------+ |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
516 | ``stylesheet`` | Path to the XSLT stylesheet file. | |
fa72698e7477
Don't put tables in blockquotes in command reference.
cmlenz
parents:
412
diff
changeset
|
517 +----------------+-----------------------------------------------------------+ |
412 | 518 |
519 All these are interpreted relative to the project source directory. | |
520 | |
521 Examples | |
522 -------- | |
523 | |
524 .. code-block:: xml | |
525 | |
526 <x:transform src="src.xml" dest="dest.xml" stylesheet="util/convert.xsl" /> | |
527 | |
528 This applies the stylesheet in ``util/convert.xsl`` to the source file | |
529 ``src.xml``, and writes the resulting XML document to ``dest.xml``. |