Merge lp://staging/~al-maisan/py-script/doc-500616 into lp://staging/py-script
- doc-500616
- Merge into trunk
Proposed by
Muharem Hrnjadovic
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Muharem Hrnjadovic | ||||
Approved revision: | not available | ||||
Merged at revision: | not available | ||||
Proposed branch: | lp://staging/~al-maisan/py-script/doc-500616 | ||||
Merge into: | lp://staging/py-script | ||||
Diff against target: |
5792 lines (+1135/-2589) 21 files modified
doc/html/api-objects.txt (+0/-6) doc/html/class-tree.html (+0/-132) doc/html/epydoc.css (+0/-312) doc/html/epydoc.js (+0/-280) doc/html/frames.html (+0/-17) doc/html/help.html (+0/-278) doc/html/identifier-index.html (+0/-181) doc/html/index.html (+0/-17) doc/html/module-tree.html (+0/-115) doc/html/redirect.html (+0/-38) doc/html/scriptutil-module.html (+0/-509) doc/html/scriptutil-pysrc.html (+0/-388) doc/html/scriptutil.ScriptError-class.html (+0/-197) doc/html/scriptutil.find-module.html (+494/-0) doc/html/scriptutil.find-pysrc.html (+390/-0) doc/html/scriptutil.find.ScriptError-class.html (+202/-0) doc/html/toc-everything.html (+0/-37) doc/html/toc-scriptutil-module.html (+0/-37) doc/html/toc-scriptutil.find-module.html (+38/-0) doc/html/toc.html (+0/-34) src/scriptutil/find.py (+11/-11) |
||||
To merge this branch: | bzr merge lp://staging/~al-maisan/py-script/doc-500616 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Muharem Hrnjadovic | Approve | ||
Review via email: mp+16602@code.staging.launchpad.net |
Commit message
HTML doc re-generated.
Description of the change
To post a comment you must log in.
Revision history for this message
Muharem Hrnjadovic (al-maisan) wrote : | # |
Revision history for this message
Muharem Hrnjadovic (al-maisan) wrote : | # |
Looks good!
review:
Approve
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === added directory 'doc/html' | |||
2 | === removed directory 'doc/html' | |||
3 | === added file 'doc/html/api-objects.txt' | |||
4 | --- doc/html/api-objects.txt 1970-01-01 00:00:00 +0000 | |||
5 | +++ doc/html/api-objects.txt 2009-12-26 22:06:14 +0000 | |||
6 | @@ -0,0 +1,9 @@ | |||
7 | 1 | scriptutil scriptutil-module.html | ||
8 | 2 | scriptutil.__package__ scriptutil-module.html#__package__ | ||
9 | 3 | scriptutil.find scriptutil.find-module.html | ||
10 | 4 | scriptutil.find.grep scriptutil.find-module.html#grep | ||
11 | 5 | scriptutil.find.pprint scriptutil.find-module.html#pprint | ||
12 | 6 | scriptutil.find.__package__ scriptutil.find-module.html#__package__ | ||
13 | 7 | scriptutil.find.replace scriptutil.find-module.html#replace | ||
14 | 8 | scriptutil.find.find scriptutil.find-module.html#find | ||
15 | 9 | scriptutil.find.ScriptError scriptutil.find.ScriptError-class.html | ||
16 | 0 | 10 | ||
17 | === removed file 'doc/html/api-objects.txt' | |||
18 | --- doc/html/api-objects.txt 2009-12-26 20:49:38 +0000 | |||
19 | +++ doc/html/api-objects.txt 1970-01-01 00:00:00 +0000 | |||
20 | @@ -1,6 +0,0 @@ | |||
21 | 1 | scriptutil scriptutil-module.html | ||
22 | 2 | scriptutil.printr scriptutil-module.html#printr | ||
23 | 3 | scriptutil.freplace scriptutil-module.html#freplace | ||
24 | 4 | scriptutil.ffind scriptutil-module.html#ffind | ||
25 | 5 | scriptutil.ffindgrep scriptutil-module.html#ffindgrep | ||
26 | 6 | scriptutil.ScriptError scriptutil.ScriptError-class.html | ||
27 | 7 | 0 | ||
28 | === added file 'doc/html/class-tree.html' | |||
29 | --- doc/html/class-tree.html 1970-01-01 00:00:00 +0000 | |||
30 | +++ doc/html/class-tree.html 2009-12-26 22:06:14 +0000 | |||
31 | @@ -0,0 +1,132 @@ | |||
32 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
33 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
34 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
35 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
36 | 5 | <head> | ||
37 | 6 | <title>Class Hierarchy</title> | ||
38 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
39 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
40 | 9 | </head> | ||
41 | 10 | |||
42 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
43 | 12 | alink="#204080"> | ||
44 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
45 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
46 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
47 | 16 | <tr valign="middle"> | ||
48 | 17 | <!-- Home link --> | ||
49 | 18 | <th> <a | ||
50 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
51 | 20 | |||
52 | 21 | <!-- Tree link --> | ||
53 | 22 | <th bgcolor="#70b0f0" class="navbar-select" | ||
54 | 23 | > Trees </th> | ||
55 | 24 | |||
56 | 25 | <!-- Index link --> | ||
57 | 26 | <th> <a | ||
58 | 27 | href="identifier-index.html">Indices</a> </th> | ||
59 | 28 | |||
60 | 29 | <!-- Help link --> | ||
61 | 30 | <th> <a | ||
62 | 31 | href="help.html">Help</a> </th> | ||
63 | 32 | |||
64 | 33 | <!-- Project homepage --> | ||
65 | 34 | <th class="navbar" align="right" width="100%"> | ||
66 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
67 | 36 | <tr><th class="navbar" align="center" | ||
68 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
69 | 38 | </tr></table></th> | ||
70 | 39 | </tr> | ||
71 | 40 | </table> | ||
72 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
73 | 42 | <tr valign="top"> | ||
74 | 43 | <td width="100%"> </td> | ||
75 | 44 | <td> | ||
76 | 45 | <table cellpadding="0" cellspacing="0"> | ||
77 | 46 | <!-- hide/show private --> | ||
78 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
79 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
80 | 49 | <tr><td align="right"><span class="options" | ||
81 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
82 | 51 | >] | <a href="class-tree.html" | ||
83 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
84 | 53 | </table> | ||
85 | 54 | </td> | ||
86 | 55 | </tr> | ||
87 | 56 | </table> | ||
88 | 57 | <center><b> | ||
89 | 58 | [ <a href="module-tree.html">Module Hierarchy</a> | ||
90 | 59 | | <a href="class-tree.html">Class Hierarchy</a> ] | ||
91 | 60 | </b></center><br /> | ||
92 | 61 | <h1 class="epydoc">Class Hierarchy</h1> | ||
93 | 62 | <ul class="nomargin-top"> | ||
94 | 63 | <li> <strong class="uidlink">object</strong>: | ||
95 | 64 | <em class="summary">The most base type</em> | ||
96 | 65 | <ul> | ||
97 | 66 | <li> <strong class="uidlink">exceptions.BaseException</strong>: | ||
98 | 67 | <em class="summary">Common base class for all exceptions</em> | ||
99 | 68 | <ul> | ||
100 | 69 | <li> <strong class="uidlink">exceptions.Exception</strong>: | ||
101 | 70 | <em class="summary">Common base class for all non-exit exceptions.</em> | ||
102 | 71 | <ul> | ||
103 | 72 | <li> <strong class="uidlink"><a href="scriptutil.find.ScriptError-class.html">scriptutil.find.ScriptError</a></strong>: | ||
104 | 73 | <em class="summary">The exception raised in case of failures.</em> | ||
105 | 74 | </li> | ||
106 | 75 | </ul> | ||
107 | 76 | </li> | ||
108 | 77 | </ul> | ||
109 | 78 | </li> | ||
110 | 79 | </ul> | ||
111 | 80 | </li> | ||
112 | 81 | </ul> | ||
113 | 82 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
114 | 83 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
115 | 84 | bgcolor="#a0c0ff" cellspacing="0"> | ||
116 | 85 | <tr valign="middle"> | ||
117 | 86 | <!-- Home link --> | ||
118 | 87 | <th> <a | ||
119 | 88 | href="scriptutil-module.html">Home</a> </th> | ||
120 | 89 | |||
121 | 90 | <!-- Tree link --> | ||
122 | 91 | <th bgcolor="#70b0f0" class="navbar-select" | ||
123 | 92 | > Trees </th> | ||
124 | 93 | |||
125 | 94 | <!-- Index link --> | ||
126 | 95 | <th> <a | ||
127 | 96 | href="identifier-index.html">Indices</a> </th> | ||
128 | 97 | |||
129 | 98 | <!-- Help link --> | ||
130 | 99 | <th> <a | ||
131 | 100 | href="help.html">Help</a> </th> | ||
132 | 101 | |||
133 | 102 | <!-- Project homepage --> | ||
134 | 103 | <th class="navbar" align="right" width="100%"> | ||
135 | 104 | <table border="0" cellpadding="0" cellspacing="0"> | ||
136 | 105 | <tr><th class="navbar" align="center" | ||
137 | 106 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
138 | 107 | </tr></table></th> | ||
139 | 108 | </tr> | ||
140 | 109 | </table> | ||
141 | 110 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
142 | 111 | <tr> | ||
143 | 112 | <td align="left" class="footer"> | ||
144 | 113 | Generated by Epydoc 3.0.1 on Sat Dec 26 23:01:34 2009 | ||
145 | 114 | </td> | ||
146 | 115 | <td align="right" class="footer"> | ||
147 | 116 | <a target="mainFrame" href="http://epydoc.sourceforge.net" | ||
148 | 117 | >http://epydoc.sourceforge.net</a> | ||
149 | 118 | </td> | ||
150 | 119 | </tr> | ||
151 | 120 | </table> | ||
152 | 121 | |||
153 | 122 | <script type="text/javascript"> | ||
154 | 123 | <!-- | ||
155 | 124 | // Private objects are initially displayed (because if | ||
156 | 125 | // javascript is turned off then we want them to be | ||
157 | 126 | // visible); but by default, we want to hide them. So hide | ||
158 | 127 | // them unless we have a cookie that says to show them. | ||
159 | 128 | checkCookie(); | ||
160 | 129 | // --> | ||
161 | 130 | </script> | ||
162 | 131 | </body> | ||
163 | 132 | </html> | ||
164 | 0 | 133 | ||
165 | === removed file 'doc/html/class-tree.html' | |||
166 | --- doc/html/class-tree.html 2009-12-26 20:49:38 +0000 | |||
167 | +++ doc/html/class-tree.html 1970-01-01 00:00:00 +0000 | |||
168 | @@ -1,132 +0,0 @@ | |||
169 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
170 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
171 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
172 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
173 | 5 | <head> | ||
174 | 6 | <title>Class Hierarchy</title> | ||
175 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
176 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
177 | 9 | </head> | ||
178 | 10 | |||
179 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
180 | 12 | alink="#204080"> | ||
181 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
182 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
183 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
184 | 16 | <tr valign="middle"> | ||
185 | 17 | <!-- Home link --> | ||
186 | 18 | <th> <a | ||
187 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
188 | 20 | |||
189 | 21 | <!-- Tree link --> | ||
190 | 22 | <th bgcolor="#70b0f0" class="navbar-select" | ||
191 | 23 | > Trees </th> | ||
192 | 24 | |||
193 | 25 | <!-- Index link --> | ||
194 | 26 | <th> <a | ||
195 | 27 | href="identifier-index.html">Indices</a> </th> | ||
196 | 28 | |||
197 | 29 | <!-- Help link --> | ||
198 | 30 | <th> <a | ||
199 | 31 | href="help.html">Help</a> </th> | ||
200 | 32 | |||
201 | 33 | <!-- Project homepage --> | ||
202 | 34 | <th class="navbar" align="right" width="100%"> | ||
203 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
204 | 36 | <tr><th class="navbar" align="center" | ||
205 | 37 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
206 | 38 | </tr></table></th> | ||
207 | 39 | </tr> | ||
208 | 40 | </table> | ||
209 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
210 | 42 | <tr valign="top"> | ||
211 | 43 | <td width="100%"> </td> | ||
212 | 44 | <td> | ||
213 | 45 | <table cellpadding="0" cellspacing="0"> | ||
214 | 46 | <!-- hide/show private --> | ||
215 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
216 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
217 | 49 | <tr><td align="right"><span class="options" | ||
218 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
219 | 51 | >] | <a href="class-tree.html" | ||
220 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
221 | 53 | </table> | ||
222 | 54 | </td> | ||
223 | 55 | </tr> | ||
224 | 56 | </table> | ||
225 | 57 | <center><b> | ||
226 | 58 | [ <a href="module-tree.html">Module Hierarchy</a> | ||
227 | 59 | | <a href="class-tree.html">Class Hierarchy</a> ] | ||
228 | 60 | </b></center><br /> | ||
229 | 61 | <h1 class="epydoc">Class Hierarchy</h1> | ||
230 | 62 | <ul class="nomargin-top"> | ||
231 | 63 | <li> <strong class="uidlink">object</strong>: | ||
232 | 64 | <em class="summary">The most base type</em> | ||
233 | 65 | <ul> | ||
234 | 66 | <li> <strong class="uidlink">exceptions.BaseException</strong>: | ||
235 | 67 | <em class="summary">Common base class for all exceptions</em> | ||
236 | 68 | <ul> | ||
237 | 69 | <li> <strong class="uidlink">exceptions.Exception</strong>: | ||
238 | 70 | <em class="summary">Common base class for all non-exit exceptions.</em> | ||
239 | 71 | <ul> | ||
240 | 72 | <li> <strong class="uidlink"><a href="scriptutil.ScriptError-class.html">scriptutil.ScriptError</a></strong>: | ||
241 | 73 | <em class="summary">The exception raised in case of failures.</em> | ||
242 | 74 | </li> | ||
243 | 75 | </ul> | ||
244 | 76 | </li> | ||
245 | 77 | </ul> | ||
246 | 78 | </li> | ||
247 | 79 | </ul> | ||
248 | 80 | </li> | ||
249 | 81 | </ul> | ||
250 | 82 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
251 | 83 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
252 | 84 | bgcolor="#a0c0ff" cellspacing="0"> | ||
253 | 85 | <tr valign="middle"> | ||
254 | 86 | <!-- Home link --> | ||
255 | 87 | <th> <a | ||
256 | 88 | href="scriptutil-module.html">Home</a> </th> | ||
257 | 89 | |||
258 | 90 | <!-- Tree link --> | ||
259 | 91 | <th bgcolor="#70b0f0" class="navbar-select" | ||
260 | 92 | > Trees </th> | ||
261 | 93 | |||
262 | 94 | <!-- Index link --> | ||
263 | 95 | <th> <a | ||
264 | 96 | href="identifier-index.html">Indices</a> </th> | ||
265 | 97 | |||
266 | 98 | <!-- Help link --> | ||
267 | 99 | <th> <a | ||
268 | 100 | href="help.html">Help</a> </th> | ||
269 | 101 | |||
270 | 102 | <!-- Project homepage --> | ||
271 | 103 | <th class="navbar" align="right" width="100%"> | ||
272 | 104 | <table border="0" cellpadding="0" cellspacing="0"> | ||
273 | 105 | <tr><th class="navbar" align="center" | ||
274 | 106 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
275 | 107 | </tr></table></th> | ||
276 | 108 | </tr> | ||
277 | 109 | </table> | ||
278 | 110 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
279 | 111 | <tr> | ||
280 | 112 | <td align="left" class="footer"> | ||
281 | 113 | Generated by Epydoc 3.0beta1 on Thu May 22 18:10:51 2008 | ||
282 | 114 | </td> | ||
283 | 115 | <td align="right" class="footer"> | ||
284 | 116 | <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a> | ||
285 | 117 | </td> | ||
286 | 118 | </tr> | ||
287 | 119 | </table> | ||
288 | 120 | |||
289 | 121 | <script type="text/javascript"> | ||
290 | 122 | <!-- | ||
291 | 123 | // Private objects are initially displayed (because if | ||
292 | 124 | // javascript is turned off then we want them to be | ||
293 | 125 | // visible); but by default, we want to hide them. So hide | ||
294 | 126 | // them unless we have a cookie that says to show them. | ||
295 | 127 | checkCookie() | ||
296 | 128 | // --> | ||
297 | 129 | </script> | ||
298 | 130 | |||
299 | 131 | </body> | ||
300 | 132 | </html> | ||
301 | 133 | 0 | ||
302 | === added file 'doc/html/crarr.png' | |||
303 | 134 | Binary files doc/html/crarr.png 1970-01-01 00:00:00 +0000 and doc/html/crarr.png 2009-12-26 22:06:14 +0000 differ | 1 | Binary files doc/html/crarr.png 1970-01-01 00:00:00 +0000 and doc/html/crarr.png 2009-12-26 22:06:14 +0000 differ |
304 | === removed file 'doc/html/crarr.png' | |||
305 | 135 | Binary files doc/html/crarr.png 2009-12-26 20:49:38 +0000 and doc/html/crarr.png 1970-01-01 00:00:00 +0000 differ | 2 | Binary files doc/html/crarr.png 2009-12-26 20:49:38 +0000 and doc/html/crarr.png 1970-01-01 00:00:00 +0000 differ |
306 | === added file 'doc/html/epydoc.css' | |||
307 | --- doc/html/epydoc.css 1970-01-01 00:00:00 +0000 | |||
308 | +++ doc/html/epydoc.css 2009-12-26 22:06:14 +0000 | |||
309 | @@ -0,0 +1,322 @@ | |||
310 | 1 | |||
311 | 2 | |||
312 | 3 | /* Epydoc CSS Stylesheet | ||
313 | 4 | * | ||
314 | 5 | * This stylesheet can be used to customize the appearance of epydoc's | ||
315 | 6 | * HTML output. | ||
316 | 7 | * | ||
317 | 8 | */ | ||
318 | 9 | |||
319 | 10 | /* Default Colors & Styles | ||
320 | 11 | * - Set the default foreground & background color with 'body'; and | ||
321 | 12 | * link colors with 'a:link' and 'a:visited'. | ||
322 | 13 | * - Use bold for decision list terms. | ||
323 | 14 | * - The heading styles defined here are used for headings *within* | ||
324 | 15 | * docstring descriptions. All headings used by epydoc itself use | ||
325 | 16 | * either class='epydoc' or class='toc' (CSS styles for both | ||
326 | 17 | * defined below). | ||
327 | 18 | */ | ||
328 | 19 | body { background: #ffffff; color: #000000; } | ||
329 | 20 | p { margin-top: 0.5em; margin-bottom: 0.5em; } | ||
330 | 21 | a:link { color: #0000ff; } | ||
331 | 22 | a:visited { color: #204080; } | ||
332 | 23 | dt { font-weight: bold; } | ||
333 | 24 | h1 { font-size: +140%; font-style: italic; | ||
334 | 25 | font-weight: bold; } | ||
335 | 26 | h2 { font-size: +125%; font-style: italic; | ||
336 | 27 | font-weight: bold; } | ||
337 | 28 | h3 { font-size: +110%; font-style: italic; | ||
338 | 29 | font-weight: normal; } | ||
339 | 30 | code { font-size: 100%; } | ||
340 | 31 | /* N.B.: class, not pseudoclass */ | ||
341 | 32 | a.link { font-family: monospace; } | ||
342 | 33 | |||
343 | 34 | /* Page Header & Footer | ||
344 | 35 | * - The standard page header consists of a navigation bar (with | ||
345 | 36 | * pointers to standard pages such as 'home' and 'trees'); a | ||
346 | 37 | * breadcrumbs list, which can be used to navigate to containing | ||
347 | 38 | * classes or modules; options links, to show/hide private | ||
348 | 39 | * variables and to show/hide frames; and a page title (using | ||
349 | 40 | * <h1>). The page title may be followed by a link to the | ||
350 | 41 | * corresponding source code (using 'span.codelink'). | ||
351 | 42 | * - The footer consists of a navigation bar, a timestamp, and a | ||
352 | 43 | * pointer to epydoc's homepage. | ||
353 | 44 | */ | ||
354 | 45 | h1.epydoc { margin: 0; font-size: +140%; font-weight: bold; } | ||
355 | 46 | h2.epydoc { font-size: +130%; font-weight: bold; } | ||
356 | 47 | h3.epydoc { font-size: +115%; font-weight: bold; | ||
357 | 48 | margin-top: 0.2em; } | ||
358 | 49 | td h3.epydoc { font-size: +115%; font-weight: bold; | ||
359 | 50 | margin-bottom: 0; } | ||
360 | 51 | table.navbar { background: #a0c0ff; color: #000000; | ||
361 | 52 | border: 2px groove #c0d0d0; } | ||
362 | 53 | table.navbar table { color: #000000; } | ||
363 | 54 | th.navbar-select { background: #70b0ff; | ||
364 | 55 | color: #000000; } | ||
365 | 56 | table.navbar a { text-decoration: none; } | ||
366 | 57 | table.navbar a:link { color: #0000ff; } | ||
367 | 58 | table.navbar a:visited { color: #204080; } | ||
368 | 59 | span.breadcrumbs { font-size: 85%; font-weight: bold; } | ||
369 | 60 | span.options { font-size: 70%; } | ||
370 | 61 | span.codelink { font-size: 85%; } | ||
371 | 62 | td.footer { font-size: 85%; } | ||
372 | 63 | |||
373 | 64 | /* Table Headers | ||
374 | 65 | * - Each summary table and details section begins with a 'header' | ||
375 | 66 | * row. This row contains a section title (marked by | ||
376 | 67 | * 'span.table-header') as well as a show/hide private link | ||
377 | 68 | * (marked by 'span.options', defined above). | ||
378 | 69 | * - Summary tables that contain user-defined groups mark those | ||
379 | 70 | * groups using 'group header' rows. | ||
380 | 71 | */ | ||
381 | 72 | td.table-header { background: #70b0ff; color: #000000; | ||
382 | 73 | border: 1px solid #608090; } | ||
383 | 74 | td.table-header table { color: #000000; } | ||
384 | 75 | td.table-header table a:link { color: #0000ff; } | ||
385 | 76 | td.table-header table a:visited { color: #204080; } | ||
386 | 77 | span.table-header { font-size: 120%; font-weight: bold; } | ||
387 | 78 | th.group-header { background: #c0e0f8; color: #000000; | ||
388 | 79 | text-align: left; font-style: italic; | ||
389 | 80 | font-size: 115%; | ||
390 | 81 | border: 1px solid #608090; } | ||
391 | 82 | |||
392 | 83 | /* Summary Tables (functions, variables, etc) | ||
393 | 84 | * - Each object is described by a single row of the table with | ||
394 | 85 | * two cells. The left cell gives the object's type, and is | ||
395 | 86 | * marked with 'code.summary-type'. The right cell gives the | ||
396 | 87 | * object's name and a summary description. | ||
397 | 88 | * - CSS styles for the table's header and group headers are | ||
398 | 89 | * defined above, under 'Table Headers' | ||
399 | 90 | */ | ||
400 | 91 | table.summary { border-collapse: collapse; | ||
401 | 92 | background: #e8f0f8; color: #000000; | ||
402 | 93 | border: 1px solid #608090; | ||
403 | 94 | margin-bottom: 0.5em; } | ||
404 | 95 | td.summary { border: 1px solid #608090; } | ||
405 | 96 | code.summary-type { font-size: 85%; } | ||
406 | 97 | table.summary a:link { color: #0000ff; } | ||
407 | 98 | table.summary a:visited { color: #204080; } | ||
408 | 99 | |||
409 | 100 | |||
410 | 101 | /* Details Tables (functions, variables, etc) | ||
411 | 102 | * - Each object is described in its own div. | ||
412 | 103 | * - A single-row summary table w/ table-header is used as | ||
413 | 104 | * a header for each details section (CSS style for table-header | ||
414 | 105 | * is defined above, under 'Table Headers'). | ||
415 | 106 | */ | ||
416 | 107 | table.details { border-collapse: collapse; | ||
417 | 108 | background: #e8f0f8; color: #000000; | ||
418 | 109 | border: 1px solid #608090; | ||
419 | 110 | margin: .2em 0 0 0; } | ||
420 | 111 | table.details table { color: #000000; } | ||
421 | 112 | table.details a:link { color: #0000ff; } | ||
422 | 113 | table.details a:visited { color: #204080; } | ||
423 | 114 | |||
424 | 115 | /* Fields */ | ||
425 | 116 | dl.fields { margin-left: 2em; margin-top: 1em; | ||
426 | 117 | margin-bottom: 1em; } | ||
427 | 118 | dl.fields dd ul { margin-left: 0em; padding-left: 0em; } | ||
428 | 119 | dl.fields dd ul li ul { margin-left: 2em; padding-left: 0em; } | ||
429 | 120 | div.fields { margin-left: 2em; } | ||
430 | 121 | div.fields p { margin-bottom: 0.5em; } | ||
431 | 122 | |||
432 | 123 | /* Index tables (identifier index, term index, etc) | ||
433 | 124 | * - link-index is used for indices containing lists of links | ||
434 | 125 | * (namely, the identifier index & term index). | ||
435 | 126 | * - index-where is used in link indices for the text indicating | ||
436 | 127 | * the container/source for each link. | ||
437 | 128 | * - metadata-index is used for indices containing metadata | ||
438 | 129 | * extracted from fields (namely, the bug index & todo index). | ||
439 | 130 | */ | ||
440 | 131 | table.link-index { border-collapse: collapse; | ||
441 | 132 | background: #e8f0f8; color: #000000; | ||
442 | 133 | border: 1px solid #608090; } | ||
443 | 134 | td.link-index { border-width: 0px; } | ||
444 | 135 | table.link-index a:link { color: #0000ff; } | ||
445 | 136 | table.link-index a:visited { color: #204080; } | ||
446 | 137 | span.index-where { font-size: 70%; } | ||
447 | 138 | table.metadata-index { border-collapse: collapse; | ||
448 | 139 | background: #e8f0f8; color: #000000; | ||
449 | 140 | border: 1px solid #608090; | ||
450 | 141 | margin: .2em 0 0 0; } | ||
451 | 142 | td.metadata-index { border-width: 1px; border-style: solid; } | ||
452 | 143 | table.metadata-index a:link { color: #0000ff; } | ||
453 | 144 | table.metadata-index a:visited { color: #204080; } | ||
454 | 145 | |||
455 | 146 | /* Function signatures | ||
456 | 147 | * - sig* is used for the signature in the details section. | ||
457 | 148 | * - .summary-sig* is used for the signature in the summary | ||
458 | 149 | * table, and when listing property accessor functions. | ||
459 | 150 | * */ | ||
460 | 151 | .sig-name { color: #006080; } | ||
461 | 152 | .sig-arg { color: #008060; } | ||
462 | 153 | .sig-default { color: #602000; } | ||
463 | 154 | .summary-sig { font-family: monospace; } | ||
464 | 155 | .summary-sig-name { color: #006080; font-weight: bold; } | ||
465 | 156 | table.summary a.summary-sig-name:link | ||
466 | 157 | { color: #006080; font-weight: bold; } | ||
467 | 158 | table.summary a.summary-sig-name:visited | ||
468 | 159 | { color: #006080; font-weight: bold; } | ||
469 | 160 | .summary-sig-arg { color: #006040; } | ||
470 | 161 | .summary-sig-default { color: #501800; } | ||
471 | 162 | |||
472 | 163 | /* Subclass list | ||
473 | 164 | */ | ||
474 | 165 | ul.subclass-list { display: inline; } | ||
475 | 166 | ul.subclass-list li { display: inline; } | ||
476 | 167 | |||
477 | 168 | /* To render variables, classes etc. like functions */ | ||
478 | 169 | table.summary .summary-name { color: #006080; font-weight: bold; | ||
479 | 170 | font-family: monospace; } | ||
480 | 171 | table.summary | ||
481 | 172 | a.summary-name:link { color: #006080; font-weight: bold; | ||
482 | 173 | font-family: monospace; } | ||
483 | 174 | table.summary | ||
484 | 175 | a.summary-name:visited { color: #006080; font-weight: bold; | ||
485 | 176 | font-family: monospace; } | ||
486 | 177 | |||
487 | 178 | /* Variable values | ||
488 | 179 | * - In the 'variable details' sections, each varaible's value is | ||
489 | 180 | * listed in a 'pre.variable' box. The width of this box is | ||
490 | 181 | * restricted to 80 chars; if the value's repr is longer than | ||
491 | 182 | * this it will be wrapped, using a backslash marked with | ||
492 | 183 | * class 'variable-linewrap'. If the value's repr is longer | ||
493 | 184 | * than 3 lines, the rest will be ellided; and an ellipsis | ||
494 | 185 | * marker ('...' marked with 'variable-ellipsis') will be used. | ||
495 | 186 | * - If the value is a string, its quote marks will be marked | ||
496 | 187 | * with 'variable-quote'. | ||
497 | 188 | * - If the variable is a regexp, it is syntax-highlighted using | ||
498 | 189 | * the re* CSS classes. | ||
499 | 190 | */ | ||
500 | 191 | pre.variable { padding: .5em; margin: 0; | ||
501 | 192 | background: #dce4ec; color: #000000; | ||
502 | 193 | border: 1px solid #708890; } | ||
503 | 194 | .variable-linewrap { color: #604000; font-weight: bold; } | ||
504 | 195 | .variable-ellipsis { color: #604000; font-weight: bold; } | ||
505 | 196 | .variable-quote { color: #604000; font-weight: bold; } | ||
506 | 197 | .variable-group { color: #008000; font-weight: bold; } | ||
507 | 198 | .variable-op { color: #604000; font-weight: bold; } | ||
508 | 199 | .variable-string { color: #006030; } | ||
509 | 200 | .variable-unknown { color: #a00000; font-weight: bold; } | ||
510 | 201 | .re { color: #000000; } | ||
511 | 202 | .re-char { color: #006030; } | ||
512 | 203 | .re-op { color: #600000; } | ||
513 | 204 | .re-group { color: #003060; } | ||
514 | 205 | .re-ref { color: #404040; } | ||
515 | 206 | |||
516 | 207 | /* Base tree | ||
517 | 208 | * - Used by class pages to display the base class hierarchy. | ||
518 | 209 | */ | ||
519 | 210 | pre.base-tree { font-size: 80%; margin: 0; } | ||
520 | 211 | |||
521 | 212 | /* Frames-based table of contents headers | ||
522 | 213 | * - Consists of two frames: one for selecting modules; and | ||
523 | 214 | * the other listing the contents of the selected module. | ||
524 | 215 | * - h1.toc is used for each frame's heading | ||
525 | 216 | * - h2.toc is used for subheadings within each frame. | ||
526 | 217 | */ | ||
527 | 218 | h1.toc { text-align: center; font-size: 105%; | ||
528 | 219 | margin: 0; font-weight: bold; | ||
529 | 220 | padding: 0; } | ||
530 | 221 | h2.toc { font-size: 100%; font-weight: bold; | ||
531 | 222 | margin: 0.5em 0 0 -0.3em; } | ||
532 | 223 | |||
533 | 224 | /* Syntax Highlighting for Source Code | ||
534 | 225 | * - doctest examples are displayed in a 'pre.py-doctest' block. | ||
535 | 226 | * If the example is in a details table entry, then it will use | ||
536 | 227 | * the colors specified by the 'table pre.py-doctest' line. | ||
537 | 228 | * - Source code listings are displayed in a 'pre.py-src' block. | ||
538 | 229 | * Each line is marked with 'span.py-line' (used to draw a line | ||
539 | 230 | * down the left margin, separating the code from the line | ||
540 | 231 | * numbers). Line numbers are displayed with 'span.py-lineno'. | ||
541 | 232 | * The expand/collapse block toggle button is displayed with | ||
542 | 233 | * 'a.py-toggle' (Note: the CSS style for 'a.py-toggle' should not | ||
543 | 234 | * modify the font size of the text.) | ||
544 | 235 | * - If a source code page is opened with an anchor, then the | ||
545 | 236 | * corresponding code block will be highlighted. The code | ||
546 | 237 | * block's header is highlighted with 'py-highlight-hdr'; and | ||
547 | 238 | * the code block's body is highlighted with 'py-highlight'. | ||
548 | 239 | * - The remaining py-* classes are used to perform syntax | ||
549 | 240 | * highlighting (py-string for string literals, py-name for names, | ||
550 | 241 | * etc.) | ||
551 | 242 | */ | ||
552 | 243 | pre.py-doctest { padding: .5em; margin: 1em; | ||
553 | 244 | background: #e8f0f8; color: #000000; | ||
554 | 245 | border: 1px solid #708890; } | ||
555 | 246 | table pre.py-doctest { background: #dce4ec; | ||
556 | 247 | color: #000000; } | ||
557 | 248 | pre.py-src { border: 2px solid #000000; | ||
558 | 249 | background: #f0f0f0; color: #000000; } | ||
559 | 250 | .py-line { border-left: 2px solid #000000; | ||
560 | 251 | margin-left: .2em; padding-left: .4em; } | ||
561 | 252 | .py-lineno { font-style: italic; font-size: 90%; | ||
562 | 253 | padding-left: .5em; } | ||
563 | 254 | a.py-toggle { text-decoration: none; } | ||
564 | 255 | div.py-highlight-hdr { border-top: 2px solid #000000; | ||
565 | 256 | border-bottom: 2px solid #000000; | ||
566 | 257 | background: #d8e8e8; } | ||
567 | 258 | div.py-highlight { border-bottom: 2px solid #000000; | ||
568 | 259 | background: #d0e0e0; } | ||
569 | 260 | .py-prompt { color: #005050; font-weight: bold;} | ||
570 | 261 | .py-more { color: #005050; font-weight: bold;} | ||
571 | 262 | .py-string { color: #006030; } | ||
572 | 263 | .py-comment { color: #003060; } | ||
573 | 264 | .py-keyword { color: #600000; } | ||
574 | 265 | .py-output { color: #404040; } | ||
575 | 266 | .py-name { color: #000050; } | ||
576 | 267 | .py-name:link { color: #000050 !important; } | ||
577 | 268 | .py-name:visited { color: #000050 !important; } | ||
578 | 269 | .py-number { color: #005000; } | ||
579 | 270 | .py-defname { color: #000060; font-weight: bold; } | ||
580 | 271 | .py-def-name { color: #000060; font-weight: bold; } | ||
581 | 272 | .py-base-class { color: #000060; } | ||
582 | 273 | .py-param { color: #000060; } | ||
583 | 274 | .py-docstring { color: #006030; } | ||
584 | 275 | .py-decorator { color: #804020; } | ||
585 | 276 | /* Use this if you don't want links to names underlined: */ | ||
586 | 277 | /*a.py-name { text-decoration: none; }*/ | ||
587 | 278 | |||
588 | 279 | /* Graphs & Diagrams | ||
589 | 280 | * - These CSS styles are used for graphs & diagrams generated using | ||
590 | 281 | * Graphviz dot. 'img.graph-without-title' is used for bare | ||
591 | 282 | * diagrams (to remove the border created by making the image | ||
592 | 283 | * clickable). | ||
593 | 284 | */ | ||
594 | 285 | img.graph-without-title { border: none; } | ||
595 | 286 | img.graph-with-title { border: 1px solid #000000; } | ||
596 | 287 | span.graph-title { font-weight: bold; } | ||
597 | 288 | span.graph-caption { } | ||
598 | 289 | |||
599 | 290 | /* General-purpose classes | ||
600 | 291 | * - 'p.indent-wrapped-lines' defines a paragraph whose first line | ||
601 | 292 | * is not indented, but whose subsequent lines are. | ||
602 | 293 | * - The 'nomargin-top' class is used to remove the top margin (e.g. | ||
603 | 294 | * from lists). The 'nomargin' class is used to remove both the | ||
604 | 295 | * top and bottom margin (but not the left or right margin -- | ||
605 | 296 | * for lists, that would cause the bullets to disappear.) | ||
606 | 297 | */ | ||
607 | 298 | p.indent-wrapped-lines { padding: 0 0 0 7em; text-indent: -7em; | ||
608 | 299 | margin: 0; } | ||
609 | 300 | .nomargin-top { margin-top: 0; } | ||
610 | 301 | .nomargin { margin-top: 0; margin-bottom: 0; } | ||
611 | 302 | |||
612 | 303 | /* HTML Log */ | ||
613 | 304 | div.log-block { padding: 0; margin: .5em 0 .5em 0; | ||
614 | 305 | background: #e8f0f8; color: #000000; | ||
615 | 306 | border: 1px solid #000000; } | ||
616 | 307 | div.log-error { padding: .1em .3em .1em .3em; margin: 4px; | ||
617 | 308 | background: #ffb0b0; color: #000000; | ||
618 | 309 | border: 1px solid #000000; } | ||
619 | 310 | div.log-warning { padding: .1em .3em .1em .3em; margin: 4px; | ||
620 | 311 | background: #ffffb0; color: #000000; | ||
621 | 312 | border: 1px solid #000000; } | ||
622 | 313 | div.log-info { padding: .1em .3em .1em .3em; margin: 4px; | ||
623 | 314 | background: #b0ffb0; color: #000000; | ||
624 | 315 | border: 1px solid #000000; } | ||
625 | 316 | h2.log-hdr { background: #70b0ff; color: #000000; | ||
626 | 317 | margin: 0; padding: 0em 0.5em 0em 0.5em; | ||
627 | 318 | border-bottom: 1px solid #000000; font-size: 110%; } | ||
628 | 319 | p.log { font-weight: bold; margin: .5em 0 .5em 0; } | ||
629 | 320 | tr.opt-changed { color: #000000; font-weight: bold; } | ||
630 | 321 | tr.opt-default { color: #606060; } | ||
631 | 322 | pre.log { margin: 0; padding: 0; padding-left: 1em; } | ||
632 | 0 | 323 | ||
633 | === removed file 'doc/html/epydoc.css' | |||
634 | --- doc/html/epydoc.css 2009-12-26 20:49:38 +0000 | |||
635 | +++ doc/html/epydoc.css 1970-01-01 00:00:00 +0000 | |||
636 | @@ -1,312 +0,0 @@ | |||
637 | 1 | |||
638 | 2 | |||
639 | 3 | /* Epydoc CSS Stylesheet | ||
640 | 4 | * | ||
641 | 5 | * This stylesheet can be used to customize the appearance of epydoc's | ||
642 | 6 | * HTML output. | ||
643 | 7 | * | ||
644 | 8 | */ | ||
645 | 9 | |||
646 | 10 | /* Default Colors & Styles | ||
647 | 11 | * - Set the default foreground & background color with 'body'; and | ||
648 | 12 | * link colors with 'a:link' and 'a:visited'. | ||
649 | 13 | * - Use bold for decision list terms. | ||
650 | 14 | * - The heading styles defined here are used for headings *within* | ||
651 | 15 | * docstring descriptions. All headings used by epydoc itself use | ||
652 | 16 | * either class='epydoc' or class='toc' (CSS styles for both | ||
653 | 17 | * defined below). | ||
654 | 18 | */ | ||
655 | 19 | body { background: #ffffff; color: #000000; } | ||
656 | 20 | a:link { color: #0000ff; } | ||
657 | 21 | a:visited { color: #204080; } | ||
658 | 22 | dt { font-weight: bold; } | ||
659 | 23 | h1 { font-size: +140%; font-style: italic; | ||
660 | 24 | font-weight: bold; } | ||
661 | 25 | h2 { font-size: +125%; font-style: italic; | ||
662 | 26 | font-weight: bold; } | ||
663 | 27 | h3 { font-size: +110%; font-style: italic; | ||
664 | 28 | font-weight: normal; } | ||
665 | 29 | code { font-size: 100%; } | ||
666 | 30 | |||
667 | 31 | /* Page Header & Footer | ||
668 | 32 | * - The standard page header consists of a navigation bar (with | ||
669 | 33 | * pointers to standard pages such as 'home' and 'trees'); a | ||
670 | 34 | * breadcrumbs list, which can be used to navigate to containing | ||
671 | 35 | * classes or modules; options links, to show/hide private | ||
672 | 36 | * variables and to show/hide frames; and a page title (using | ||
673 | 37 | * <h1>). The page title may be followed by a link to the | ||
674 | 38 | * corresponding source code (using 'span.codelink'). | ||
675 | 39 | * - The footer consists of a navigation bar, a timestamp, and a | ||
676 | 40 | * pointer to epydoc's homepage. | ||
677 | 41 | */ | ||
678 | 42 | h1.epydoc { margin: 0; font-size: +140%; font-weight: bold; } | ||
679 | 43 | h2.epydoc { font-size: +130%; font-weight: bold; } | ||
680 | 44 | h3.epydoc { font-size: +115%; font-weight: bold; } | ||
681 | 45 | td h3.epydoc { font-size: +115%; font-weight: bold; | ||
682 | 46 | margin-bottom: 0; } | ||
683 | 47 | table.navbar { background: #a0c0ff; color: #000000; | ||
684 | 48 | border: 2px groove #c0d0d0; } | ||
685 | 49 | table.navbar table { color: #000000; } | ||
686 | 50 | th.navbar-select { background: #70b0ff; | ||
687 | 51 | color: #000000; } | ||
688 | 52 | table.navbar a { text-decoration: none; } | ||
689 | 53 | table.navbar a:link { color: #0000ff; } | ||
690 | 54 | table.navbar a:visited { color: #204080; } | ||
691 | 55 | span.breadcrumbs { font-size: 85%; font-weight: bold; } | ||
692 | 56 | span.options { font-size: 70%; } | ||
693 | 57 | span.codelink { font-size: 85%; } | ||
694 | 58 | td.footer { font-size: 85%; } | ||
695 | 59 | |||
696 | 60 | /* Table Headers | ||
697 | 61 | * - Each summary table and details section begins with a 'header' | ||
698 | 62 | * row. This row contains a section title (marked by | ||
699 | 63 | * 'span.table-header') as well as a show/hide private link | ||
700 | 64 | * (marked by 'span.options', defined above). | ||
701 | 65 | * - Summary tables that contain user-defined groups mark those | ||
702 | 66 | * groups using 'group header' rows. | ||
703 | 67 | */ | ||
704 | 68 | td.table-header { background: #70b0ff; color: #000000; | ||
705 | 69 | border: 1px solid #608090; } | ||
706 | 70 | td.table-header table { color: #000000; } | ||
707 | 71 | td.table-header table a:link { color: #0000ff; } | ||
708 | 72 | td.table-header table a:visited { color: #204080; } | ||
709 | 73 | span.table-header { font-size: 120%; font-weight: bold; } | ||
710 | 74 | th.group-header { background: #c0e0f8; color: #000000; | ||
711 | 75 | text-align: left; font-style: italic; | ||
712 | 76 | font-size: 115%; | ||
713 | 77 | border: 1px solid #608090; } | ||
714 | 78 | |||
715 | 79 | /* Summary Tables (functions, variables, etc) | ||
716 | 80 | * - Each object is described by a single row of the table with | ||
717 | 81 | * two cells. The left cell gives the object's type, and is | ||
718 | 82 | * marked with 'code.summary-type'. The right cell gives the | ||
719 | 83 | * object's name and a summary description. | ||
720 | 84 | * - CSS styles for the table's header and group headers are | ||
721 | 85 | * defined above, under 'Table Headers' | ||
722 | 86 | */ | ||
723 | 87 | table.summary { border-collapse: collapse; | ||
724 | 88 | background: #e8f0f8; color: #000000; | ||
725 | 89 | border: 1px solid #608090; | ||
726 | 90 | margin-bottom: 0.5em; } | ||
727 | 91 | td.summary { border: 1px solid #608090; } | ||
728 | 92 | code.summary-type { font-size: 85%; } | ||
729 | 93 | table.summary a:link { color: #0000ff; } | ||
730 | 94 | table.summary a:visited { color: #204080; } | ||
731 | 95 | |||
732 | 96 | |||
733 | 97 | /* Details Tables (functions, variables, etc) | ||
734 | 98 | * - Each object is described in its own div. | ||
735 | 99 | * - A single-row summary table w/ table-header is used as | ||
736 | 100 | * a header for each details section (CSS style for table-header | ||
737 | 101 | * is defined above, under 'Table Headers'). | ||
738 | 102 | */ | ||
739 | 103 | table.details { border-collapse: collapse; | ||
740 | 104 | background: #e8f0f8; color: #000000; | ||
741 | 105 | border: 1px solid #608090; | ||
742 | 106 | margin: .2em 0 0 0; } | ||
743 | 107 | table.details table { color: #000000; } | ||
744 | 108 | table.details a:link { color: #0000ff; } | ||
745 | 109 | table.details a:visited { color: #204080; } | ||
746 | 110 | |||
747 | 111 | /* Fields */ | ||
748 | 112 | dl.fields { margin-left: 2em; margin-top: 1em; | ||
749 | 113 | margin-bottom: 1em; } | ||
750 | 114 | dl.fields dd ul { margin-left: 0em; padding-left: 0em; } | ||
751 | 115 | div.fields { margin-left: 2em; } | ||
752 | 116 | div.fields p { margin-bottom: 0.5em; } | ||
753 | 117 | |||
754 | 118 | /* Index tables (identifier index, term index, etc) | ||
755 | 119 | * - link-index is used for indices containing lists of links | ||
756 | 120 | * (namely, the identifier index & term index). | ||
757 | 121 | * - index-where is used in link indices for the text indicating | ||
758 | 122 | * the container/source for each link. | ||
759 | 123 | * - metadata-index is used for indices containing metadata | ||
760 | 124 | * extracted from fields (namely, the bug index & todo index). | ||
761 | 125 | */ | ||
762 | 126 | table.link-index { border-collapse: collapse; | ||
763 | 127 | background: #e8f0f8; color: #000000; | ||
764 | 128 | border: 1px solid #608090; } | ||
765 | 129 | td.link-index { border-width: 0px; } | ||
766 | 130 | table.link-index a:link { color: #0000ff; } | ||
767 | 131 | table.link-index a:visited { color: #204080; } | ||
768 | 132 | span.index-where { font-size: 70%; } | ||
769 | 133 | table.metadata-index { border-collapse: collapse; | ||
770 | 134 | background: #e8f0f8; color: #000000; | ||
771 | 135 | border: 1px solid #608090; | ||
772 | 136 | margin: .2em 0 0 0; } | ||
773 | 137 | td.metadata-index { border-width: 1px; border-style: solid; } | ||
774 | 138 | table.metadata-index a:link { color: #0000ff; } | ||
775 | 139 | table.metadata-index a:visited { color: #204080; } | ||
776 | 140 | |||
777 | 141 | /* Function signatures | ||
778 | 142 | * - sig* is used for the signature in the details section. | ||
779 | 143 | * - .summary-sig* is used for the signature in the summary | ||
780 | 144 | * table, and when listing property accessor functions. | ||
781 | 145 | * */ | ||
782 | 146 | .sig-name { color: #006080; } | ||
783 | 147 | .sig-arg { color: #008060; } | ||
784 | 148 | .sig-default { color: #602000; } | ||
785 | 149 | .summary-sig { font-family: monospace; } | ||
786 | 150 | .summary-sig-name { color: #006080; font-weight: bold; } | ||
787 | 151 | table.summary a.summary-sig-name:link | ||
788 | 152 | { color: #006080; font-weight: bold; } | ||
789 | 153 | table.summary a.summary-sig-name:visited | ||
790 | 154 | { color: #006080; font-weight: bold; } | ||
791 | 155 | .summary-sig-arg { color: #006040; } | ||
792 | 156 | .summary-sig-default { color: #501800; } | ||
793 | 157 | |||
794 | 158 | /* To render variables, classes etc. like functions */ | ||
795 | 159 | table.summary .summary-name { color: #006080; font-weight: bold; | ||
796 | 160 | font-family: monospace; } | ||
797 | 161 | table.summary | ||
798 | 162 | a.summary-name:link { color: #006080; font-weight: bold; | ||
799 | 163 | font-family: monospace; } | ||
800 | 164 | table.summary | ||
801 | 165 | a.summary-name:visited { color: #006080; font-weight: bold; | ||
802 | 166 | font-family: monospace; } | ||
803 | 167 | |||
804 | 168 | /* Variable values | ||
805 | 169 | * - In the 'variable details' sections, each varaible's value is | ||
806 | 170 | * listed in a 'pre.variable' box. The width of this box is | ||
807 | 171 | * restricted to 80 chars; if the value's repr is longer than | ||
808 | 172 | * this it will be wrapped, using a backslash marked with | ||
809 | 173 | * class 'variable-linewrap'. If the value's repr is longer | ||
810 | 174 | * than 3 lines, the rest will be ellided; and an ellipsis | ||
811 | 175 | * marker ('...' marked with 'variable-ellipsis') will be used. | ||
812 | 176 | * - If the value is a string, its quote marks will be marked | ||
813 | 177 | * with 'variable-quote'. | ||
814 | 178 | * - If the variable is a regexp, it is syntax-highlighted using | ||
815 | 179 | * the re* CSS classes. | ||
816 | 180 | */ | ||
817 | 181 | pre.variable { padding: .5em; margin: 0; | ||
818 | 182 | background: #dce4ec; color: #000000; | ||
819 | 183 | border: 1px solid #708890; } | ||
820 | 184 | .variable-linewrap { color: #604000; font-weight: bold; } | ||
821 | 185 | .variable-ellipsis { color: #604000; font-weight: bold; } | ||
822 | 186 | .variable-quote { color: #604000; font-weight: bold; } | ||
823 | 187 | .variable-group { color: #008000; font-weight: bold; } | ||
824 | 188 | .variable-op { color: #604000; font-weight: bold; } | ||
825 | 189 | .variable-string { color: #006030; } | ||
826 | 190 | .variable-unknown { color: #a00000; font-weight: bold; } | ||
827 | 191 | .re { color: #000000; } | ||
828 | 192 | .re-char { color: #006030; } | ||
829 | 193 | .re-op { color: #600000; } | ||
830 | 194 | .re-group { color: #003060; } | ||
831 | 195 | .re-ref { color: #404040; } | ||
832 | 196 | |||
833 | 197 | /* Base tree | ||
834 | 198 | * - Used by class pages to display the base class hierarchy. | ||
835 | 199 | */ | ||
836 | 200 | pre.base-tree { font-size: 80%; margin: 0; } | ||
837 | 201 | |||
838 | 202 | /* Frames-based table of contents headers | ||
839 | 203 | * - Consists of two frames: one for selecting modules; and | ||
840 | 204 | * the other listing the contents of the selected module. | ||
841 | 205 | * - h1.toc is used for each frame's heading | ||
842 | 206 | * - h2.toc is used for subheadings within each frame. | ||
843 | 207 | */ | ||
844 | 208 | h1.toc { text-align: center; font-size: 105%; | ||
845 | 209 | margin: 0; font-weight: bold; | ||
846 | 210 | padding: 0; } | ||
847 | 211 | h2.toc { font-size: 100%; font-weight: bold; | ||
848 | 212 | margin: 0.5em 0 0 -0.3em; } | ||
849 | 213 | |||
850 | 214 | /* Syntax Highlighting for Source Code | ||
851 | 215 | * - doctest examples are displayed in a 'pre.py-doctest' block. | ||
852 | 216 | * If the example is in a details table entry, then it will use | ||
853 | 217 | * the colors specified by the 'table pre.py-doctest' line. | ||
854 | 218 | * - Source code listings are displayed in a 'pre.py-src' block. | ||
855 | 219 | * Each line is marked with 'span.py-line' (used to draw a line | ||
856 | 220 | * down the left margin, separating the code from the line | ||
857 | 221 | * numbers). Line numbers are displayed with 'span.py-lineno'. | ||
858 | 222 | * The expand/collapse block toggle button is displayed with | ||
859 | 223 | * 'a.py-toggle' (Note: the CSS style for 'a.py-toggle' should not | ||
860 | 224 | * modify the font size of the text.) | ||
861 | 225 | * - If a source code page is opened with an anchor, then the | ||
862 | 226 | * corresponding code block will be highlighted. The code | ||
863 | 227 | * block's header is highlighted with 'py-highlight-hdr'; and | ||
864 | 228 | * the code block's body is highlighted with 'py-highlight'. | ||
865 | 229 | * - The remaining py-* classes are used to perform syntax | ||
866 | 230 | * highlighting (py-string for string literals, py-name for names, | ||
867 | 231 | * etc.) | ||
868 | 232 | */ | ||
869 | 233 | pre.py-doctest { padding: .5em; margin: 1em; | ||
870 | 234 | background: #e8f0f8; color: #000000; | ||
871 | 235 | border: 1px solid #708890; } | ||
872 | 236 | table pre.py-doctest { background: #dce4ec; | ||
873 | 237 | color: #000000; } | ||
874 | 238 | pre.py-src { border: 2px solid #000000; | ||
875 | 239 | background: #f0f0f0; color: #000000; } | ||
876 | 240 | .py-line { border-left: 2px solid #000000; | ||
877 | 241 | margin-left: .2em; padding-left: .4em; } | ||
878 | 242 | .py-lineno { font-style: italic; font-size: 90%; | ||
879 | 243 | padding-left: .5em; } | ||
880 | 244 | a.py-toggle { text-decoration: none; } | ||
881 | 245 | div.py-highlight-hdr { border-top: 2px solid #000000; | ||
882 | 246 | border-bottom: 2px solid #000000; | ||
883 | 247 | background: #d8e8e8; } | ||
884 | 248 | div.py-highlight { border-bottom: 2px solid #000000; | ||
885 | 249 | background: #d0e0e0; } | ||
886 | 250 | .py-prompt { color: #005050; font-weight: bold;} | ||
887 | 251 | .py-more { color: #005050; font-weight: bold;} | ||
888 | 252 | .py-string { color: #006030; } | ||
889 | 253 | .py-comment { color: #003060; } | ||
890 | 254 | .py-keyword { color: #600000; } | ||
891 | 255 | .py-output { color: #404040; } | ||
892 | 256 | .py-name { color: #000050; } | ||
893 | 257 | .py-name:link { color: #000050 !important; } | ||
894 | 258 | .py-name:visited { color: #000050 !important; } | ||
895 | 259 | .py-number { color: #005000; } | ||
896 | 260 | .py-defname { color: #000060; font-weight: bold; } | ||
897 | 261 | .py-def-name { color: #000060; font-weight: bold; } | ||
898 | 262 | .py-base-class { color: #000060; } | ||
899 | 263 | .py-param { color: #000060; } | ||
900 | 264 | .py-docstring { color: #006030; } | ||
901 | 265 | .py-decorator { color: #804020; } | ||
902 | 266 | /* Use this if you don't want links to names underlined: */ | ||
903 | 267 | /*a.py-name { text-decoration: none; }*/ | ||
904 | 268 | |||
905 | 269 | /* Graphs & Diagrams | ||
906 | 270 | * - These CSS styles are used for graphs & diagrams generated using | ||
907 | 271 | * Graphviz dot. 'img.graph-without-title' is used for bare | ||
908 | 272 | * diagrams (to remove the border created by making the image | ||
909 | 273 | * clickable). | ||
910 | 274 | */ | ||
911 | 275 | img.graph-without-title { border: none; } | ||
912 | 276 | img.graph-with-title { border: 1px solid #000000; } | ||
913 | 277 | span.graph-title { font-weight: bold; } | ||
914 | 278 | span.graph-caption { } | ||
915 | 279 | |||
916 | 280 | /* General-purpose classes | ||
917 | 281 | * - 'p.indent-wrapped-lines' defines a paragraph whose first line | ||
918 | 282 | * is not indented, but whose subsequent lines are. | ||
919 | 283 | * - The 'nomargin-top' class is used to remove the top margin (e.g. | ||
920 | 284 | * from lists). The 'nomargin' class is used to remove both the | ||
921 | 285 | * top and bottom margin (but not the left or right margin -- | ||
922 | 286 | * for lists, that would cause the bullets to disappear.) | ||
923 | 287 | */ | ||
924 | 288 | p.indent-wrapped-lines { padding: 0 0 0 7em; text-indent: -7em; | ||
925 | 289 | margin: 0; } | ||
926 | 290 | .nomargin-top { margin-top: 0; } | ||
927 | 291 | .nomargin { margin-top: 0; margin-bottom: 0; } | ||
928 | 292 | |||
929 | 293 | /* HTML Log */ | ||
930 | 294 | div.log-block { padding: 0; margin: .5em 0 .5em 0; | ||
931 | 295 | background: #e8f0f8; color: #000000; | ||
932 | 296 | border: 1px solid #000000; } | ||
933 | 297 | div.log-error { padding: .1em .3em .1em .3em; margin: 4px; | ||
934 | 298 | background: #ffb0b0; color: #000000; | ||
935 | 299 | border: 1px solid #000000; } | ||
936 | 300 | div.log-warning { padding: .1em .3em .1em .3em; margin: 4px; | ||
937 | 301 | background: #ffffb0; color: #000000; | ||
938 | 302 | border: 1px solid #000000; } | ||
939 | 303 | div.log-info { padding: .1em .3em .1em .3em; margin: 4px; | ||
940 | 304 | background: #b0ffb0; color: #000000; | ||
941 | 305 | border: 1px solid #000000; } | ||
942 | 306 | h2.log-hdr { background: #70b0ff; color: #000000; | ||
943 | 307 | margin: 0; padding: 0em 0.5em 0em 0.5em; | ||
944 | 308 | border-bottom: 1px solid #000000; font-size: 110%; } | ||
945 | 309 | p.log { font-weight: bold; margin: .5em 0 .5em 0; } | ||
946 | 310 | tr.opt-changed { color: #000000; font-weight: bold; } | ||
947 | 311 | tr.opt-default { color: #606060; } | ||
948 | 312 | pre.log { margin: 0; padding: 0; padding-left: 1em; } | ||
949 | 313 | 0 | ||
950 | === added file 'doc/html/epydoc.js' | |||
951 | --- doc/html/epydoc.js 1970-01-01 00:00:00 +0000 | |||
952 | +++ doc/html/epydoc.js 2009-12-26 22:06:14 +0000 | |||
953 | @@ -0,0 +1,293 @@ | |||
954 | 1 | function toggle_private() { | ||
955 | 2 | // Search for any private/public links on this page. Store | ||
956 | 3 | // their old text in "cmd," so we will know what action to | ||
957 | 4 | // take; and change their text to the opposite action. | ||
958 | 5 | var cmd = "?"; | ||
959 | 6 | var elts = document.getElementsByTagName("a"); | ||
960 | 7 | for(var i=0; i<elts.length; i++) { | ||
961 | 8 | if (elts[i].className == "privatelink") { | ||
962 | 9 | cmd = elts[i].innerHTML; | ||
963 | 10 | elts[i].innerHTML = ((cmd && cmd.substr(0,4)=="show")? | ||
964 | 11 | "hide private":"show private"); | ||
965 | 12 | } | ||
966 | 13 | } | ||
967 | 14 | // Update all DIVs containing private objects. | ||
968 | 15 | var elts = document.getElementsByTagName("div"); | ||
969 | 16 | for(var i=0; i<elts.length; i++) { | ||
970 | 17 | if (elts[i].className == "private") { | ||
971 | 18 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")?"none":"block"); | ||
972 | 19 | } | ||
973 | 20 | else if (elts[i].className == "public") { | ||
974 | 21 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")?"block":"none"); | ||
975 | 22 | } | ||
976 | 23 | } | ||
977 | 24 | // Update all table rows containing private objects. Note, we | ||
978 | 25 | // use "" instead of "block" becaue IE & firefox disagree on what | ||
979 | 26 | // this should be (block vs table-row), and "" just gives the | ||
980 | 27 | // default for both browsers. | ||
981 | 28 | var elts = document.getElementsByTagName("tr"); | ||
982 | 29 | for(var i=0; i<elts.length; i++) { | ||
983 | 30 | if (elts[i].className == "private") { | ||
984 | 31 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")?"none":""); | ||
985 | 32 | } | ||
986 | 33 | } | ||
987 | 34 | // Update all list items containing private objects. | ||
988 | 35 | var elts = document.getElementsByTagName("li"); | ||
989 | 36 | for(var i=0; i<elts.length; i++) { | ||
990 | 37 | if (elts[i].className == "private") { | ||
991 | 38 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")? | ||
992 | 39 | "none":""); | ||
993 | 40 | } | ||
994 | 41 | } | ||
995 | 42 | // Update all list items containing private objects. | ||
996 | 43 | var elts = document.getElementsByTagName("ul"); | ||
997 | 44 | for(var i=0; i<elts.length; i++) { | ||
998 | 45 | if (elts[i].className == "private") { | ||
999 | 46 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")?"none":"block"); | ||
1000 | 47 | } | ||
1001 | 48 | } | ||
1002 | 49 | // Set a cookie to remember the current option. | ||
1003 | 50 | document.cookie = "EpydocPrivate="+cmd; | ||
1004 | 51 | } | ||
1005 | 52 | function show_private() { | ||
1006 | 53 | var elts = document.getElementsByTagName("a"); | ||
1007 | 54 | for(var i=0; i<elts.length; i++) { | ||
1008 | 55 | if (elts[i].className == "privatelink") { | ||
1009 | 56 | cmd = elts[i].innerHTML; | ||
1010 | 57 | if (cmd && cmd.substr(0,4)=="show") | ||
1011 | 58 | toggle_private(); | ||
1012 | 59 | } | ||
1013 | 60 | } | ||
1014 | 61 | } | ||
1015 | 62 | function getCookie(name) { | ||
1016 | 63 | var dc = document.cookie; | ||
1017 | 64 | var prefix = name + "="; | ||
1018 | 65 | var begin = dc.indexOf("; " + prefix); | ||
1019 | 66 | if (begin == -1) { | ||
1020 | 67 | begin = dc.indexOf(prefix); | ||
1021 | 68 | if (begin != 0) return null; | ||
1022 | 69 | } else | ||
1023 | 70 | { begin += 2; } | ||
1024 | 71 | var end = document.cookie.indexOf(";", begin); | ||
1025 | 72 | if (end == -1) | ||
1026 | 73 | { end = dc.length; } | ||
1027 | 74 | return unescape(dc.substring(begin + prefix.length, end)); | ||
1028 | 75 | } | ||
1029 | 76 | function setFrame(url1, url2) { | ||
1030 | 77 | parent.frames[1].location.href = url1; | ||
1031 | 78 | parent.frames[2].location.href = url2; | ||
1032 | 79 | } | ||
1033 | 80 | function checkCookie() { | ||
1034 | 81 | var cmd=getCookie("EpydocPrivate"); | ||
1035 | 82 | if (cmd && cmd.substr(0,4)!="show" && location.href.indexOf("#_") < 0) | ||
1036 | 83 | toggle_private(); | ||
1037 | 84 | } | ||
1038 | 85 | function toggleCallGraph(id) { | ||
1039 | 86 | var elt = document.getElementById(id); | ||
1040 | 87 | if (elt.style.display == "none") | ||
1041 | 88 | elt.style.display = "block"; | ||
1042 | 89 | else | ||
1043 | 90 | elt.style.display = "none"; | ||
1044 | 91 | } | ||
1045 | 92 | function expand(id) { | ||
1046 | 93 | var elt = document.getElementById(id+"-expanded"); | ||
1047 | 94 | if (elt) elt.style.display = "block"; | ||
1048 | 95 | var elt = document.getElementById(id+"-expanded-linenums"); | ||
1049 | 96 | if (elt) elt.style.display = "block"; | ||
1050 | 97 | var elt = document.getElementById(id+"-collapsed"); | ||
1051 | 98 | if (elt) { elt.innerHTML = ""; elt.style.display = "none"; } | ||
1052 | 99 | var elt = document.getElementById(id+"-collapsed-linenums"); | ||
1053 | 100 | if (elt) { elt.innerHTML = ""; elt.style.display = "none"; } | ||
1054 | 101 | var elt = document.getElementById(id+"-toggle"); | ||
1055 | 102 | if (elt) { elt.innerHTML = "-"; } | ||
1056 | 103 | } | ||
1057 | 104 | |||
1058 | 105 | function collapse(id) { | ||
1059 | 106 | var elt = document.getElementById(id+"-expanded"); | ||
1060 | 107 | if (elt) elt.style.display = "none"; | ||
1061 | 108 | var elt = document.getElementById(id+"-expanded-linenums"); | ||
1062 | 109 | if (elt) elt.style.display = "none"; | ||
1063 | 110 | var elt = document.getElementById(id+"-collapsed-linenums"); | ||
1064 | 111 | if (elt) { elt.innerHTML = "<br />"; elt.style.display="block"; } | ||
1065 | 112 | var elt = document.getElementById(id+"-toggle"); | ||
1066 | 113 | if (elt) { elt.innerHTML = "+"; } | ||
1067 | 114 | var elt = document.getElementById(id+"-collapsed"); | ||
1068 | 115 | if (elt) { | ||
1069 | 116 | elt.style.display = "block"; | ||
1070 | 117 | |||
1071 | 118 | var indent = elt.getAttribute("indent"); | ||
1072 | 119 | var pad = elt.getAttribute("pad"); | ||
1073 | 120 | var s = "<tt class='py-lineno'>"; | ||
1074 | 121 | for (var i=0; i<pad.length; i++) { s += " " } | ||
1075 | 122 | s += "</tt>"; | ||
1076 | 123 | s += " <tt class='py-line'>"; | ||
1077 | 124 | for (var i=0; i<indent.length; i++) { s += " " } | ||
1078 | 125 | s += "<a href='#' onclick='expand(\"" + id; | ||
1079 | 126 | s += "\");return false'>...</a></tt><br />"; | ||
1080 | 127 | elt.innerHTML = s; | ||
1081 | 128 | } | ||
1082 | 129 | } | ||
1083 | 130 | |||
1084 | 131 | function toggle(id) { | ||
1085 | 132 | elt = document.getElementById(id+"-toggle"); | ||
1086 | 133 | if (elt.innerHTML == "-") | ||
1087 | 134 | collapse(id); | ||
1088 | 135 | else | ||
1089 | 136 | expand(id); | ||
1090 | 137 | return false; | ||
1091 | 138 | } | ||
1092 | 139 | |||
1093 | 140 | function highlight(id) { | ||
1094 | 141 | var elt = document.getElementById(id+"-def"); | ||
1095 | 142 | if (elt) elt.className = "py-highlight-hdr"; | ||
1096 | 143 | var elt = document.getElementById(id+"-expanded"); | ||
1097 | 144 | if (elt) elt.className = "py-highlight"; | ||
1098 | 145 | var elt = document.getElementById(id+"-collapsed"); | ||
1099 | 146 | if (elt) elt.className = "py-highlight"; | ||
1100 | 147 | } | ||
1101 | 148 | |||
1102 | 149 | function num_lines(s) { | ||
1103 | 150 | var n = 1; | ||
1104 | 151 | var pos = s.indexOf("\n"); | ||
1105 | 152 | while ( pos > 0) { | ||
1106 | 153 | n += 1; | ||
1107 | 154 | pos = s.indexOf("\n", pos+1); | ||
1108 | 155 | } | ||
1109 | 156 | return n; | ||
1110 | 157 | } | ||
1111 | 158 | |||
1112 | 159 | // Collapse all blocks that mave more than `min_lines` lines. | ||
1113 | 160 | function collapse_all(min_lines) { | ||
1114 | 161 | var elts = document.getElementsByTagName("div"); | ||
1115 | 162 | for (var i=0; i<elts.length; i++) { | ||
1116 | 163 | var elt = elts[i]; | ||
1117 | 164 | var split = elt.id.indexOf("-"); | ||
1118 | 165 | if (split > 0) | ||
1119 | 166 | if (elt.id.substring(split, elt.id.length) == "-expanded") | ||
1120 | 167 | if (num_lines(elt.innerHTML) > min_lines) | ||
1121 | 168 | collapse(elt.id.substring(0, split)); | ||
1122 | 169 | } | ||
1123 | 170 | } | ||
1124 | 171 | |||
1125 | 172 | function expandto(href) { | ||
1126 | 173 | var start = href.indexOf("#")+1; | ||
1127 | 174 | if (start != 0 && start != href.length) { | ||
1128 | 175 | if (href.substring(start, href.length) != "-") { | ||
1129 | 176 | collapse_all(4); | ||
1130 | 177 | pos = href.indexOf(".", start); | ||
1131 | 178 | while (pos != -1) { | ||
1132 | 179 | var id = href.substring(start, pos); | ||
1133 | 180 | expand(id); | ||
1134 | 181 | pos = href.indexOf(".", pos+1); | ||
1135 | 182 | } | ||
1136 | 183 | var id = href.substring(start, href.length); | ||
1137 | 184 | expand(id); | ||
1138 | 185 | highlight(id); | ||
1139 | 186 | } | ||
1140 | 187 | } | ||
1141 | 188 | } | ||
1142 | 189 | |||
1143 | 190 | function kill_doclink(id) { | ||
1144 | 191 | var parent = document.getElementById(id); | ||
1145 | 192 | parent.removeChild(parent.childNodes.item(0)); | ||
1146 | 193 | } | ||
1147 | 194 | function auto_kill_doclink(ev) { | ||
1148 | 195 | if (!ev) var ev = window.event; | ||
1149 | 196 | if (!this.contains(ev.toElement)) { | ||
1150 | 197 | var parent = document.getElementById(this.parentID); | ||
1151 | 198 | parent.removeChild(parent.childNodes.item(0)); | ||
1152 | 199 | } | ||
1153 | 200 | } | ||
1154 | 201 | |||
1155 | 202 | function doclink(id, name, targets_id) { | ||
1156 | 203 | var elt = document.getElementById(id); | ||
1157 | 204 | |||
1158 | 205 | // If we already opened the box, then destroy it. | ||
1159 | 206 | // (This case should never occur, but leave it in just in case.) | ||
1160 | 207 | if (elt.childNodes.length > 1) { | ||
1161 | 208 | elt.removeChild(elt.childNodes.item(0)); | ||
1162 | 209 | } | ||
1163 | 210 | else { | ||
1164 | 211 | // The outer box: relative + inline positioning. | ||
1165 | 212 | var box1 = document.createElement("div"); | ||
1166 | 213 | box1.style.position = "relative"; | ||
1167 | 214 | box1.style.display = "inline"; | ||
1168 | 215 | box1.style.top = 0; | ||
1169 | 216 | box1.style.left = 0; | ||
1170 | 217 | |||
1171 | 218 | // A shadow for fun | ||
1172 | 219 | var shadow = document.createElement("div"); | ||
1173 | 220 | shadow.style.position = "absolute"; | ||
1174 | 221 | shadow.style.left = "-1.3em"; | ||
1175 | 222 | shadow.style.top = "-1.3em"; | ||
1176 | 223 | shadow.style.background = "#404040"; | ||
1177 | 224 | |||
1178 | 225 | // The inner box: absolute positioning. | ||
1179 | 226 | var box2 = document.createElement("div"); | ||
1180 | 227 | box2.style.position = "relative"; | ||
1181 | 228 | box2.style.border = "1px solid #a0a0a0"; | ||
1182 | 229 | box2.style.left = "-.2em"; | ||
1183 | 230 | box2.style.top = "-.2em"; | ||
1184 | 231 | box2.style.background = "white"; | ||
1185 | 232 | box2.style.padding = ".3em .4em .3em .4em"; | ||
1186 | 233 | box2.style.fontStyle = "normal"; | ||
1187 | 234 | box2.onmouseout=auto_kill_doclink; | ||
1188 | 235 | box2.parentID = id; | ||
1189 | 236 | |||
1190 | 237 | // Get the targets | ||
1191 | 238 | var targets_elt = document.getElementById(targets_id); | ||
1192 | 239 | var targets = targets_elt.getAttribute("targets"); | ||
1193 | 240 | var links = ""; | ||
1194 | 241 | target_list = targets.split(","); | ||
1195 | 242 | for (var i=0; i<target_list.length; i++) { | ||
1196 | 243 | var target = target_list[i].split("="); | ||
1197 | 244 | links += "<li><a href='" + target[1] + | ||
1198 | 245 | "' style='text-decoration:none'>" + | ||
1199 | 246 | target[0] + "</a></li>"; | ||
1200 | 247 | } | ||
1201 | 248 | |||
1202 | 249 | // Put it all together. | ||
1203 | 250 | elt.insertBefore(box1, elt.childNodes.item(0)); | ||
1204 | 251 | //box1.appendChild(box2); | ||
1205 | 252 | box1.appendChild(shadow); | ||
1206 | 253 | shadow.appendChild(box2); | ||
1207 | 254 | box2.innerHTML = | ||
1208 | 255 | "Which <b>"+name+"</b> do you want to see documentation for?" + | ||
1209 | 256 | "<ul style='margin-bottom: 0;'>" + | ||
1210 | 257 | links + | ||
1211 | 258 | "<li><a href='#' style='text-decoration:none' " + | ||
1212 | 259 | "onclick='kill_doclink(\""+id+"\");return false;'>"+ | ||
1213 | 260 | "<i>None of the above</i></a></li></ul>"; | ||
1214 | 261 | } | ||
1215 | 262 | return false; | ||
1216 | 263 | } | ||
1217 | 264 | |||
1218 | 265 | function get_anchor() { | ||
1219 | 266 | var href = location.href; | ||
1220 | 267 | var start = href.indexOf("#")+1; | ||
1221 | 268 | if ((start != 0) && (start != href.length)) | ||
1222 | 269 | return href.substring(start, href.length); | ||
1223 | 270 | } | ||
1224 | 271 | function redirect_url(dottedName) { | ||
1225 | 272 | // Scan through each element of the "pages" list, and check | ||
1226 | 273 | // if "name" matches with any of them. | ||
1227 | 274 | for (var i=0; i<pages.length; i++) { | ||
1228 | 275 | |||
1229 | 276 | // Each page has the form "<pagename>-m" or "<pagename>-c"; | ||
1230 | 277 | // extract the <pagename> portion & compare it to dottedName. | ||
1231 | 278 | var pagename = pages[i].substring(0, pages[i].length-2); | ||
1232 | 279 | if (pagename == dottedName.substring(0,pagename.length)) { | ||
1233 | 280 | |||
1234 | 281 | // We've found a page that matches `dottedName`; | ||
1235 | 282 | // construct its URL, using leftover `dottedName` | ||
1236 | 283 | // content to form an anchor. | ||
1237 | 284 | var pagetype = pages[i].charAt(pages[i].length-1); | ||
1238 | 285 | var url = pagename + ((pagetype=="m")?"-module.html": | ||
1239 | 286 | "-class.html"); | ||
1240 | 287 | if (dottedName.length > pagename.length) | ||
1241 | 288 | url += "#" + dottedName.substring(pagename.length+1, | ||
1242 | 289 | dottedName.length); | ||
1243 | 290 | return url; | ||
1244 | 291 | } | ||
1245 | 292 | } | ||
1246 | 293 | } | ||
1247 | 0 | 294 | ||
1248 | === removed file 'doc/html/epydoc.js' | |||
1249 | --- doc/html/epydoc.js 2009-12-26 20:49:38 +0000 | |||
1250 | +++ doc/html/epydoc.js 1970-01-01 00:00:00 +0000 | |||
1251 | @@ -1,280 +0,0 @@ | |||
1252 | 1 | function toggle_private() { | ||
1253 | 2 | // Search for any private/public links on this page. Store | ||
1254 | 3 | // their old text in "cmd," so we will know what action to | ||
1255 | 4 | // take; and change their text to the opposite action. | ||
1256 | 5 | var cmd = "?"; | ||
1257 | 6 | var elts = document.getElementsByTagName("a"); | ||
1258 | 7 | for(var i=0; i<elts.length; i++) { | ||
1259 | 8 | if (elts[i].className == "privatelink") { | ||
1260 | 9 | cmd = elts[i].innerHTML; | ||
1261 | 10 | elts[i].innerHTML = ((cmd && cmd.substr(0,4)=="show")? | ||
1262 | 11 | "hide private":"show private"); | ||
1263 | 12 | } | ||
1264 | 13 | } | ||
1265 | 14 | // Update all DIVs containing private objects. | ||
1266 | 15 | var elts = document.getElementsByTagName("div"); | ||
1267 | 16 | for(var i=0; i<elts.length; i++) { | ||
1268 | 17 | if (elts[i].className == "private") { | ||
1269 | 18 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")?"none":"block"); | ||
1270 | 19 | } | ||
1271 | 20 | } | ||
1272 | 21 | // Update all table rowss containing private objects. Note, we | ||
1273 | 22 | // use "" instead of "block" becaue IE & firefox disagree on what | ||
1274 | 23 | // this should be (block vs table-row), and "" just gives the | ||
1275 | 24 | // default for both browsers. | ||
1276 | 25 | var elts = document.getElementsByTagName("tr"); | ||
1277 | 26 | for(var i=0; i<elts.length; i++) { | ||
1278 | 27 | if (elts[i].className == "private") { | ||
1279 | 28 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")?"none":""); | ||
1280 | 29 | } | ||
1281 | 30 | } | ||
1282 | 31 | // Update all list items containing private objects. | ||
1283 | 32 | var elts = document.getElementsByTagName("li"); | ||
1284 | 33 | for(var i=0; i<elts.length; i++) { | ||
1285 | 34 | if (elts[i].className == "private") { | ||
1286 | 35 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")? | ||
1287 | 36 | "none":"list-item"); | ||
1288 | 37 | } | ||
1289 | 38 | } | ||
1290 | 39 | // Update all list items containing private objects. | ||
1291 | 40 | var elts = document.getElementsByTagName("ul"); | ||
1292 | 41 | for(var i=0; i<elts.length; i++) { | ||
1293 | 42 | if (elts[i].className == "private") { | ||
1294 | 43 | elts[i].style.display = ((cmd && cmd.substr(0,4)=="hide")?"none":"block"); | ||
1295 | 44 | } | ||
1296 | 45 | } | ||
1297 | 46 | // Set a cookie to remember the current option. | ||
1298 | 47 | document.cookie = "EpydocPrivate="+cmd; | ||
1299 | 48 | } | ||
1300 | 49 | function getCookie(name) { | ||
1301 | 50 | var dc = document.cookie; | ||
1302 | 51 | var prefix = name + "="; | ||
1303 | 52 | var begin = dc.indexOf("; " + prefix); | ||
1304 | 53 | if (begin == -1) { | ||
1305 | 54 | begin = dc.indexOf(prefix); | ||
1306 | 55 | if (begin != 0) return null; | ||
1307 | 56 | } else | ||
1308 | 57 | { begin += 2; } | ||
1309 | 58 | var end = document.cookie.indexOf(";", begin); | ||
1310 | 59 | if (end == -1) | ||
1311 | 60 | { end = dc.length; } | ||
1312 | 61 | return unescape(dc.substring(begin + prefix.length, end)); | ||
1313 | 62 | } | ||
1314 | 63 | function setFrame(url1, url2) { | ||
1315 | 64 | parent.frames[1].location.href = url1; | ||
1316 | 65 | parent.frames[2].location.href = url2; | ||
1317 | 66 | } | ||
1318 | 67 | function checkCookie() { | ||
1319 | 68 | var cmd=getCookie("EpydocPrivate"); | ||
1320 | 69 | if (cmd && cmd.substr(0,4)!="show" && location.href.indexOf("#_") < 0) | ||
1321 | 70 | toggle_private(); | ||
1322 | 71 | } | ||
1323 | 72 | function toggleCallGraph(id) { | ||
1324 | 73 | var elt = document.getElementById(id); | ||
1325 | 74 | if (elt.style.display == "none") | ||
1326 | 75 | elt.style.display = "block"; | ||
1327 | 76 | else | ||
1328 | 77 | elt.style.display = "none"; | ||
1329 | 78 | } | ||
1330 | 79 | function expand(id) { | ||
1331 | 80 | var elt = document.getElementById(id+"-expanded"); | ||
1332 | 81 | if (elt) elt.style.display = "block"; | ||
1333 | 82 | var elt = document.getElementById(id+"-expanded-linenums"); | ||
1334 | 83 | if (elt) elt.style.display = "block"; | ||
1335 | 84 | var elt = document.getElementById(id+"-collapsed"); | ||
1336 | 85 | if (elt) { elt.innerHTML = ""; elt.style.display = "none"; } | ||
1337 | 86 | var elt = document.getElementById(id+"-collapsed-linenums"); | ||
1338 | 87 | if (elt) { elt.innerHTML = ""; elt.style.display = "none"; } | ||
1339 | 88 | var elt = document.getElementById(id+"-toggle"); | ||
1340 | 89 | if (elt) { elt.innerHTML = "-"; } | ||
1341 | 90 | } | ||
1342 | 91 | |||
1343 | 92 | function collapse(id) { | ||
1344 | 93 | var elt = document.getElementById(id+"-expanded"); | ||
1345 | 94 | if (elt) elt.style.display = "none"; | ||
1346 | 95 | var elt = document.getElementById(id+"-expanded-linenums"); | ||
1347 | 96 | if (elt) elt.style.display = "none"; | ||
1348 | 97 | var elt = document.getElementById(id+"-collapsed-linenums"); | ||
1349 | 98 | if (elt) { elt.innerHTML = "<br/>"; elt.style.display="block"; } | ||
1350 | 99 | var elt = document.getElementById(id+"-toggle"); | ||
1351 | 100 | if (elt) { elt.innerHTML = "+"; } | ||
1352 | 101 | var elt = document.getElementById(id+"-collapsed"); | ||
1353 | 102 | if (elt) { | ||
1354 | 103 | elt.style.display = "block"; | ||
1355 | 104 | |||
1356 | 105 | var indent = elt.getAttribute("indent"); | ||
1357 | 106 | var pad = elt.getAttribute("pad"); | ||
1358 | 107 | var s = "<tt class='py-lineno'>"; | ||
1359 | 108 | for (var i=0; i<pad.length; i++) { s += " " } | ||
1360 | 109 | s += "</tt>"; | ||
1361 | 110 | s += " <tt class='py-line'>"; | ||
1362 | 111 | for (var i=0; i<indent.length; i++) { s += " " } | ||
1363 | 112 | s += "<a href='#' onclick='expand(\"" + id; | ||
1364 | 113 | s += "\");return false'>...</a></tt><br />"; | ||
1365 | 114 | elt.innerHTML = s; | ||
1366 | 115 | } | ||
1367 | 116 | } | ||
1368 | 117 | |||
1369 | 118 | function toggle(id) { | ||
1370 | 119 | elt = document.getElementById(id+"-toggle"); | ||
1371 | 120 | if (elt.innerHTML == "-") | ||
1372 | 121 | collapse(id); | ||
1373 | 122 | else | ||
1374 | 123 | expand(id); | ||
1375 | 124 | return false; | ||
1376 | 125 | } | ||
1377 | 126 | |||
1378 | 127 | function highlight(id) { | ||
1379 | 128 | var elt = document.getElementById(id+"-def"); | ||
1380 | 129 | if (elt) elt.className = "py-highlight-hdr"; | ||
1381 | 130 | var elt = document.getElementById(id+"-expanded"); | ||
1382 | 131 | if (elt) elt.className = "py-highlight"; | ||
1383 | 132 | var elt = document.getElementById(id+"-collapsed"); | ||
1384 | 133 | if (elt) elt.className = "py-highlight"; | ||
1385 | 134 | } | ||
1386 | 135 | |||
1387 | 136 | function num_lines(s) { | ||
1388 | 137 | var n = 1; | ||
1389 | 138 | var pos = s.indexOf("\n"); | ||
1390 | 139 | while ( pos > 0) { | ||
1391 | 140 | n += 1; | ||
1392 | 141 | pos = s.indexOf("\n", pos+1); | ||
1393 | 142 | } | ||
1394 | 143 | return n; | ||
1395 | 144 | } | ||
1396 | 145 | |||
1397 | 146 | // Collapse all blocks that mave more than `min_lines` lines. | ||
1398 | 147 | function collapse_all(min_lines) { | ||
1399 | 148 | var elts = document.getElementsByTagName("div"); | ||
1400 | 149 | for (var i=0; i<elts.length; i++) { | ||
1401 | 150 | var elt = elts[i]; | ||
1402 | 151 | var split = elt.id.indexOf("-"); | ||
1403 | 152 | if (split > 0) | ||
1404 | 153 | if (elt.id.substring(split, elt.id.length) == "-expanded") | ||
1405 | 154 | if (num_lines(elt.innerHTML) > min_lines) | ||
1406 | 155 | collapse(elt.id.substring(0, split)); | ||
1407 | 156 | } | ||
1408 | 157 | } | ||
1409 | 158 | |||
1410 | 159 | function expandto(href) { | ||
1411 | 160 | var start = href.indexOf("#")+1; | ||
1412 | 161 | if (start != 0 && start != href.length) { | ||
1413 | 162 | if (href.substring(start, href.length) != "-") { | ||
1414 | 163 | collapse_all(4); | ||
1415 | 164 | pos = href.indexOf(".", start); | ||
1416 | 165 | while (pos != -1) { | ||
1417 | 166 | var id = href.substring(start, pos); | ||
1418 | 167 | expand(id); | ||
1419 | 168 | pos = href.indexOf(".", pos+1); | ||
1420 | 169 | } | ||
1421 | 170 | var id = href.substring(start, href.length); | ||
1422 | 171 | expand(id); | ||
1423 | 172 | highlight(id); | ||
1424 | 173 | } | ||
1425 | 174 | } | ||
1426 | 175 | } | ||
1427 | 176 | |||
1428 | 177 | function kill_doclink(id) { | ||
1429 | 178 | var parent = document.getElementById(id); | ||
1430 | 179 | parent.removeChild(parent.childNodes.item(0)); | ||
1431 | 180 | } | ||
1432 | 181 | function auto_kill_doclink(ev) { | ||
1433 | 182 | if (!ev) var ev = window.event; | ||
1434 | 183 | if (!this.contains(ev.toElement)) { | ||
1435 | 184 | var parent = document.getElementById(this.parentID); | ||
1436 | 185 | parent.removeChild(parent.childNodes.item(0)); | ||
1437 | 186 | } | ||
1438 | 187 | } | ||
1439 | 188 | |||
1440 | 189 | function doclink(id, name, targets_id) { | ||
1441 | 190 | var elt = document.getElementById(id); | ||
1442 | 191 | |||
1443 | 192 | // If we already opened the box, then destroy it. | ||
1444 | 193 | // (This case should never occur, but leave it in just in case.) | ||
1445 | 194 | if (elt.childNodes.length > 1) { | ||
1446 | 195 | elt.removeChild(elt.childNodes.item(0)); | ||
1447 | 196 | } | ||
1448 | 197 | else { | ||
1449 | 198 | // The outer box: relative + inline positioning. | ||
1450 | 199 | var box1 = document.createElement("div"); | ||
1451 | 200 | box1.style.position = "relative"; | ||
1452 | 201 | box1.style.display = "inline"; | ||
1453 | 202 | box1.style.top = 0; | ||
1454 | 203 | box1.style.left = 0; | ||
1455 | 204 | |||
1456 | 205 | // A shadow for fun | ||
1457 | 206 | var shadow = document.createElement("div"); | ||
1458 | 207 | shadow.style.position = "absolute"; | ||
1459 | 208 | shadow.style.left = "-1.3em"; | ||
1460 | 209 | shadow.style.top = "-1.3em"; | ||
1461 | 210 | shadow.style.background = "#404040"; | ||
1462 | 211 | |||
1463 | 212 | // The inner box: absolute positioning. | ||
1464 | 213 | var box2 = document.createElement("div"); | ||
1465 | 214 | box2.style.position = "relative"; | ||
1466 | 215 | box2.style.border = "1px solid #a0a0a0"; | ||
1467 | 216 | box2.style.left = "-.2em"; | ||
1468 | 217 | box2.style.top = "-.2em"; | ||
1469 | 218 | box2.style.background = "white"; | ||
1470 | 219 | box2.style.padding = ".3em .4em .3em .4em"; | ||
1471 | 220 | box2.style.fontStyle = "normal"; | ||
1472 | 221 | box2.onmouseout=auto_kill_doclink; | ||
1473 | 222 | box2.parentID = id; | ||
1474 | 223 | |||
1475 | 224 | // Get the targets | ||
1476 | 225 | var targets_elt = document.getElementById(targets_id); | ||
1477 | 226 | var targets = targets_elt.getAttribute("targets"); | ||
1478 | 227 | var links = ""; | ||
1479 | 228 | target_list = targets.split(","); | ||
1480 | 229 | for (var i=0; i<target_list.length; i++) { | ||
1481 | 230 | var target = target_list[i].split("="); | ||
1482 | 231 | links += "<li><a href='" + target[1] + | ||
1483 | 232 | "' style='text-decoration:none'>" + | ||
1484 | 233 | target[0] + "</a></li>"; | ||
1485 | 234 | } | ||
1486 | 235 | |||
1487 | 236 | // Put it all together. | ||
1488 | 237 | elt.insertBefore(box1, elt.childNodes.item(0)); | ||
1489 | 238 | //box1.appendChild(box2); | ||
1490 | 239 | box1.appendChild(shadow); | ||
1491 | 240 | shadow.appendChild(box2); | ||
1492 | 241 | box2.innerHTML = | ||
1493 | 242 | "Which <b>"+name+"</b> do you want to see documentation for?" + | ||
1494 | 243 | "<ul style='margin-bottom: 0;'>" + | ||
1495 | 244 | links + | ||
1496 | 245 | "<li><a href='#' style='text-decoration:none' " + | ||
1497 | 246 | "onclick='kill_doclink(\""+id+"\");return false;'>"+ | ||
1498 | 247 | "<i>None of the above</i></a></li></ul>"; | ||
1499 | 248 | } | ||
1500 | 249 | return false; | ||
1501 | 250 | } | ||
1502 | 251 | |||
1503 | 252 | function get_anchor() { | ||
1504 | 253 | var href = location.href; | ||
1505 | 254 | var start = href.indexOf("#")+1; | ||
1506 | 255 | if ((start != 0) && (start != href.length)) | ||
1507 | 256 | return href.substring(start, href.length); | ||
1508 | 257 | } | ||
1509 | 258 | function redirect_url(dottedName) { | ||
1510 | 259 | // Scan through each element of the "pages" list, and check | ||
1511 | 260 | // if "name" matches with any of them. | ||
1512 | 261 | for (var i=0; i<pages.length; i++) { | ||
1513 | 262 | |||
1514 | 263 | // Each page has the form "<pagename>-m" or "<pagename>-c"; | ||
1515 | 264 | // extract the <pagename> portion & compare it to dottedName. | ||
1516 | 265 | var pagename = pages[i].substring(0, pages[i].length-2); | ||
1517 | 266 | if (pagename == dottedName.substring(0,pagename.length)) { | ||
1518 | 267 | |||
1519 | 268 | // We've found a page that matches `dottedName`; | ||
1520 | 269 | // construct its URL, using leftover `dottedName` | ||
1521 | 270 | // content to form an anchor. | ||
1522 | 271 | var pagetype = pages[i].charAt(pages[i].length-1); | ||
1523 | 272 | var url = pagename + ((pagetype=="m")?"-module.html": | ||
1524 | 273 | "-class.html"); | ||
1525 | 274 | if (dottedName.length > pagename.length) | ||
1526 | 275 | url += "#" + dottedName.substring(pagename.length+1, | ||
1527 | 276 | dottedName.length); | ||
1528 | 277 | return url; | ||
1529 | 278 | } | ||
1530 | 279 | } | ||
1531 | 280 | } | ||
1532 | 281 | 0 | ||
1533 | === added file 'doc/html/frames.html' | |||
1534 | --- doc/html/frames.html 1970-01-01 00:00:00 +0000 | |||
1535 | +++ doc/html/frames.html 2009-12-26 22:06:14 +0000 | |||
1536 | @@ -0,0 +1,17 @@ | |||
1537 | 1 | <?xml version="1.0" encoding="iso-8859-1"?> | ||
1538 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" | ||
1539 | 3 | "DTD/xhtml1-frameset.dtd"> | ||
1540 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
1541 | 5 | <head> | ||
1542 | 6 | <title> API Documentation </title> | ||
1543 | 7 | </head> | ||
1544 | 8 | <frameset cols="20%,80%"> | ||
1545 | 9 | <frameset rows="30%,70%"> | ||
1546 | 10 | <frame src="toc.html" name="moduleListFrame" | ||
1547 | 11 | id="moduleListFrame" /> | ||
1548 | 12 | <frame src="toc-everything.html" name="moduleFrame" | ||
1549 | 13 | id="moduleFrame" /> | ||
1550 | 14 | </frameset> | ||
1551 | 15 | <frame src="scriptutil-module.html" name="mainFrame" id="mainFrame" /> | ||
1552 | 16 | </frameset> | ||
1553 | 17 | </html> | ||
1554 | 0 | 18 | ||
1555 | === removed file 'doc/html/frames.html' | |||
1556 | --- doc/html/frames.html 2009-12-26 20:49:38 +0000 | |||
1557 | +++ doc/html/frames.html 1970-01-01 00:00:00 +0000 | |||
1558 | @@ -1,17 +0,0 @@ | |||
1559 | 1 | <?xml version="1.0" encoding="iso-8859-1"?> | ||
1560 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" | ||
1561 | 3 | "DTD/xhtml1-frameset.dtd"> | ||
1562 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
1563 | 5 | <head> | ||
1564 | 6 | <title> Module scriptutil </title> | ||
1565 | 7 | </head> | ||
1566 | 8 | <frameset cols="20%,80%"> | ||
1567 | 9 | <frameset rows="30%,70%"> | ||
1568 | 10 | <frame src="toc.html" name="moduleListFrame" | ||
1569 | 11 | id="moduleListFrame" /> | ||
1570 | 12 | <frame src="toc-everything.html" name="moduleFrame" | ||
1571 | 13 | id="moduleFrame" /> | ||
1572 | 14 | </frameset> | ||
1573 | 15 | <frame src="scriptutil-module.html" name="mainFrame" id="mainFrame" /> | ||
1574 | 16 | </frameset> | ||
1575 | 17 | </html> | ||
1576 | 18 | 0 | ||
1577 | === added file 'doc/html/help.html' | |||
1578 | --- doc/html/help.html 1970-01-01 00:00:00 +0000 | |||
1579 | +++ doc/html/help.html 2009-12-26 22:06:14 +0000 | |||
1580 | @@ -0,0 +1,278 @@ | |||
1581 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
1582 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
1583 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
1584 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
1585 | 5 | <head> | ||
1586 | 6 | <title>Help</title> | ||
1587 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
1588 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
1589 | 9 | </head> | ||
1590 | 10 | |||
1591 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
1592 | 12 | alink="#204080"> | ||
1593 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
1594 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
1595 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
1596 | 16 | <tr valign="middle"> | ||
1597 | 17 | <!-- Home link --> | ||
1598 | 18 | <th> <a | ||
1599 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
1600 | 20 | |||
1601 | 21 | <!-- Tree link --> | ||
1602 | 22 | <th> <a | ||
1603 | 23 | href="module-tree.html">Trees</a> </th> | ||
1604 | 24 | |||
1605 | 25 | <!-- Index link --> | ||
1606 | 26 | <th> <a | ||
1607 | 27 | href="identifier-index.html">Indices</a> </th> | ||
1608 | 28 | |||
1609 | 29 | <!-- Help link --> | ||
1610 | 30 | <th bgcolor="#70b0f0" class="navbar-select" | ||
1611 | 31 | > Help </th> | ||
1612 | 32 | |||
1613 | 33 | <!-- Project homepage --> | ||
1614 | 34 | <th class="navbar" align="right" width="100%"> | ||
1615 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
1616 | 36 | <tr><th class="navbar" align="center" | ||
1617 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
1618 | 38 | </tr></table></th> | ||
1619 | 39 | </tr> | ||
1620 | 40 | </table> | ||
1621 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
1622 | 42 | <tr valign="top"> | ||
1623 | 43 | <td width="100%"> </td> | ||
1624 | 44 | <td> | ||
1625 | 45 | <table cellpadding="0" cellspacing="0"> | ||
1626 | 46 | <!-- hide/show private --> | ||
1627 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
1628 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
1629 | 49 | <tr><td align="right"><span class="options" | ||
1630 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
1631 | 51 | >] | <a href="help.html" | ||
1632 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
1633 | 53 | </table> | ||
1634 | 54 | </td> | ||
1635 | 55 | </tr> | ||
1636 | 56 | </table> | ||
1637 | 57 | |||
1638 | 58 | <h1 class="epydoc"> API Documentation </h1> | ||
1639 | 59 | |||
1640 | 60 | <p> This document contains the API (Application Programming Interface) | ||
1641 | 61 | documentation for this project. Documentation for the Python | ||
1642 | 62 | objects defined by the project is divided into separate pages for each | ||
1643 | 63 | package, module, and class. The API documentation also includes two | ||
1644 | 64 | pages containing information about the project as a whole: a trees | ||
1645 | 65 | page, and an index page. </p> | ||
1646 | 66 | |||
1647 | 67 | <h2> Object Documentation </h2> | ||
1648 | 68 | |||
1649 | 69 | <p>Each <strong>Package Documentation</strong> page contains: </p> | ||
1650 | 70 | <ul> | ||
1651 | 71 | <li> A description of the package. </li> | ||
1652 | 72 | <li> A list of the modules and sub-packages contained by the | ||
1653 | 73 | package. </li> | ||
1654 | 74 | <li> A summary of the classes defined by the package. </li> | ||
1655 | 75 | <li> A summary of the functions defined by the package. </li> | ||
1656 | 76 | <li> A summary of the variables defined by the package. </li> | ||
1657 | 77 | <li> A detailed description of each function defined by the | ||
1658 | 78 | package. </li> | ||
1659 | 79 | <li> A detailed description of each variable defined by the | ||
1660 | 80 | package. </li> | ||
1661 | 81 | </ul> | ||
1662 | 82 | |||
1663 | 83 | <p>Each <strong>Module Documentation</strong> page contains:</p> | ||
1664 | 84 | <ul> | ||
1665 | 85 | <li> A description of the module. </li> | ||
1666 | 86 | <li> A summary of the classes defined by the module. </li> | ||
1667 | 87 | <li> A summary of the functions defined by the module. </li> | ||
1668 | 88 | <li> A summary of the variables defined by the module. </li> | ||
1669 | 89 | <li> A detailed description of each function defined by the | ||
1670 | 90 | module. </li> | ||
1671 | 91 | <li> A detailed description of each variable defined by the | ||
1672 | 92 | module. </li> | ||
1673 | 93 | </ul> | ||
1674 | 94 | |||
1675 | 95 | <p>Each <strong>Class Documentation</strong> page contains: </p> | ||
1676 | 96 | <ul> | ||
1677 | 97 | <li> A class inheritance diagram. </li> | ||
1678 | 98 | <li> A list of known subclasses. </li> | ||
1679 | 99 | <li> A description of the class. </li> | ||
1680 | 100 | <li> A summary of the methods defined by the class. </li> | ||
1681 | 101 | <li> A summary of the instance variables defined by the class. </li> | ||
1682 | 102 | <li> A summary of the class (static) variables defined by the | ||
1683 | 103 | class. </li> | ||
1684 | 104 | <li> A detailed description of each method defined by the | ||
1685 | 105 | class. </li> | ||
1686 | 106 | <li> A detailed description of each instance variable defined by the | ||
1687 | 107 | class. </li> | ||
1688 | 108 | <li> A detailed description of each class (static) variable defined | ||
1689 | 109 | by the class. </li> | ||
1690 | 110 | </ul> | ||
1691 | 111 | |||
1692 | 112 | <h2> Project Documentation </h2> | ||
1693 | 113 | |||
1694 | 114 | <p> The <strong>Trees</strong> page contains the module and class hierarchies: </p> | ||
1695 | 115 | <ul> | ||
1696 | 116 | <li> The <em>module hierarchy</em> lists every package and module, with | ||
1697 | 117 | modules grouped into packages. At the top level, and within each | ||
1698 | 118 | package, modules and sub-packages are listed alphabetically. </li> | ||
1699 | 119 | <li> The <em>class hierarchy</em> lists every class, grouped by base | ||
1700 | 120 | class. If a class has more than one base class, then it will be | ||
1701 | 121 | listed under each base class. At the top level, and under each base | ||
1702 | 122 | class, classes are listed alphabetically. </li> | ||
1703 | 123 | </ul> | ||
1704 | 124 | |||
1705 | 125 | <p> The <strong>Index</strong> page contains indices of terms and | ||
1706 | 126 | identifiers: </p> | ||
1707 | 127 | <ul> | ||
1708 | 128 | <li> The <em>term index</em> lists every term indexed by any object's | ||
1709 | 129 | documentation. For each term, the index provides links to each | ||
1710 | 130 | place where the term is indexed. </li> | ||
1711 | 131 | <li> The <em>identifier index</em> lists the (short) name of every package, | ||
1712 | 132 | module, class, method, function, variable, and parameter. For each | ||
1713 | 133 | identifier, the index provides a short description, and a link to | ||
1714 | 134 | its documentation. </li> | ||
1715 | 135 | </ul> | ||
1716 | 136 | |||
1717 | 137 | <h2> The Table of Contents </h2> | ||
1718 | 138 | |||
1719 | 139 | <p> The table of contents occupies the two frames on the left side of | ||
1720 | 140 | the window. The upper-left frame displays the <em>project | ||
1721 | 141 | contents</em>, and the lower-left frame displays the <em>module | ||
1722 | 142 | contents</em>: </p> | ||
1723 | 143 | |||
1724 | 144 | <table class="help summary" border="1" cellspacing="0" cellpadding="3"> | ||
1725 | 145 | <tr style="height: 30%"> | ||
1726 | 146 | <td align="center" style="font-size: small"> | ||
1727 | 147 | Project<br />Contents<hr />...</td> | ||
1728 | 148 | <td align="center" style="font-size: small" rowspan="2" width="70%"> | ||
1729 | 149 | API<br />Documentation<br />Frame<br /><br /><br /> | ||
1730 | 150 | </td> | ||
1731 | 151 | </tr> | ||
1732 | 152 | <tr> | ||
1733 | 153 | <td align="center" style="font-size: small"> | ||
1734 | 154 | Module<br />Contents<hr /> <br />...<br /> | ||
1735 | 155 | </td> | ||
1736 | 156 | </tr> | ||
1737 | 157 | </table><br /> | ||
1738 | 158 | |||
1739 | 159 | <p> The <strong>project contents frame</strong> contains a list of all packages | ||
1740 | 160 | and modules that are defined by the project. Clicking on an entry | ||
1741 | 161 | will display its contents in the module contents frame. Clicking on a | ||
1742 | 162 | special entry, labeled "Everything," will display the contents of | ||
1743 | 163 | the entire project. </p> | ||
1744 | 164 | |||
1745 | 165 | <p> The <strong>module contents frame</strong> contains a list of every | ||
1746 | 166 | submodule, class, type, exception, function, and variable defined by a | ||
1747 | 167 | module or package. Clicking on an entry will display its | ||
1748 | 168 | documentation in the API documentation frame. Clicking on the name of | ||
1749 | 169 | the module, at the top of the frame, will display the documentation | ||
1750 | 170 | for the module itself. </p> | ||
1751 | 171 | |||
1752 | 172 | <p> The "<strong>frames</strong>" and "<strong>no frames</strong>" buttons below the top | ||
1753 | 173 | navigation bar can be used to control whether the table of contents is | ||
1754 | 174 | displayed or not. </p> | ||
1755 | 175 | |||
1756 | 176 | <h2> The Navigation Bar </h2> | ||
1757 | 177 | |||
1758 | 178 | <p> A navigation bar is located at the top and bottom of every page. | ||
1759 | 179 | It indicates what type of page you are currently viewing, and allows | ||
1760 | 180 | you to go to related pages. The following table describes the labels | ||
1761 | 181 | on the navigation bar. Note that not some labels (such as | ||
1762 | 182 | [Parent]) are not displayed on all pages. </p> | ||
1763 | 183 | |||
1764 | 184 | <table class="summary" border="1" cellspacing="0" cellpadding="3" width="100%"> | ||
1765 | 185 | <tr class="summary"> | ||
1766 | 186 | <th>Label</th> | ||
1767 | 187 | <th>Highlighted when...</th> | ||
1768 | 188 | <th>Links to...</th> | ||
1769 | 189 | </tr> | ||
1770 | 190 | <tr><td valign="top"><strong>[Parent]</strong></td> | ||
1771 | 191 | <td valign="top"><em>(never highlighted)</em></td> | ||
1772 | 192 | <td valign="top"> the parent of the current package </td></tr> | ||
1773 | 193 | <tr><td valign="top"><strong>[Package]</strong></td> | ||
1774 | 194 | <td valign="top">viewing a package</td> | ||
1775 | 195 | <td valign="top">the package containing the current object | ||
1776 | 196 | </td></tr> | ||
1777 | 197 | <tr><td valign="top"><strong>[Module]</strong></td> | ||
1778 | 198 | <td valign="top">viewing a module</td> | ||
1779 | 199 | <td valign="top">the module containing the current object | ||
1780 | 200 | </td></tr> | ||
1781 | 201 | <tr><td valign="top"><strong>[Class]</strong></td> | ||
1782 | 202 | <td valign="top">viewing a class </td> | ||
1783 | 203 | <td valign="top">the class containing the current object</td></tr> | ||
1784 | 204 | <tr><td valign="top"><strong>[Trees]</strong></td> | ||
1785 | 205 | <td valign="top">viewing the trees page</td> | ||
1786 | 206 | <td valign="top"> the trees page </td></tr> | ||
1787 | 207 | <tr><td valign="top"><strong>[Index]</strong></td> | ||
1788 | 208 | <td valign="top">viewing the index page</td> | ||
1789 | 209 | <td valign="top"> the index page </td></tr> | ||
1790 | 210 | <tr><td valign="top"><strong>[Help]</strong></td> | ||
1791 | 211 | <td valign="top">viewing the help page</td> | ||
1792 | 212 | <td valign="top"> the help page </td></tr> | ||
1793 | 213 | </table> | ||
1794 | 214 | |||
1795 | 215 | <p> The "<strong>show private</strong>" and "<strong>hide private</strong>" buttons below | ||
1796 | 216 | the top navigation bar can be used to control whether documentation | ||
1797 | 217 | for private objects is displayed. Private objects are usually defined | ||
1798 | 218 | as objects whose (short) names begin with a single underscore, but do | ||
1799 | 219 | not end with an underscore. For example, "<code>_x</code>", | ||
1800 | 220 | "<code>__pprint</code>", and "<code>epydoc.epytext._tokenize</code>" | ||
1801 | 221 | are private objects; but "<code>re.sub</code>", | ||
1802 | 222 | "<code>__init__</code>", and "<code>type_</code>" are not. However, | ||
1803 | 223 | if a module defines the "<code>__all__</code>" variable, then its | ||
1804 | 224 | contents are used to decide which objects are private. </p> | ||
1805 | 225 | |||
1806 | 226 | <p> A timestamp below the bottom navigation bar indicates when each | ||
1807 | 227 | page was last updated. </p> | ||
1808 | 228 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
1809 | 229 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
1810 | 230 | bgcolor="#a0c0ff" cellspacing="0"> | ||
1811 | 231 | <tr valign="middle"> | ||
1812 | 232 | <!-- Home link --> | ||
1813 | 233 | <th> <a | ||
1814 | 234 | href="scriptutil-module.html">Home</a> </th> | ||
1815 | 235 | |||
1816 | 236 | <!-- Tree link --> | ||
1817 | 237 | <th> <a | ||
1818 | 238 | href="module-tree.html">Trees</a> </th> | ||
1819 | 239 | |||
1820 | 240 | <!-- Index link --> | ||
1821 | 241 | <th> <a | ||
1822 | 242 | href="identifier-index.html">Indices</a> </th> | ||
1823 | 243 | |||
1824 | 244 | <!-- Help link --> | ||
1825 | 245 | <th bgcolor="#70b0f0" class="navbar-select" | ||
1826 | 246 | > Help </th> | ||
1827 | 247 | |||
1828 | 248 | <!-- Project homepage --> | ||
1829 | 249 | <th class="navbar" align="right" width="100%"> | ||
1830 | 250 | <table border="0" cellpadding="0" cellspacing="0"> | ||
1831 | 251 | <tr><th class="navbar" align="center" | ||
1832 | 252 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
1833 | 253 | </tr></table></th> | ||
1834 | 254 | </tr> | ||
1835 | 255 | </table> | ||
1836 | 256 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
1837 | 257 | <tr> | ||
1838 | 258 | <td align="left" class="footer"> | ||
1839 | 259 | Generated by Epydoc 3.0.1 on Sat Dec 26 23:01:34 2009 | ||
1840 | 260 | </td> | ||
1841 | 261 | <td align="right" class="footer"> | ||
1842 | 262 | <a target="mainFrame" href="http://epydoc.sourceforge.net" | ||
1843 | 263 | >http://epydoc.sourceforge.net</a> | ||
1844 | 264 | </td> | ||
1845 | 265 | </tr> | ||
1846 | 266 | </table> | ||
1847 | 267 | |||
1848 | 268 | <script type="text/javascript"> | ||
1849 | 269 | <!-- | ||
1850 | 270 | // Private objects are initially displayed (because if | ||
1851 | 271 | // javascript is turned off then we want them to be | ||
1852 | 272 | // visible); but by default, we want to hide them. So hide | ||
1853 | 273 | // them unless we have a cookie that says to show them. | ||
1854 | 274 | checkCookie(); | ||
1855 | 275 | // --> | ||
1856 | 276 | </script> | ||
1857 | 277 | </body> | ||
1858 | 278 | </html> | ||
1859 | 0 | 279 | ||
1860 | === removed file 'doc/html/help.html' | |||
1861 | --- doc/html/help.html 2009-12-26 20:49:38 +0000 | |||
1862 | +++ doc/html/help.html 1970-01-01 00:00:00 +0000 | |||
1863 | @@ -1,278 +0,0 @@ | |||
1864 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
1865 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
1866 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
1867 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
1868 | 5 | <head> | ||
1869 | 6 | <title>Help</title> | ||
1870 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
1871 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
1872 | 9 | </head> | ||
1873 | 10 | |||
1874 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
1875 | 12 | alink="#204080"> | ||
1876 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
1877 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
1878 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
1879 | 16 | <tr valign="middle"> | ||
1880 | 17 | <!-- Home link --> | ||
1881 | 18 | <th> <a | ||
1882 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
1883 | 20 | |||
1884 | 21 | <!-- Tree link --> | ||
1885 | 22 | <th> <a | ||
1886 | 23 | href="module-tree.html">Trees</a> </th> | ||
1887 | 24 | |||
1888 | 25 | <!-- Index link --> | ||
1889 | 26 | <th> <a | ||
1890 | 27 | href="identifier-index.html">Indices</a> </th> | ||
1891 | 28 | |||
1892 | 29 | <!-- Help link --> | ||
1893 | 30 | <th bgcolor="#70b0f0" class="navbar-select" | ||
1894 | 31 | > Help </th> | ||
1895 | 32 | |||
1896 | 33 | <!-- Project homepage --> | ||
1897 | 34 | <th class="navbar" align="right" width="100%"> | ||
1898 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
1899 | 36 | <tr><th class="navbar" align="center" | ||
1900 | 37 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
1901 | 38 | </tr></table></th> | ||
1902 | 39 | </tr> | ||
1903 | 40 | </table> | ||
1904 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
1905 | 42 | <tr valign="top"> | ||
1906 | 43 | <td width="100%"> </td> | ||
1907 | 44 | <td> | ||
1908 | 45 | <table cellpadding="0" cellspacing="0"> | ||
1909 | 46 | <!-- hide/show private --> | ||
1910 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
1911 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
1912 | 49 | <tr><td align="right"><span class="options" | ||
1913 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
1914 | 51 | >] | <a href="help.html" | ||
1915 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
1916 | 53 | </table> | ||
1917 | 54 | </td> | ||
1918 | 55 | </tr> | ||
1919 | 56 | </table> | ||
1920 | 57 | |||
1921 | 58 | <h1 class="epydoc"> API Documentation </h1> | ||
1922 | 59 | |||
1923 | 60 | <p> This document contains the API (Application Programming Interface) | ||
1924 | 61 | documentation for Module scriptutil. Documentation for the Python | ||
1925 | 62 | objects defined by the project is divided into separate pages for each | ||
1926 | 63 | package, module, and class. The API documentation also includes two | ||
1927 | 64 | pages containing information about the project as a whole: a trees | ||
1928 | 65 | page, and an index page. </p> | ||
1929 | 66 | |||
1930 | 67 | <h2> Object Documentation </h2> | ||
1931 | 68 | |||
1932 | 69 | <p>Each <strong>Package Documentation</strong> page contains: </p> | ||
1933 | 70 | <ul> | ||
1934 | 71 | <li> A description of the package. </li> | ||
1935 | 72 | <li> A list of the modules and sub-packages contained by the | ||
1936 | 73 | package. </li> | ||
1937 | 74 | <li> A summary of the classes defined by the package. </li> | ||
1938 | 75 | <li> A summary of the functions defined by the package. </li> | ||
1939 | 76 | <li> A summary of the variables defined by the package. </li> | ||
1940 | 77 | <li> A detailed description of each function defined by the | ||
1941 | 78 | package. </li> | ||
1942 | 79 | <li> A detailed description of each variable defined by the | ||
1943 | 80 | package. </li> | ||
1944 | 81 | </ul> | ||
1945 | 82 | |||
1946 | 83 | <p>Each <strong>Module Documentation</strong> page contains:</p> | ||
1947 | 84 | <ul> | ||
1948 | 85 | <li> A description of the module. </li> | ||
1949 | 86 | <li> A summary of the classes defined by the module. </li> | ||
1950 | 87 | <li> A summary of the functions defined by the module. </li> | ||
1951 | 88 | <li> A summary of the variables defined by the module. </li> | ||
1952 | 89 | <li> A detailed description of each function defined by the | ||
1953 | 90 | module. </li> | ||
1954 | 91 | <li> A detailed description of each variable defined by the | ||
1955 | 92 | module. </li> | ||
1956 | 93 | </ul> | ||
1957 | 94 | |||
1958 | 95 | <p>Each <strong>Class Documentation</strong> page contains: </p> | ||
1959 | 96 | <ul> | ||
1960 | 97 | <li> A class inheritance diagram. </li> | ||
1961 | 98 | <li> A list of known subclasses. </li> | ||
1962 | 99 | <li> A description of the class. </li> | ||
1963 | 100 | <li> A summary of the methods defined by the class. </li> | ||
1964 | 101 | <li> A summary of the instance variables defined by the class. </li> | ||
1965 | 102 | <li> A summary of the class (static) variables defined by the | ||
1966 | 103 | class. </li> | ||
1967 | 104 | <li> A detailed description of each method defined by the | ||
1968 | 105 | class. </li> | ||
1969 | 106 | <li> A detailed description of each instance variable defined by the | ||
1970 | 107 | class. </li> | ||
1971 | 108 | <li> A detailed description of each class (static) variable defined | ||
1972 | 109 | by the class. </li> | ||
1973 | 110 | </ul> | ||
1974 | 111 | |||
1975 | 112 | <h2> Project Documentation </h2> | ||
1976 | 113 | |||
1977 | 114 | <p> The <strong>Trees</strong> page contains the module and class hierarchies: </p> | ||
1978 | 115 | <ul> | ||
1979 | 116 | <li> The <em>module hierarchy</em> lists every package and module, with | ||
1980 | 117 | modules grouped into packages. At the top level, and within each | ||
1981 | 118 | package, modules and sub-packages are listed alphabetically. </li> | ||
1982 | 119 | <li> The <em>class hierarchy</em> lists every class, grouped by base | ||
1983 | 120 | class. If a class has more than one base class, then it will be | ||
1984 | 121 | listed under each base class. At the top level, and under each base | ||
1985 | 122 | class, classes are listed alphabetically. </li> | ||
1986 | 123 | </ul> | ||
1987 | 124 | |||
1988 | 125 | <p> The <strong>Index</strong> page contains indices of terms and | ||
1989 | 126 | identifiers: </p> | ||
1990 | 127 | <ul> | ||
1991 | 128 | <li> The <em>term index</em> lists every term indexed by any object's | ||
1992 | 129 | documentation. For each term, the index provides links to each | ||
1993 | 130 | place where the term is indexed. </li> | ||
1994 | 131 | <li> The <em>identifier index</em> lists the (short) name of every package, | ||
1995 | 132 | module, class, method, function, variable, and parameter. For each | ||
1996 | 133 | identifier, the index provides a short description, and a link to | ||
1997 | 134 | its documentation. </li> | ||
1998 | 135 | </ul> | ||
1999 | 136 | |||
2000 | 137 | <h2> The Table of Contents </h2> | ||
2001 | 138 | |||
2002 | 139 | <p> The table of contents occupies the two frames on the left side of | ||
2003 | 140 | the window. The upper-left frame displays the <em>project | ||
2004 | 141 | contents</em>, and the lower-left frame displays the <em>module | ||
2005 | 142 | contents</em>: </p> | ||
2006 | 143 | |||
2007 | 144 | <table class="help summary" border="1" cellspacing="0" cellpadding="3"> | ||
2008 | 145 | <tr style="height: 30%"> | ||
2009 | 146 | <td align="center" style="font-size: small"> | ||
2010 | 147 | Project<br />Contents<hr />...</td> | ||
2011 | 148 | <td align="center" style="font-size: small" rowspan="2" width="70%"> | ||
2012 | 149 | API<br />Documentation<br />Frame<br /><br /><br /> | ||
2013 | 150 | </td> | ||
2014 | 151 | </tr> | ||
2015 | 152 | <tr> | ||
2016 | 153 | <td align="center" style="font-size: small"> | ||
2017 | 154 | Module<br />Contents<hr /> <br />...<br /> | ||
2018 | 155 | </td> | ||
2019 | 156 | </tr> | ||
2020 | 157 | </table><br /> | ||
2021 | 158 | |||
2022 | 159 | <p> The <strong>project contents frame</strong> contains a list of all packages | ||
2023 | 160 | and modules that are defined by the project. Clicking on an entry | ||
2024 | 161 | will display its contents in the module contents frame. Clicking on a | ||
2025 | 162 | special entry, labeled "Everything," will display the contents of | ||
2026 | 163 | the entire project. </p> | ||
2027 | 164 | |||
2028 | 165 | <p> The <strong>module contents frame</strong> contains a list of every | ||
2029 | 166 | submodule, class, type, exception, function, and variable defined by a | ||
2030 | 167 | module or package. Clicking on an entry will display its | ||
2031 | 168 | documentation in the API documentation frame. Clicking on the name of | ||
2032 | 169 | the module, at the top of the frame, will display the documentation | ||
2033 | 170 | for the module itself. </p> | ||
2034 | 171 | |||
2035 | 172 | <p> The "<strong>frames</strong>" and "<strong>no frames</strong>" buttons below the top | ||
2036 | 173 | navigation bar can be used to control whether the table of contents is | ||
2037 | 174 | displayed or not. </p> | ||
2038 | 175 | |||
2039 | 176 | <h2> The Navigation Bar </h2> | ||
2040 | 177 | |||
2041 | 178 | <p> A navigation bar is located at the top and bottom of every page. | ||
2042 | 179 | It indicates what type of page you are currently viewing, and allows | ||
2043 | 180 | you to go to related pages. The following table describes the labels | ||
2044 | 181 | on the navigation bar. Note that not some labels (such as | ||
2045 | 182 | [Parent]) are not displayed on all pages. </p> | ||
2046 | 183 | |||
2047 | 184 | <table class="summary" border="1" cellspacing="0" cellpadding="3" width="100%"> | ||
2048 | 185 | <tr class="summary"> | ||
2049 | 186 | <th>Label</th> | ||
2050 | 187 | <th>Highlighted when...</th> | ||
2051 | 188 | <th>Links to...</th> | ||
2052 | 189 | </tr> | ||
2053 | 190 | <tr><td valign="top"><strong>[Parent]</strong></td> | ||
2054 | 191 | <td valign="top"><em>(never highlighted)</em></td> | ||
2055 | 192 | <td valign="top"> the parent of the current package </td></tr> | ||
2056 | 193 | <tr><td valign="top"><strong>[Package]</strong></td> | ||
2057 | 194 | <td valign="top">viewing a package</td> | ||
2058 | 195 | <td valign="top">the package containing the current object | ||
2059 | 196 | </td></tr> | ||
2060 | 197 | <tr><td valign="top"><strong>[Module]</strong></td> | ||
2061 | 198 | <td valign="top">viewing a module</td> | ||
2062 | 199 | <td valign="top">the module containing the current object | ||
2063 | 200 | </td></tr> | ||
2064 | 201 | <tr><td valign="top"><strong>[Class]</strong></td> | ||
2065 | 202 | <td valign="top">viewing a class </td> | ||
2066 | 203 | <td valign="top">the class containing the current object</td></tr> | ||
2067 | 204 | <tr><td valign="top"><strong>[Trees]</strong></td> | ||
2068 | 205 | <td valign="top">viewing the trees page</td> | ||
2069 | 206 | <td valign="top"> the trees page </td></tr> | ||
2070 | 207 | <tr><td valign="top"><strong>[Index]</strong></td> | ||
2071 | 208 | <td valign="top">viewing the index page</td> | ||
2072 | 209 | <td valign="top"> the index page </td></tr> | ||
2073 | 210 | <tr><td valign="top"><strong>[Help]</strong></td> | ||
2074 | 211 | <td valign="top">viewing the help page</td> | ||
2075 | 212 | <td valign="top"> the help page </td></tr> | ||
2076 | 213 | </table> | ||
2077 | 214 | |||
2078 | 215 | <p> The "<strong>show private</strong>" and "<strong>hide private</strong>" buttons below | ||
2079 | 216 | the top navigation bar can be used to control whether documentation | ||
2080 | 217 | for private objects is displayed. Private objects are usually defined | ||
2081 | 218 | as objects whose (short) names begin with a single underscore, but do | ||
2082 | 219 | not end with an underscore. For example, "<code>_x</code>", | ||
2083 | 220 | "<code>__pprint</code>", and "<code>epydoc.epytext._tokenize</code>" | ||
2084 | 221 | are private objects; but "<code>re.sub</code>", | ||
2085 | 222 | "<code>__init__</code>", and "<code>type_</code>" are not. However, | ||
2086 | 223 | if a module defines the "<code>__all__</code>" variable, then its | ||
2087 | 224 | contents are used to decide which objects are private. </p> | ||
2088 | 225 | |||
2089 | 226 | <p> A timestamp below the bottom navigation bar indicates when each | ||
2090 | 227 | page was last updated. </p> | ||
2091 | 228 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2092 | 229 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2093 | 230 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2094 | 231 | <tr valign="middle"> | ||
2095 | 232 | <!-- Home link --> | ||
2096 | 233 | <th> <a | ||
2097 | 234 | href="scriptutil-module.html">Home</a> </th> | ||
2098 | 235 | |||
2099 | 236 | <!-- Tree link --> | ||
2100 | 237 | <th> <a | ||
2101 | 238 | href="module-tree.html">Trees</a> </th> | ||
2102 | 239 | |||
2103 | 240 | <!-- Index link --> | ||
2104 | 241 | <th> <a | ||
2105 | 242 | href="identifier-index.html">Indices</a> </th> | ||
2106 | 243 | |||
2107 | 244 | <!-- Help link --> | ||
2108 | 245 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2109 | 246 | > Help </th> | ||
2110 | 247 | |||
2111 | 248 | <!-- Project homepage --> | ||
2112 | 249 | <th class="navbar" align="right" width="100%"> | ||
2113 | 250 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2114 | 251 | <tr><th class="navbar" align="center" | ||
2115 | 252 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
2116 | 253 | </tr></table></th> | ||
2117 | 254 | </tr> | ||
2118 | 255 | </table> | ||
2119 | 256 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
2120 | 257 | <tr> | ||
2121 | 258 | <td align="left" class="footer"> | ||
2122 | 259 | Generated by Epydoc 3.0beta1 on Thu May 22 18:10:51 2008 | ||
2123 | 260 | </td> | ||
2124 | 261 | <td align="right" class="footer"> | ||
2125 | 262 | <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a> | ||
2126 | 263 | </td> | ||
2127 | 264 | </tr> | ||
2128 | 265 | </table> | ||
2129 | 266 | |||
2130 | 267 | <script type="text/javascript"> | ||
2131 | 268 | <!-- | ||
2132 | 269 | // Private objects are initially displayed (because if | ||
2133 | 270 | // javascript is turned off then we want them to be | ||
2134 | 271 | // visible); but by default, we want to hide them. So hide | ||
2135 | 272 | // them unless we have a cookie that says to show them. | ||
2136 | 273 | checkCookie() | ||
2137 | 274 | // --> | ||
2138 | 275 | </script> | ||
2139 | 276 | |||
2140 | 277 | </body> | ||
2141 | 278 | </html> | ||
2142 | 279 | 0 | ||
2143 | === added file 'doc/html/identifier-index.html' | |||
2144 | --- doc/html/identifier-index.html 1970-01-01 00:00:00 +0000 | |||
2145 | +++ doc/html/identifier-index.html 2009-12-26 22:06:14 +0000 | |||
2146 | @@ -0,0 +1,217 @@ | |||
2147 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
2148 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
2149 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
2150 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
2151 | 5 | <head> | ||
2152 | 6 | <title>Identifier Index</title> | ||
2153 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
2154 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
2155 | 9 | </head> | ||
2156 | 10 | |||
2157 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
2158 | 12 | alink="#204080"> | ||
2159 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2160 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2161 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2162 | 16 | <tr valign="middle"> | ||
2163 | 17 | <!-- Home link --> | ||
2164 | 18 | <th> <a | ||
2165 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
2166 | 20 | |||
2167 | 21 | <!-- Tree link --> | ||
2168 | 22 | <th> <a | ||
2169 | 23 | href="module-tree.html">Trees</a> </th> | ||
2170 | 24 | |||
2171 | 25 | <!-- Index link --> | ||
2172 | 26 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2173 | 27 | > Indices </th> | ||
2174 | 28 | |||
2175 | 29 | <!-- Help link --> | ||
2176 | 30 | <th> <a | ||
2177 | 31 | href="help.html">Help</a> </th> | ||
2178 | 32 | |||
2179 | 33 | <!-- Project homepage --> | ||
2180 | 34 | <th class="navbar" align="right" width="100%"> | ||
2181 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2182 | 36 | <tr><th class="navbar" align="center" | ||
2183 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
2184 | 38 | </tr></table></th> | ||
2185 | 39 | </tr> | ||
2186 | 40 | </table> | ||
2187 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
2188 | 42 | <tr valign="top"> | ||
2189 | 43 | <td width="100%"> </td> | ||
2190 | 44 | <td> | ||
2191 | 45 | <table cellpadding="0" cellspacing="0"> | ||
2192 | 46 | <!-- hide/show private --> | ||
2193 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
2194 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
2195 | 49 | <tr><td align="right"><span class="options" | ||
2196 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
2197 | 51 | >] | <a href="identifier-index.html" | ||
2198 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
2199 | 53 | </table> | ||
2200 | 54 | </td> | ||
2201 | 55 | </tr> | ||
2202 | 56 | </table> | ||
2203 | 57 | <table border="0" width="100%"> | ||
2204 | 58 | <tr valign="bottom"><td> | ||
2205 | 59 | <h1 class="epydoc">Identifier Index</h1> | ||
2206 | 60 | </td><td> | ||
2207 | 61 | [ | ||
2208 | 62 | A | ||
2209 | 63 | B | ||
2210 | 64 | C | ||
2211 | 65 | D | ||
2212 | 66 | E | ||
2213 | 67 | <a href="#F">F</a> | ||
2214 | 68 | <a href="#G">G</a> | ||
2215 | 69 | H | ||
2216 | 70 | I | ||
2217 | 71 | J | ||
2218 | 72 | K | ||
2219 | 73 | L | ||
2220 | 74 | M | ||
2221 | 75 | N | ||
2222 | 76 | O | ||
2223 | 77 | <a href="#P">P</a> | ||
2224 | 78 | Q | ||
2225 | 79 | <a href="#R">R</a> | ||
2226 | 80 | <a href="#S">S</a> | ||
2227 | 81 | T | ||
2228 | 82 | U | ||
2229 | 83 | V | ||
2230 | 84 | W | ||
2231 | 85 | X | ||
2232 | 86 | Y | ||
2233 | 87 | Z | ||
2234 | 88 | <a href="#_">_</a> | ||
2235 | 89 | ] | ||
2236 | 90 | </td></table> | ||
2237 | 91 | <table border="0" width="100%"> | ||
2238 | 92 | <tr valign="top"><td valign="top" width="1%"><h2 class="epydoc"><a name="F">F</a></h2></td> | ||
2239 | 93 | <td valign="top"> | ||
2240 | 94 | <table class="link-index" width="100%" border="1"> | ||
2241 | 95 | <tr> | ||
2242 | 96 | <td width="33%" class="link-index"><a href="scriptutil.find-module.html">find</a><br /> | ||
2243 | 97 | <span class="index-where">(in <a href="scriptutil-module.html">scriptutil</a>)</span></td> | ||
2244 | 98 | <td width="33%" class="link-index"><a href="scriptutil.find-module.html#find">find()</a><br /> | ||
2245 | 99 | <span class="index-where">(in <a href="scriptutil.find-module.html">scriptutil.find</a>)</span></td> | ||
2246 | 100 | <td width="33%" class="link-index"> </td> | ||
2247 | 101 | </tr> | ||
2248 | 102 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2249 | 103 | </table> | ||
2250 | 104 | </td></tr> | ||
2251 | 105 | <tr valign="top"><td valign="top" width="1%"><h2 class="epydoc"><a name="G">G</a></h2></td> | ||
2252 | 106 | <td valign="top"> | ||
2253 | 107 | <table class="link-index" width="100%" border="1"> | ||
2254 | 108 | <tr> | ||
2255 | 109 | <td width="33%" class="link-index"><a href="scriptutil.find-module.html#grep">grep()</a><br /> | ||
2256 | 110 | <span class="index-where">(in <a href="scriptutil.find-module.html">scriptutil.find</a>)</span></td> | ||
2257 | 111 | <td width="33%" class="link-index"> </td> | ||
2258 | 112 | <td width="33%" class="link-index"> </td> | ||
2259 | 113 | </tr> | ||
2260 | 114 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2261 | 115 | </table> | ||
2262 | 116 | </td></tr> | ||
2263 | 117 | <tr valign="top"><td valign="top" width="1%"><h2 class="epydoc"><a name="P">P</a></h2></td> | ||
2264 | 118 | <td valign="top"> | ||
2265 | 119 | <table class="link-index" width="100%" border="1"> | ||
2266 | 120 | <tr> | ||
2267 | 121 | <td width="33%" class="link-index"><a href="scriptutil.find-module.html#pprint">pprint()</a><br /> | ||
2268 | 122 | <span class="index-where">(in <a href="scriptutil.find-module.html">scriptutil.find</a>)</span></td> | ||
2269 | 123 | <td width="33%" class="link-index"> </td> | ||
2270 | 124 | <td width="33%" class="link-index"> </td> | ||
2271 | 125 | </tr> | ||
2272 | 126 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2273 | 127 | </table> | ||
2274 | 128 | </td></tr> | ||
2275 | 129 | <tr valign="top"><td valign="top" width="1%"><h2 class="epydoc"><a name="R">R</a></h2></td> | ||
2276 | 130 | <td valign="top"> | ||
2277 | 131 | <table class="link-index" width="100%" border="1"> | ||
2278 | 132 | <tr> | ||
2279 | 133 | <td width="33%" class="link-index"><a href="scriptutil.find-module.html#replace">replace()</a><br /> | ||
2280 | 134 | <span class="index-where">(in <a href="scriptutil.find-module.html">scriptutil.find</a>)</span></td> | ||
2281 | 135 | <td width="33%" class="link-index"> </td> | ||
2282 | 136 | <td width="33%" class="link-index"> </td> | ||
2283 | 137 | </tr> | ||
2284 | 138 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2285 | 139 | </table> | ||
2286 | 140 | </td></tr> | ||
2287 | 141 | <tr valign="top"><td valign="top" width="1%"><h2 class="epydoc"><a name="S">S</a></h2></td> | ||
2288 | 142 | <td valign="top"> | ||
2289 | 143 | <table class="link-index" width="100%" border="1"> | ||
2290 | 144 | <tr> | ||
2291 | 145 | <td width="33%" class="link-index"><a href="scriptutil.find.ScriptError-class.html">ScriptError</a><br /> | ||
2292 | 146 | <span class="index-where">(in <a href="scriptutil.find-module.html">scriptutil.find</a>)</span></td> | ||
2293 | 147 | <td width="33%" class="link-index"><a href="scriptutil-module.html">scriptutil</a></td> | ||
2294 | 148 | <td width="33%" class="link-index"> </td> | ||
2295 | 149 | </tr> | ||
2296 | 150 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2297 | 151 | </table> | ||
2298 | 152 | </td></tr> | ||
2299 | 153 | <tr valign="top"><td valign="top" width="1%"><h2 class="epydoc"><a name="_">_</a></h2></td> | ||
2300 | 154 | <td valign="top"> | ||
2301 | 155 | <table class="link-index" width="100%" border="1"> | ||
2302 | 156 | <tr> | ||
2303 | 157 | <td width="33%" class="link-index"><a href="scriptutil-module.html#__package__">__package__</a><br /> | ||
2304 | 158 | <span class="index-where">(in <a href="scriptutil-module.html">scriptutil</a>)</span></td> | ||
2305 | 159 | <td width="33%" class="link-index"><a href="scriptutil.find-module.html#__package__">__package__</a><br /> | ||
2306 | 160 | <span class="index-where">(in <a href="scriptutil.find-module.html">scriptutil.find</a>)</span></td> | ||
2307 | 161 | <td width="33%" class="link-index"> </td> | ||
2308 | 162 | </tr> | ||
2309 | 163 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2310 | 164 | </table> | ||
2311 | 165 | </td></tr> | ||
2312 | 166 | </table> | ||
2313 | 167 | <br /><br /><!-- ==================== NAVIGATION BAR ==================== --> | ||
2314 | 168 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2315 | 169 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2316 | 170 | <tr valign="middle"> | ||
2317 | 171 | <!-- Home link --> | ||
2318 | 172 | <th> <a | ||
2319 | 173 | href="scriptutil-module.html">Home</a> </th> | ||
2320 | 174 | |||
2321 | 175 | <!-- Tree link --> | ||
2322 | 176 | <th> <a | ||
2323 | 177 | href="module-tree.html">Trees</a> </th> | ||
2324 | 178 | |||
2325 | 179 | <!-- Index link --> | ||
2326 | 180 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2327 | 181 | > Indices </th> | ||
2328 | 182 | |||
2329 | 183 | <!-- Help link --> | ||
2330 | 184 | <th> <a | ||
2331 | 185 | href="help.html">Help</a> </th> | ||
2332 | 186 | |||
2333 | 187 | <!-- Project homepage --> | ||
2334 | 188 | <th class="navbar" align="right" width="100%"> | ||
2335 | 189 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2336 | 190 | <tr><th class="navbar" align="center" | ||
2337 | 191 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
2338 | 192 | </tr></table></th> | ||
2339 | 193 | </tr> | ||
2340 | 194 | </table> | ||
2341 | 195 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
2342 | 196 | <tr> | ||
2343 | 197 | <td align="left" class="footer"> | ||
2344 | 198 | Generated by Epydoc 3.0.1 on Sat Dec 26 23:01:34 2009 | ||
2345 | 199 | </td> | ||
2346 | 200 | <td align="right" class="footer"> | ||
2347 | 201 | <a target="mainFrame" href="http://epydoc.sourceforge.net" | ||
2348 | 202 | >http://epydoc.sourceforge.net</a> | ||
2349 | 203 | </td> | ||
2350 | 204 | </tr> | ||
2351 | 205 | </table> | ||
2352 | 206 | |||
2353 | 207 | <script type="text/javascript"> | ||
2354 | 208 | <!-- | ||
2355 | 209 | // Private objects are initially displayed (because if | ||
2356 | 210 | // javascript is turned off then we want them to be | ||
2357 | 211 | // visible); but by default, we want to hide them. So hide | ||
2358 | 212 | // them unless we have a cookie that says to show them. | ||
2359 | 213 | checkCookie(); | ||
2360 | 214 | // --> | ||
2361 | 215 | </script> | ||
2362 | 216 | </body> | ||
2363 | 217 | </html> | ||
2364 | 0 | 218 | ||
2365 | === removed file 'doc/html/identifier-index.html' | |||
2366 | --- doc/html/identifier-index.html 2009-12-26 20:49:38 +0000 | |||
2367 | +++ doc/html/identifier-index.html 1970-01-01 00:00:00 +0000 | |||
2368 | @@ -1,181 +0,0 @@ | |||
2369 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
2370 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
2371 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
2372 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
2373 | 5 | <head> | ||
2374 | 6 | <title>Identifier Index</title> | ||
2375 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
2376 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
2377 | 9 | </head> | ||
2378 | 10 | |||
2379 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
2380 | 12 | alink="#204080"> | ||
2381 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2382 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2383 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2384 | 16 | <tr valign="middle"> | ||
2385 | 17 | <!-- Home link --> | ||
2386 | 18 | <th> <a | ||
2387 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
2388 | 20 | |||
2389 | 21 | <!-- Tree link --> | ||
2390 | 22 | <th> <a | ||
2391 | 23 | href="module-tree.html">Trees</a> </th> | ||
2392 | 24 | |||
2393 | 25 | <!-- Index link --> | ||
2394 | 26 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2395 | 27 | > Indices </th> | ||
2396 | 28 | |||
2397 | 29 | <!-- Help link --> | ||
2398 | 30 | <th> <a | ||
2399 | 31 | href="help.html">Help</a> </th> | ||
2400 | 32 | |||
2401 | 33 | <!-- Project homepage --> | ||
2402 | 34 | <th class="navbar" align="right" width="100%"> | ||
2403 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2404 | 36 | <tr><th class="navbar" align="center" | ||
2405 | 37 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
2406 | 38 | </tr></table></th> | ||
2407 | 39 | </tr> | ||
2408 | 40 | </table> | ||
2409 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
2410 | 42 | <tr valign="top"> | ||
2411 | 43 | <td width="100%"> </td> | ||
2412 | 44 | <td> | ||
2413 | 45 | <table cellpadding="0" cellspacing="0"> | ||
2414 | 46 | <!-- hide/show private --> | ||
2415 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
2416 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
2417 | 49 | <tr><td align="right"><span class="options" | ||
2418 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
2419 | 51 | >] | <a href="identifier-index.html" | ||
2420 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
2421 | 53 | </table> | ||
2422 | 54 | </td> | ||
2423 | 55 | </tr> | ||
2424 | 56 | </table> | ||
2425 | 57 | <table border="0" width="100%"> | ||
2426 | 58 | <tr valign="bottom"><td> | ||
2427 | 59 | <h1 class="epydoc">Identifier Index</h1> | ||
2428 | 60 | </td><td> | ||
2429 | 61 | [ | ||
2430 | 62 | A | ||
2431 | 63 | B | ||
2432 | 64 | C | ||
2433 | 65 | D | ||
2434 | 66 | E | ||
2435 | 67 | <a href="#F">F</a> | ||
2436 | 68 | G | ||
2437 | 69 | H | ||
2438 | 70 | I | ||
2439 | 71 | J | ||
2440 | 72 | K | ||
2441 | 73 | L | ||
2442 | 74 | M | ||
2443 | 75 | N | ||
2444 | 76 | O | ||
2445 | 77 | <a href="#P">P</a> | ||
2446 | 78 | Q | ||
2447 | 79 | R | ||
2448 | 80 | <a href="#S">S</a> | ||
2449 | 81 | T | ||
2450 | 82 | U | ||
2451 | 83 | V | ||
2452 | 84 | W | ||
2453 | 85 | X | ||
2454 | 86 | Y | ||
2455 | 87 | Z | ||
2456 | 88 | _ | ||
2457 | 89 | ] | ||
2458 | 90 | </td></table> | ||
2459 | 91 | <table border="0" width="100%"><tr valign="top"> | ||
2460 | 92 | <td valign="top" width="1%"><a name="F"><h2 class="epydoc">F</h2></a></td> | ||
2461 | 93 | <td valign="top"> | ||
2462 | 94 | <table class="link-index" width="100%" border="1"> | ||
2463 | 95 | <tr> | ||
2464 | 96 | <td width="33%" class="link-index"><a href="scriptutil-module.html#ffind">ffind()</a><br /> | ||
2465 | 97 | <span class="index-where">(in <a href="scriptutil-module.html">scriptutil</a>)</font></td> | ||
2466 | 98 | <td width="33%" class="link-index"><a href="scriptutil-module.html#ffindgrep">ffindgrep()</a><br /> | ||
2467 | 99 | <span class="index-where">(in <a href="scriptutil-module.html">scriptutil</a>)</font></td> | ||
2468 | 100 | <td width="33%" class="link-index"><a href="scriptutil-module.html#freplace">freplace()</a><br /> | ||
2469 | 101 | <span class="index-where">(in <a href="scriptutil-module.html">scriptutil</a>)</font></td> | ||
2470 | 102 | </tr> | ||
2471 | 103 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2472 | 104 | </table> | ||
2473 | 105 | </td></tr> | ||
2474 | 106 | <td valign="top" width="1%"><a name="P"><h2 class="epydoc">P</h2></a></td> | ||
2475 | 107 | <td valign="top"> | ||
2476 | 108 | <table class="link-index" width="100%" border="1"> | ||
2477 | 109 | <tr> | ||
2478 | 110 | <td width="33%" class="link-index"><a href="scriptutil-module.html#printr">printr()</a><br /> | ||
2479 | 111 | <span class="index-where">(in <a href="scriptutil-module.html">scriptutil</a>)</font></td> | ||
2480 | 112 | <td width="33%" class="link-index"> </td> | ||
2481 | 113 | <td width="33%" class="link-index"> </td> | ||
2482 | 114 | </tr> | ||
2483 | 115 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2484 | 116 | </table> | ||
2485 | 117 | </td></tr> | ||
2486 | 118 | <td valign="top" width="1%"><a name="S"><h2 class="epydoc">S</h2></a></td> | ||
2487 | 119 | <td valign="top"> | ||
2488 | 120 | <table class="link-index" width="100%" border="1"> | ||
2489 | 121 | <tr> | ||
2490 | 122 | <td width="33%" class="link-index"><a href="scriptutil.ScriptError-class.html">ScriptError</a><br /> | ||
2491 | 123 | <span class="index-where">(in <a href="scriptutil-module.html">scriptutil</a>)</font></td> | ||
2492 | 124 | <td width="33%" class="link-index"><a href="scriptutil-module.html">scriptutil</a></td> | ||
2493 | 125 | <td width="33%" class="link-index"> </td> | ||
2494 | 126 | </tr> | ||
2495 | 127 | <tr><td class="link-index"> </td><td class="link-index"> </td><td class="link-index"> </td></tr> | ||
2496 | 128 | </table> | ||
2497 | 129 | </td></tr> | ||
2498 | 130 | </table> | ||
2499 | 131 | </br /><br /><!-- ==================== NAVIGATION BAR ==================== --> | ||
2500 | 132 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2501 | 133 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2502 | 134 | <tr valign="middle"> | ||
2503 | 135 | <!-- Home link --> | ||
2504 | 136 | <th> <a | ||
2505 | 137 | href="scriptutil-module.html">Home</a> </th> | ||
2506 | 138 | |||
2507 | 139 | <!-- Tree link --> | ||
2508 | 140 | <th> <a | ||
2509 | 141 | href="module-tree.html">Trees</a> </th> | ||
2510 | 142 | |||
2511 | 143 | <!-- Index link --> | ||
2512 | 144 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2513 | 145 | > Indices </th> | ||
2514 | 146 | |||
2515 | 147 | <!-- Help link --> | ||
2516 | 148 | <th> <a | ||
2517 | 149 | href="help.html">Help</a> </th> | ||
2518 | 150 | |||
2519 | 151 | <!-- Project homepage --> | ||
2520 | 152 | <th class="navbar" align="right" width="100%"> | ||
2521 | 153 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2522 | 154 | <tr><th class="navbar" align="center" | ||
2523 | 155 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
2524 | 156 | </tr></table></th> | ||
2525 | 157 | </tr> | ||
2526 | 158 | </table> | ||
2527 | 159 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
2528 | 160 | <tr> | ||
2529 | 161 | <td align="left" class="footer"> | ||
2530 | 162 | Generated by Epydoc 3.0beta1 on Thu May 22 18:10:51 2008 | ||
2531 | 163 | </td> | ||
2532 | 164 | <td align="right" class="footer"> | ||
2533 | 165 | <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a> | ||
2534 | 166 | </td> | ||
2535 | 167 | </tr> | ||
2536 | 168 | </table> | ||
2537 | 169 | |||
2538 | 170 | <script type="text/javascript"> | ||
2539 | 171 | <!-- | ||
2540 | 172 | // Private objects are initially displayed (because if | ||
2541 | 173 | // javascript is turned off then we want them to be | ||
2542 | 174 | // visible); but by default, we want to hide them. So hide | ||
2543 | 175 | // them unless we have a cookie that says to show them. | ||
2544 | 176 | checkCookie() | ||
2545 | 177 | // --> | ||
2546 | 178 | </script> | ||
2547 | 179 | |||
2548 | 180 | </body> | ||
2549 | 181 | </html> | ||
2550 | 182 | 0 | ||
2551 | === added file 'doc/html/index.html' | |||
2552 | --- doc/html/index.html 1970-01-01 00:00:00 +0000 | |||
2553 | +++ doc/html/index.html 2009-12-26 22:06:14 +0000 | |||
2554 | @@ -0,0 +1,17 @@ | |||
2555 | 1 | <?xml version="1.0" encoding="iso-8859-1"?> | ||
2556 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" | ||
2557 | 3 | "DTD/xhtml1-frameset.dtd"> | ||
2558 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
2559 | 5 | <head> | ||
2560 | 6 | <title> API Documentation </title> | ||
2561 | 7 | </head> | ||
2562 | 8 | <frameset cols="20%,80%"> | ||
2563 | 9 | <frameset rows="30%,70%"> | ||
2564 | 10 | <frame src="toc.html" name="moduleListFrame" | ||
2565 | 11 | id="moduleListFrame" /> | ||
2566 | 12 | <frame src="toc-everything.html" name="moduleFrame" | ||
2567 | 13 | id="moduleFrame" /> | ||
2568 | 14 | </frameset> | ||
2569 | 15 | <frame src="scriptutil-module.html" name="mainFrame" id="mainFrame" /> | ||
2570 | 16 | </frameset> | ||
2571 | 17 | </html> | ||
2572 | 0 | 18 | ||
2573 | === removed file 'doc/html/index.html' | |||
2574 | --- doc/html/index.html 2009-12-26 20:49:38 +0000 | |||
2575 | +++ doc/html/index.html 1970-01-01 00:00:00 +0000 | |||
2576 | @@ -1,17 +0,0 @@ | |||
2577 | 1 | <?xml version="1.0" encoding="iso-8859-1"?> | ||
2578 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" | ||
2579 | 3 | "DTD/xhtml1-frameset.dtd"> | ||
2580 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
2581 | 5 | <head> | ||
2582 | 6 | <title> Module scriptutil </title> | ||
2583 | 7 | </head> | ||
2584 | 8 | <frameset cols="20%,80%"> | ||
2585 | 9 | <frameset rows="30%,70%"> | ||
2586 | 10 | <frame src="toc.html" name="moduleListFrame" | ||
2587 | 11 | id="moduleListFrame" /> | ||
2588 | 12 | <frame src="toc-everything.html" name="moduleFrame" | ||
2589 | 13 | id="moduleFrame" /> | ||
2590 | 14 | </frameset> | ||
2591 | 15 | <frame src="scriptutil-module.html" name="mainFrame" id="mainFrame" /> | ||
2592 | 16 | </frameset> | ||
2593 | 17 | </html> | ||
2594 | 18 | 0 | ||
2595 | === added file 'doc/html/module-tree.html' | |||
2596 | --- doc/html/module-tree.html 1970-01-01 00:00:00 +0000 | |||
2597 | +++ doc/html/module-tree.html 2009-12-26 22:06:14 +0000 | |||
2598 | @@ -0,0 +1,119 @@ | |||
2599 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
2600 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
2601 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
2602 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
2603 | 5 | <head> | ||
2604 | 6 | <title>Module Hierarchy</title> | ||
2605 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
2606 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
2607 | 9 | </head> | ||
2608 | 10 | |||
2609 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
2610 | 12 | alink="#204080"> | ||
2611 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2612 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2613 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2614 | 16 | <tr valign="middle"> | ||
2615 | 17 | <!-- Home link --> | ||
2616 | 18 | <th> <a | ||
2617 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
2618 | 20 | |||
2619 | 21 | <!-- Tree link --> | ||
2620 | 22 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2621 | 23 | > Trees </th> | ||
2622 | 24 | |||
2623 | 25 | <!-- Index link --> | ||
2624 | 26 | <th> <a | ||
2625 | 27 | href="identifier-index.html">Indices</a> </th> | ||
2626 | 28 | |||
2627 | 29 | <!-- Help link --> | ||
2628 | 30 | <th> <a | ||
2629 | 31 | href="help.html">Help</a> </th> | ||
2630 | 32 | |||
2631 | 33 | <!-- Project homepage --> | ||
2632 | 34 | <th class="navbar" align="right" width="100%"> | ||
2633 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2634 | 36 | <tr><th class="navbar" align="center" | ||
2635 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
2636 | 38 | </tr></table></th> | ||
2637 | 39 | </tr> | ||
2638 | 40 | </table> | ||
2639 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
2640 | 42 | <tr valign="top"> | ||
2641 | 43 | <td width="100%"> </td> | ||
2642 | 44 | <td> | ||
2643 | 45 | <table cellpadding="0" cellspacing="0"> | ||
2644 | 46 | <!-- hide/show private --> | ||
2645 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
2646 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
2647 | 49 | <tr><td align="right"><span class="options" | ||
2648 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
2649 | 51 | >] | <a href="module-tree.html" | ||
2650 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
2651 | 53 | </table> | ||
2652 | 54 | </td> | ||
2653 | 55 | </tr> | ||
2654 | 56 | </table> | ||
2655 | 57 | <center><b> | ||
2656 | 58 | [ <a href="module-tree.html">Module Hierarchy</a> | ||
2657 | 59 | | <a href="class-tree.html">Class Hierarchy</a> ] | ||
2658 | 60 | </b></center><br /> | ||
2659 | 61 | <h1 class="epydoc">Module Hierarchy</h1> | ||
2660 | 62 | <ul class="nomargin-top"> | ||
2661 | 63 | <li> <strong class="uidlink"><a href="scriptutil-module.html">scriptutil</a></strong> | ||
2662 | 64 | <ul> | ||
2663 | 65 | <li> <strong class="uidlink"><a href="scriptutil.find-module.html">scriptutil.find</a></strong>: <em class="summary">Functions commonly used in shell scripting:</em> </li> | ||
2664 | 66 | </ul> | ||
2665 | 67 | </li> | ||
2666 | 68 | </ul> | ||
2667 | 69 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2668 | 70 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2669 | 71 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2670 | 72 | <tr valign="middle"> | ||
2671 | 73 | <!-- Home link --> | ||
2672 | 74 | <th> <a | ||
2673 | 75 | href="scriptutil-module.html">Home</a> </th> | ||
2674 | 76 | |||
2675 | 77 | <!-- Tree link --> | ||
2676 | 78 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2677 | 79 | > Trees </th> | ||
2678 | 80 | |||
2679 | 81 | <!-- Index link --> | ||
2680 | 82 | <th> <a | ||
2681 | 83 | href="identifier-index.html">Indices</a> </th> | ||
2682 | 84 | |||
2683 | 85 | <!-- Help link --> | ||
2684 | 86 | <th> <a | ||
2685 | 87 | href="help.html">Help</a> </th> | ||
2686 | 88 | |||
2687 | 89 | <!-- Project homepage --> | ||
2688 | 90 | <th class="navbar" align="right" width="100%"> | ||
2689 | 91 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2690 | 92 | <tr><th class="navbar" align="center" | ||
2691 | 93 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
2692 | 94 | </tr></table></th> | ||
2693 | 95 | </tr> | ||
2694 | 96 | </table> | ||
2695 | 97 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
2696 | 98 | <tr> | ||
2697 | 99 | <td align="left" class="footer"> | ||
2698 | 100 | Generated by Epydoc 3.0.1 on Sat Dec 26 23:01:34 2009 | ||
2699 | 101 | </td> | ||
2700 | 102 | <td align="right" class="footer"> | ||
2701 | 103 | <a target="mainFrame" href="http://epydoc.sourceforge.net" | ||
2702 | 104 | >http://epydoc.sourceforge.net</a> | ||
2703 | 105 | </td> | ||
2704 | 106 | </tr> | ||
2705 | 107 | </table> | ||
2706 | 108 | |||
2707 | 109 | <script type="text/javascript"> | ||
2708 | 110 | <!-- | ||
2709 | 111 | // Private objects are initially displayed (because if | ||
2710 | 112 | // javascript is turned off then we want them to be | ||
2711 | 113 | // visible); but by default, we want to hide them. So hide | ||
2712 | 114 | // them unless we have a cookie that says to show them. | ||
2713 | 115 | checkCookie(); | ||
2714 | 116 | // --> | ||
2715 | 117 | </script> | ||
2716 | 118 | </body> | ||
2717 | 119 | </html> | ||
2718 | 0 | 120 | ||
2719 | === removed file 'doc/html/module-tree.html' | |||
2720 | --- doc/html/module-tree.html 2009-12-26 20:49:38 +0000 | |||
2721 | +++ doc/html/module-tree.html 1970-01-01 00:00:00 +0000 | |||
2722 | @@ -1,115 +0,0 @@ | |||
2723 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
2724 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
2725 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
2726 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
2727 | 5 | <head> | ||
2728 | 6 | <title>Module Hierarchy</title> | ||
2729 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
2730 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
2731 | 9 | </head> | ||
2732 | 10 | |||
2733 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
2734 | 12 | alink="#204080"> | ||
2735 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2736 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2737 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2738 | 16 | <tr valign="middle"> | ||
2739 | 17 | <!-- Home link --> | ||
2740 | 18 | <th> <a | ||
2741 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
2742 | 20 | |||
2743 | 21 | <!-- Tree link --> | ||
2744 | 22 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2745 | 23 | > Trees </th> | ||
2746 | 24 | |||
2747 | 25 | <!-- Index link --> | ||
2748 | 26 | <th> <a | ||
2749 | 27 | href="identifier-index.html">Indices</a> </th> | ||
2750 | 28 | |||
2751 | 29 | <!-- Help link --> | ||
2752 | 30 | <th> <a | ||
2753 | 31 | href="help.html">Help</a> </th> | ||
2754 | 32 | |||
2755 | 33 | <!-- Project homepage --> | ||
2756 | 34 | <th class="navbar" align="right" width="100%"> | ||
2757 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2758 | 36 | <tr><th class="navbar" align="center" | ||
2759 | 37 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
2760 | 38 | </tr></table></th> | ||
2761 | 39 | </tr> | ||
2762 | 40 | </table> | ||
2763 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
2764 | 42 | <tr valign="top"> | ||
2765 | 43 | <td width="100%"> </td> | ||
2766 | 44 | <td> | ||
2767 | 45 | <table cellpadding="0" cellspacing="0"> | ||
2768 | 46 | <!-- hide/show private --> | ||
2769 | 47 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
2770 | 48 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
2771 | 49 | <tr><td align="right"><span class="options" | ||
2772 | 50 | >[<a href="frames.html" target="_top">frames</a | ||
2773 | 51 | >] | <a href="module-tree.html" | ||
2774 | 52 | target="_top">no frames</a>]</span></td></tr> | ||
2775 | 53 | </table> | ||
2776 | 54 | </td> | ||
2777 | 55 | </tr> | ||
2778 | 56 | </table> | ||
2779 | 57 | <center><b> | ||
2780 | 58 | [ <a href="module-tree.html">Module Hierarchy</a> | ||
2781 | 59 | | <a href="class-tree.html">Class Hierarchy</a> ] | ||
2782 | 60 | </b></center><br /> | ||
2783 | 61 | <h1 class="epydoc">Module Hierarchy</h1> | ||
2784 | 62 | <ul class="nomargin-top"> | ||
2785 | 63 | <li> <strong class="uidlink"><a href="scriptutil-module.html">scriptutil</a></strong>: <em class="summary">Copyright (c) 2008, Muharem Hrnjadovic</em> </li> | ||
2786 | 64 | </ul> | ||
2787 | 65 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2788 | 66 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2789 | 67 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2790 | 68 | <tr valign="middle"> | ||
2791 | 69 | <!-- Home link --> | ||
2792 | 70 | <th> <a | ||
2793 | 71 | href="scriptutil-module.html">Home</a> </th> | ||
2794 | 72 | |||
2795 | 73 | <!-- Tree link --> | ||
2796 | 74 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2797 | 75 | > Trees </th> | ||
2798 | 76 | |||
2799 | 77 | <!-- Index link --> | ||
2800 | 78 | <th> <a | ||
2801 | 79 | href="identifier-index.html">Indices</a> </th> | ||
2802 | 80 | |||
2803 | 81 | <!-- Help link --> | ||
2804 | 82 | <th> <a | ||
2805 | 83 | href="help.html">Help</a> </th> | ||
2806 | 84 | |||
2807 | 85 | <!-- Project homepage --> | ||
2808 | 86 | <th class="navbar" align="right" width="100%"> | ||
2809 | 87 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2810 | 88 | <tr><th class="navbar" align="center" | ||
2811 | 89 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
2812 | 90 | </tr></table></th> | ||
2813 | 91 | </tr> | ||
2814 | 92 | </table> | ||
2815 | 93 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
2816 | 94 | <tr> | ||
2817 | 95 | <td align="left" class="footer"> | ||
2818 | 96 | Generated by Epydoc 3.0beta1 on Thu May 22 18:10:51 2008 | ||
2819 | 97 | </td> | ||
2820 | 98 | <td align="right" class="footer"> | ||
2821 | 99 | <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a> | ||
2822 | 100 | </td> | ||
2823 | 101 | </tr> | ||
2824 | 102 | </table> | ||
2825 | 103 | |||
2826 | 104 | <script type="text/javascript"> | ||
2827 | 105 | <!-- | ||
2828 | 106 | // Private objects are initially displayed (because if | ||
2829 | 107 | // javascript is turned off then we want them to be | ||
2830 | 108 | // visible); but by default, we want to hide them. So hide | ||
2831 | 109 | // them unless we have a cookie that says to show them. | ||
2832 | 110 | checkCookie() | ||
2833 | 111 | // --> | ||
2834 | 112 | </script> | ||
2835 | 113 | |||
2836 | 114 | </body> | ||
2837 | 115 | </html> | ||
2838 | 116 | 0 | ||
2839 | === added file 'doc/html/redirect.html' | |||
2840 | --- doc/html/redirect.html 1970-01-01 00:00:00 +0000 | |||
2841 | +++ doc/html/redirect.html 2009-12-26 22:06:14 +0000 | |||
2842 | @@ -0,0 +1,38 @@ | |||
2843 | 1 | <html><head><title>Epydoc Redirect Page</title> | ||
2844 | 2 | <meta http-equiv="cache-control" content="no-cache" /> | ||
2845 | 3 | <meta http-equiv="expires" content="0" /> | ||
2846 | 4 | <meta http-equiv="pragma" content="no-cache" /> | ||
2847 | 5 | <script type="text/javascript" src="epydoc.js"></script> | ||
2848 | 6 | </head> | ||
2849 | 7 | <body> | ||
2850 | 8 | <script type="text/javascript"> | ||
2851 | 9 | <!-- | ||
2852 | 10 | var pages = ["scriptutil.find.ScriptError-c", "scriptutil.find-m", "scriptutil-m"]; | ||
2853 | 11 | var dottedName = get_anchor(); | ||
2854 | 12 | if (dottedName) { | ||
2855 | 13 | var target = redirect_url(dottedName); | ||
2856 | 14 | if (target) window.location.replace(target); | ||
2857 | 15 | } | ||
2858 | 16 | // --> | ||
2859 | 17 | </script> | ||
2860 | 18 | |||
2861 | 19 | <h3>Epydoc Auto-redirect page</h3> | ||
2862 | 20 | |||
2863 | 21 | <p>When javascript is enabled, this page will redirect URLs of | ||
2864 | 22 | the form <tt>redirect.html#<i>dotted.name</i></tt> to the | ||
2865 | 23 | documentation for the object with the given fully-qualified | ||
2866 | 24 | dotted name.</p> | ||
2867 | 25 | <p><a id="message"> </a></p> | ||
2868 | 26 | |||
2869 | 27 | <script type="text/javascript"> | ||
2870 | 28 | <!-- | ||
2871 | 29 | if (dottedName) { | ||
2872 | 30 | var msg = document.getElementById("message"); | ||
2873 | 31 | msg.innerHTML = "No documentation found for <tt>"+ | ||
2874 | 32 | dottedName+"</tt>"; | ||
2875 | 33 | } | ||
2876 | 34 | // --> | ||
2877 | 35 | </script> | ||
2878 | 36 | |||
2879 | 37 | </body> | ||
2880 | 38 | </html> | ||
2881 | 0 | 39 | ||
2882 | === removed file 'doc/html/redirect.html' | |||
2883 | --- doc/html/redirect.html 2009-12-26 20:49:38 +0000 | |||
2884 | +++ doc/html/redirect.html 1970-01-01 00:00:00 +0000 | |||
2885 | @@ -1,38 +0,0 @@ | |||
2886 | 1 | <html><head><title>Epydoc Redirect Page</title> | ||
2887 | 2 | <meta http-equiv="cache-control" content="no-cache" /> | ||
2888 | 3 | <meta http-equiv="expires" content="0" /> | ||
2889 | 4 | <meta http-equiv="pragma" content="no-cache" /> | ||
2890 | 5 | <script type="text/javascript" src="epydoc.js"></script> | ||
2891 | 6 | </head> | ||
2892 | 7 | <body> | ||
2893 | 8 | <script type="text/javascript"> | ||
2894 | 9 | <!-- | ||
2895 | 10 | var pages = ["scriptutil.ScriptError-c", "scriptutil-m"]; | ||
2896 | 11 | var dottedName = get_anchor(); | ||
2897 | 12 | if (dottedName) { | ||
2898 | 13 | var target = redirect_url(dottedName); | ||
2899 | 14 | if (target) window.location.replace(target); | ||
2900 | 15 | } | ||
2901 | 16 | // --> | ||
2902 | 17 | </script> | ||
2903 | 18 | |||
2904 | 19 | <h3>Epydoc Auto-redirect page</h3> | ||
2905 | 20 | |||
2906 | 21 | <p>When javascript is enabled, this page will redirect URLs of | ||
2907 | 22 | the form <tt>redirect.html#<i>dotted.name</i></tt> to the | ||
2908 | 23 | documentation for the object with the given fully-qualified | ||
2909 | 24 | dotted name.</p> | ||
2910 | 25 | <p><a id="message"> </a></p> | ||
2911 | 26 | |||
2912 | 27 | <script type="text/javascript"> | ||
2913 | 28 | <!-- | ||
2914 | 29 | if (dottedName) { | ||
2915 | 30 | var msg = document.getElementById("message"); | ||
2916 | 31 | msg.innerHTML = "No documentation found for <tt>"+ | ||
2917 | 32 | dottedName+"</tt>"; | ||
2918 | 33 | } | ||
2919 | 34 | // --> | ||
2920 | 35 | </script> | ||
2921 | 36 | |||
2922 | 37 | </body> | ||
2923 | 38 | </html> | ||
2924 | 39 | 0 | ||
2925 | === added file 'doc/html/scriptutil-module.html' | |||
2926 | --- doc/html/scriptutil-module.html 1970-01-01 00:00:00 +0000 | |||
2927 | +++ doc/html/scriptutil-module.html 2009-12-26 22:06:14 +0000 | |||
2928 | @@ -0,0 +1,162 @@ | |||
2929 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
2930 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
2931 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
2932 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
2933 | 5 | <head> | ||
2934 | 6 | <title>scriptutil</title> | ||
2935 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
2936 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
2937 | 9 | </head> | ||
2938 | 10 | |||
2939 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
2940 | 12 | alink="#204080"> | ||
2941 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
2942 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
2943 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
2944 | 16 | <tr valign="middle"> | ||
2945 | 17 | <!-- Home link --> | ||
2946 | 18 | <th bgcolor="#70b0f0" class="navbar-select" | ||
2947 | 19 | > Home </th> | ||
2948 | 20 | |||
2949 | 21 | <!-- Tree link --> | ||
2950 | 22 | <th> <a | ||
2951 | 23 | href="module-tree.html">Trees</a> </th> | ||
2952 | 24 | |||
2953 | 25 | <!-- Index link --> | ||
2954 | 26 | <th> <a | ||
2955 | 27 | href="identifier-index.html">Indices</a> </th> | ||
2956 | 28 | |||
2957 | 29 | <!-- Help link --> | ||
2958 | 30 | <th> <a | ||
2959 | 31 | href="help.html">Help</a> </th> | ||
2960 | 32 | |||
2961 | 33 | <!-- Project homepage --> | ||
2962 | 34 | <th class="navbar" align="right" width="100%"> | ||
2963 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
2964 | 36 | <tr><th class="navbar" align="center" | ||
2965 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
2966 | 38 | </tr></table></th> | ||
2967 | 39 | </tr> | ||
2968 | 40 | </table> | ||
2969 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
2970 | 42 | <tr valign="top"> | ||
2971 | 43 | <td width="100%"> | ||
2972 | 44 | <span class="breadcrumbs"> | ||
2973 | 45 | Package scriptutil | ||
2974 | 46 | </span> | ||
2975 | 47 | </td> | ||
2976 | 48 | <td> | ||
2977 | 49 | <table cellpadding="0" cellspacing="0"> | ||
2978 | 50 | <!-- hide/show private --> | ||
2979 | 51 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
2980 | 52 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
2981 | 53 | <tr><td align="right"><span class="options" | ||
2982 | 54 | >[<a href="frames.html" target="_top">frames</a | ||
2983 | 55 | >] | <a href="scriptutil-module.html" | ||
2984 | 56 | target="_top">no frames</a>]</span></td></tr> | ||
2985 | 57 | </table> | ||
2986 | 58 | </td> | ||
2987 | 59 | </tr> | ||
2988 | 60 | </table> | ||
2989 | 61 | <!-- ==================== PACKAGE DESCRIPTION ==================== --> | ||
2990 | 62 | <h1 class="epydoc">Package scriptutil</h1><p class="nomargin-top"><span class="codelink"><a href="scriptutil-pysrc.html">source code</a></span></p> | ||
2991 | 63 | <!-- ==================== SUBMODULES ==================== --> | ||
2992 | 64 | <a name="section-Submodules"></a> | ||
2993 | 65 | <table class="summary" border="1" cellpadding="3" | ||
2994 | 66 | cellspacing="0" width="100%" bgcolor="white"> | ||
2995 | 67 | <tr bgcolor="#70b0f0" class="table-header"> | ||
2996 | 68 | <td colspan="2" class="table-header"> | ||
2997 | 69 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
2998 | 70 | <tr valign="top"> | ||
2999 | 71 | <td align="left"><span class="table-header">Submodules</span></td> | ||
3000 | 72 | <td align="right" valign="top" | ||
3001 | 73 | ><span class="options">[<a href="#section-Submodules" | ||
3002 | 74 | class="privatelink" onclick="toggle_private();" | ||
3003 | 75 | >hide private</a>]</span></td> | ||
3004 | 76 | </tr> | ||
3005 | 77 | </table> | ||
3006 | 78 | </td> | ||
3007 | 79 | </tr> | ||
3008 | 80 | <tr><td class="summary"> | ||
3009 | 81 | <ul class="nomargin"> | ||
3010 | 82 | <li> <strong class="uidlink"><a href="scriptutil.find-module.html">scriptutil.find</a></strong>: <em class="summary">Functions commonly used in shell scripting:</em> </li> | ||
3011 | 83 | </ul></td></tr> | ||
3012 | 84 | </table> | ||
3013 | 85 | |||
3014 | 86 | <br /> | ||
3015 | 87 | <!-- ==================== VARIABLES ==================== --> | ||
3016 | 88 | <a name="section-Variables"></a> | ||
3017 | 89 | <table class="summary" border="1" cellpadding="3" | ||
3018 | 90 | cellspacing="0" width="100%" bgcolor="white"> | ||
3019 | 91 | <tr bgcolor="#70b0f0" class="table-header"> | ||
3020 | 92 | <td colspan="2" class="table-header"> | ||
3021 | 93 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
3022 | 94 | <tr valign="top"> | ||
3023 | 95 | <td align="left"><span class="table-header">Variables</span></td> | ||
3024 | 96 | <td align="right" valign="top" | ||
3025 | 97 | ><span class="options">[<a href="#section-Variables" | ||
3026 | 98 | class="privatelink" onclick="toggle_private();" | ||
3027 | 99 | >hide private</a>]</span></td> | ||
3028 | 100 | </tr> | ||
3029 | 101 | </table> | ||
3030 | 102 | </td> | ||
3031 | 103 | </tr> | ||
3032 | 104 | <tr> | ||
3033 | 105 | <td width="15%" align="right" valign="top" class="summary"> | ||
3034 | 106 | <span class="summary-type"> </span> | ||
3035 | 107 | </td><td class="summary"> | ||
3036 | 108 | <a name="__package__"></a><span class="summary-name">__package__</span> = <code title="None">None</code> | ||
3037 | 109 | </td> | ||
3038 | 110 | </tr> | ||
3039 | 111 | </table> | ||
3040 | 112 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
3041 | 113 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
3042 | 114 | bgcolor="#a0c0ff" cellspacing="0"> | ||
3043 | 115 | <tr valign="middle"> | ||
3044 | 116 | <!-- Home link --> | ||
3045 | 117 | <th bgcolor="#70b0f0" class="navbar-select" | ||
3046 | 118 | > Home </th> | ||
3047 | 119 | |||
3048 | 120 | <!-- Tree link --> | ||
3049 | 121 | <th> <a | ||
3050 | 122 | href="module-tree.html">Trees</a> </th> | ||
3051 | 123 | |||
3052 | 124 | <!-- Index link --> | ||
3053 | 125 | <th> <a | ||
3054 | 126 | href="identifier-index.html">Indices</a> </th> | ||
3055 | 127 | |||
3056 | 128 | <!-- Help link --> | ||
3057 | 129 | <th> <a | ||
3058 | 130 | href="help.html">Help</a> </th> | ||
3059 | 131 | |||
3060 | 132 | <!-- Project homepage --> | ||
3061 | 133 | <th class="navbar" align="right" width="100%"> | ||
3062 | 134 | <table border="0" cellpadding="0" cellspacing="0"> | ||
3063 | 135 | <tr><th class="navbar" align="center" | ||
3064 | 136 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
3065 | 137 | </tr></table></th> | ||
3066 | 138 | </tr> | ||
3067 | 139 | </table> | ||
3068 | 140 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
3069 | 141 | <tr> | ||
3070 | 142 | <td align="left" class="footer"> | ||
3071 | 143 | Generated by Epydoc 3.0.1 on Sat Dec 26 23:01:34 2009 | ||
3072 | 144 | </td> | ||
3073 | 145 | <td align="right" class="footer"> | ||
3074 | 146 | <a target="mainFrame" href="http://epydoc.sourceforge.net" | ||
3075 | 147 | >http://epydoc.sourceforge.net</a> | ||
3076 | 148 | </td> | ||
3077 | 149 | </tr> | ||
3078 | 150 | </table> | ||
3079 | 151 | |||
3080 | 152 | <script type="text/javascript"> | ||
3081 | 153 | <!-- | ||
3082 | 154 | // Private objects are initially displayed (because if | ||
3083 | 155 | // javascript is turned off then we want them to be | ||
3084 | 156 | // visible); but by default, we want to hide them. So hide | ||
3085 | 157 | // them unless we have a cookie that says to show them. | ||
3086 | 158 | checkCookie(); | ||
3087 | 159 | // --> | ||
3088 | 160 | </script> | ||
3089 | 161 | </body> | ||
3090 | 162 | </html> | ||
3091 | 0 | 163 | ||
3092 | === removed file 'doc/html/scriptutil-module.html' | |||
3093 | --- doc/html/scriptutil-module.html 2009-12-26 20:49:38 +0000 | |||
3094 | +++ doc/html/scriptutil-module.html 1970-01-01 00:00:00 +0000 | |||
3095 | @@ -1,509 +0,0 @@ | |||
3096 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
3097 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
3098 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
3099 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
3100 | 5 | <head> | ||
3101 | 6 | <title>scriptutil</title> | ||
3102 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
3103 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
3104 | 9 | </head> | ||
3105 | 10 | |||
3106 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
3107 | 12 | alink="#204080"> | ||
3108 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
3109 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
3110 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
3111 | 16 | <tr valign="middle"> | ||
3112 | 17 | <!-- Home link --> | ||
3113 | 18 | <th bgcolor="#70b0f0" class="navbar-select" | ||
3114 | 19 | > Home </th> | ||
3115 | 20 | |||
3116 | 21 | <!-- Tree link --> | ||
3117 | 22 | <th> <a | ||
3118 | 23 | href="module-tree.html">Trees</a> </th> | ||
3119 | 24 | |||
3120 | 25 | <!-- Index link --> | ||
3121 | 26 | <th> <a | ||
3122 | 27 | href="identifier-index.html">Indices</a> </th> | ||
3123 | 28 | |||
3124 | 29 | <!-- Help link --> | ||
3125 | 30 | <th> <a | ||
3126 | 31 | href="help.html">Help</a> </th> | ||
3127 | 32 | |||
3128 | 33 | <!-- Project homepage --> | ||
3129 | 34 | <th class="navbar" align="right" width="100%"> | ||
3130 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
3131 | 36 | <tr><th class="navbar" align="center" | ||
3132 | 37 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
3133 | 38 | </tr></table></th> | ||
3134 | 39 | </tr> | ||
3135 | 40 | </table> | ||
3136 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
3137 | 42 | <tr valign="top"> | ||
3138 | 43 | <td width="100%"> | ||
3139 | 44 | <span class="breadcrumbs"> | ||
3140 | 45 | Script scriptutil | ||
3141 | 46 | </span> | ||
3142 | 47 | </td> | ||
3143 | 48 | <td> | ||
3144 | 49 | <table cellpadding="0" cellspacing="0"> | ||
3145 | 50 | <!-- hide/show private --> | ||
3146 | 51 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
3147 | 52 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
3148 | 53 | <tr><td align="right"><span class="options" | ||
3149 | 54 | >[<a href="frames.html" target="_top">frames</a | ||
3150 | 55 | >] | <a href="scriptutil-module.html" | ||
3151 | 56 | target="_top">no frames</a>]</span></td></tr> | ||
3152 | 57 | </table> | ||
3153 | 58 | </td> | ||
3154 | 59 | </tr> | ||
3155 | 60 | </table> | ||
3156 | 61 | <!-- ==================== MODULE DESCRIPTION ==================== --> | ||
3157 | 62 | <h1 class="epydoc">Module scriptutil</h1><span class="codelink"><a href="scriptutil-pysrc.html">source code</a></span><br /><br /> | ||
3158 | 63 | <p>Copyright (c) 2008, Muharem Hrnjadovic</p> | ||
3159 | 64 | <p>All rights reserved.</p> | ||
3160 | 65 | Redistribution and use in source and binary forms, with or without | ||
3161 | 66 | modification, are permitted provided that the following conditions are | ||
3162 | 67 | met: | ||
3163 | 68 | <ul> | ||
3164 | 69 | <li> | ||
3165 | 70 | Redistributions of source code must retain the above copyright | ||
3166 | 71 | notice, this list of conditions and the following disclaimer. | ||
3167 | 72 | </li> | ||
3168 | 73 | <li> | ||
3169 | 74 | Redistributions in binary form must reproduce the above copyright | ||
3170 | 75 | notice, this list of conditions and the following disclaimer in the | ||
3171 | 76 | documentation and/or other materials provided with the | ||
3172 | 77 | distribution. | ||
3173 | 78 | </li> | ||
3174 | 79 | <li> | ||
3175 | 80 | Neither the name of Muharem Hrnjadovic nor the names of other | ||
3176 | 81 | contributors may be used to endorse or promote products derived from | ||
3177 | 82 | this software without specific prior written permission. | ||
3178 | 83 | </li> | ||
3179 | 84 | </ul> | ||
3180 | 85 | <p>THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | ||
3181 | 86 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT | ||
3182 | 87 | NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | ||
3183 | 88 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | ||
3184 | 89 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
3185 | 90 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED | ||
3186 | 91 | TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR | ||
3187 | 92 | PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF | ||
3188 | 93 | LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING | ||
3189 | 94 | NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | ||
3190 | 95 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</p> | ||
3191 | 96 | |||
3192 | 97 | <p>---------------------------------------------------------------------------</p> | ||
3193 | 98 | Module providing functions commonly used in shell scripting: | ||
3194 | 99 | <ul> | ||
3195 | 100 | <li> | ||
3196 | 101 | ffind() : finds files in a directory tree | ||
3197 | 102 | </li> | ||
3198 | 103 | <li> | ||
3199 | 104 | ffindgrep(): finds files in a directory tree and matches their | ||
3200 | 105 | content to regular expressions | ||
3201 | 106 | </li> | ||
3202 | 107 | <li> | ||
3203 | 108 | freplace() : in-place search/replace of files in a directory tree | ||
3204 | 109 | with regular expressions | ||
3205 | 110 | </li> | ||
3206 | 111 | <li> | ||
3207 | 112 | printr() : prints the results of the ffind()/ffindgrep() | ||
3208 | 113 | functions | ||
3209 | 114 | </li> | ||
3210 | 115 | </ul> | ||
3211 | 116 | Please see the <a | ||
3212 | 117 | href="http://muharem.wordpress.com/2007/05/20/python-find-files-using-unix-shell-style-wildcards/" | ||
3213 | 118 | target="_top">tutorial</a> as well as the documentation strings of the | ||
3214 | 119 | particular functions for detailed information.<br /><br /> | ||
3215 | 120 | |||
3216 | 121 | <hr /> | ||
3217 | 122 | <div class="fields"> <p><strong>Version:</strong> | ||
3218 | 123 | 1.1 | ||
3219 | 124 | </p> | ||
3220 | 125 | </div><!-- ==================== CLASSES ==================== --> | ||
3221 | 126 | <a name="section-Classes"></a> | ||
3222 | 127 | <table class="summary" border="1" cellpadding="3" | ||
3223 | 128 | cellspacing="0" width="100%" bgcolor="white"> | ||
3224 | 129 | <tr bgcolor="#70b0f0" class="table-header"> | ||
3225 | 130 | <td colspan="2" class="table-header"> | ||
3226 | 131 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
3227 | 132 | <tr valign="top"> | ||
3228 | 133 | <td align="left"><span class="table-header">Classes</span></td> | ||
3229 | 134 | <td align="right" valign="top" | ||
3230 | 135 | ><span class="options">[<a href="#section-Classes" | ||
3231 | 136 | class="privatelink" onclick="toggle_private();" | ||
3232 | 137 | >hide private</a>]</span></td> | ||
3233 | 138 | </tr> | ||
3234 | 139 | </table> | ||
3235 | 140 | </td> | ||
3236 | 141 | </tr> | ||
3237 | 142 | <tr> | ||
3238 | 143 | <td width="15%" align="right" valign="top" class="summary"> | ||
3239 | 144 | <span class="summary-type"> </span> | ||
3240 | 145 | </td><td class="summary"> | ||
3241 | 146 | <a href="scriptutil.ScriptError-class.html" class="summary-name">ScriptError</a><br /> | ||
3242 | 147 | The exception raised in case of failures. | ||
3243 | 148 | </td> | ||
3244 | 149 | </tr> | ||
3245 | 150 | </table> | ||
3246 | 151 | <!-- ==================== FUNCTIONS ==================== --> | ||
3247 | 152 | <a name="section-Functions"></a> | ||
3248 | 153 | <table class="summary" border="1" cellpadding="3" | ||
3249 | 154 | cellspacing="0" width="100%" bgcolor="white"> | ||
3250 | 155 | <tr bgcolor="#70b0f0" class="table-header"> | ||
3251 | 156 | <td colspan="2" class="table-header"> | ||
3252 | 157 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
3253 | 158 | <tr valign="top"> | ||
3254 | 159 | <td align="left"><span class="table-header">Functions</span></td> | ||
3255 | 160 | <td align="right" valign="top" | ||
3256 | 161 | ><span class="options">[<a href="#section-Functions" | ||
3257 | 162 | class="privatelink" onclick="toggle_private();" | ||
3258 | 163 | >hide private</a>]</span></td> | ||
3259 | 164 | </tr> | ||
3260 | 165 | </table> | ||
3261 | 166 | </td> | ||
3262 | 167 | </tr> | ||
3263 | 168 | <tr> | ||
3264 | 169 | <td width="15%" align="right" valign="top" class="summary"> | ||
3265 | 170 | <span class="summary-type">sequence</span> | ||
3266 | 171 | </td><td class="summary"> | ||
3267 | 172 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3268 | 173 | <tr> | ||
3269 | 174 | <td><span class="summary-sig"><a href="scriptutil-module.html#ffind" class="summary-sig-name">ffind</a>(<span class="summary-sig-arg">path</span>, | ||
3270 | 175 | <span class="summary-sig-arg">shellglobs</span>=<span class="summary-sig-default">None</span>, | ||
3271 | 176 | <span class="summary-sig-arg">namefs</span>=<span class="summary-sig-default">None</span>, | ||
3272 | 177 | <span class="summary-sig-arg">relative</span>=<span class="summary-sig-default">True</span>)</span><br /> | ||
3273 | 178 | Find files in the directory tree starting at 'path' (filtered by | ||
3274 | 179 | Unix shell-style wildcards ('shellglobs') and/or the functions in the | ||
3275 | 180 | 'namefs' sequence).</td> | ||
3276 | 181 | <td align="right" valign="top"> | ||
3277 | 182 | <span class="codelink"><a href="scriptutil-pysrc.html#ffind">source code</a></span> | ||
3278 | 183 | |||
3279 | 184 | </td> | ||
3280 | 185 | </tr> | ||
3281 | 186 | </table> | ||
3282 | 187 | |||
3283 | 188 | </td> | ||
3284 | 189 | </tr> | ||
3285 | 190 | <tr> | ||
3286 | 191 | <td width="15%" align="right" valign="top" class="summary"> | ||
3287 | 192 | <span class="summary-type">dict</span> | ||
3288 | 193 | </td><td class="summary"> | ||
3289 | 194 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3290 | 195 | <tr> | ||
3291 | 196 | <td><span class="summary-sig"><a href="scriptutil-module.html#ffindgrep" class="summary-sig-name">ffindgrep</a>(<span class="summary-sig-arg">path</span>, | ||
3292 | 197 | <span class="summary-sig-arg">regexl</span>, | ||
3293 | 198 | <span class="summary-sig-arg">shellglobs</span>=<span class="summary-sig-default">None</span>, | ||
3294 | 199 | <span class="summary-sig-arg">namefs</span>=<span class="summary-sig-default">None</span>, | ||
3295 | 200 | <span class="summary-sig-arg">relative</span>=<span class="summary-sig-default">True</span>, | ||
3296 | 201 | <span class="summary-sig-arg">linenums</span>=<span class="summary-sig-default">False</span>)</span><br /> | ||
3297 | 202 | Find files in the directory tree starting at 'path' (filtered by | ||
3298 | 203 | Unix shell-style wildcards ('shellglobs') and/or the functions in the | ||
3299 | 204 | 'namefs' sequence) and search inside these.</td> | ||
3300 | 205 | <td align="right" valign="top"> | ||
3301 | 206 | <span class="codelink"><a href="scriptutil-pysrc.html#ffindgrep">source code</a></span> | ||
3302 | 207 | |||
3303 | 208 | </td> | ||
3304 | 209 | </tr> | ||
3305 | 210 | </table> | ||
3306 | 211 | |||
3307 | 212 | </td> | ||
3308 | 213 | </tr> | ||
3309 | 214 | <tr> | ||
3310 | 215 | <td width="15%" align="right" valign="top" class="summary"> | ||
3311 | 216 | <span class="summary-type">number</span> | ||
3312 | 217 | </td><td class="summary"> | ||
3313 | 218 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3314 | 219 | <tr> | ||
3315 | 220 | <td><span class="summary-sig"><a href="scriptutil-module.html#freplace" class="summary-sig-name">freplace</a>(<span class="summary-sig-arg">path</span>, | ||
3316 | 221 | <span class="summary-sig-arg">regexl</span>, | ||
3317 | 222 | <span class="summary-sig-arg">shellglobs</span>=<span class="summary-sig-default">None</span>, | ||
3318 | 223 | <span class="summary-sig-arg">namefs</span>=<span class="summary-sig-default">None</span>, | ||
3319 | 224 | <span class="summary-sig-arg">bext</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">.bak</code><code class="variable-quote">'</code></span>)</span><br /> | ||
3320 | 225 | Find files in the directory tree starting at 'path' (filtered by | ||
3321 | 226 | Unix shell-style wildcards ('shellglobs') and/or the functions in the | ||
3322 | 227 | 'namefs' sequence) and perform an in-place search/replace operation | ||
3323 | 228 | on these.</td> | ||
3324 | 229 | <td align="right" valign="top"> | ||
3325 | 230 | <span class="codelink"><a href="scriptutil-pysrc.html#freplace">source code</a></span> | ||
3326 | 231 | |||
3327 | 232 | </td> | ||
3328 | 233 | </tr> | ||
3329 | 234 | </table> | ||
3330 | 235 | |||
3331 | 236 | </td> | ||
3332 | 237 | </tr> | ||
3333 | 238 | <tr> | ||
3334 | 239 | <td width="15%" align="right" valign="top" class="summary"> | ||
3335 | 240 | <span class="summary-type"> </span> | ||
3336 | 241 | </td><td class="summary"> | ||
3337 | 242 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3338 | 243 | <tr> | ||
3339 | 244 | <td><span class="summary-sig"><a href="scriptutil-module.html#printr" class="summary-sig-name">printr</a>(<span class="summary-sig-arg">results</span>)</span><br /> | ||
3340 | 245 | Print the results of the ffind()/ffindgrep() functions.</td> | ||
3341 | 246 | <td align="right" valign="top"> | ||
3342 | 247 | <span class="codelink"><a href="scriptutil-pysrc.html#printr">source code</a></span> | ||
3343 | 248 | |||
3344 | 249 | </td> | ||
3345 | 250 | </tr> | ||
3346 | 251 | </table> | ||
3347 | 252 | |||
3348 | 253 | </td> | ||
3349 | 254 | </tr> | ||
3350 | 255 | </table> | ||
3351 | 256 | <!-- ==================== FUNCTION DETAILS ==================== --> | ||
3352 | 257 | <a name="section-FunctionDetails"></a> | ||
3353 | 258 | <table class="details" border="1" cellpadding="3" | ||
3354 | 259 | cellspacing="0" width="100%" bgcolor="white"> | ||
3355 | 260 | <tr bgcolor="#70b0f0" class="table-header"> | ||
3356 | 261 | <td colspan="2" class="table-header"> | ||
3357 | 262 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
3358 | 263 | <tr valign="top"> | ||
3359 | 264 | <td align="left"><span class="table-header">Function Details</span></td> | ||
3360 | 265 | <td align="right" valign="top" | ||
3361 | 266 | ><span class="options">[<a href="#section-FunctionDetails" | ||
3362 | 267 | class="privatelink" onclick="toggle_private();" | ||
3363 | 268 | >hide private</a>]</span></td> | ||
3364 | 269 | </tr> | ||
3365 | 270 | </table> | ||
3366 | 271 | </td> | ||
3367 | 272 | </tr> | ||
3368 | 273 | </table> | ||
3369 | 274 | <a name="ffind"></a> | ||
3370 | 275 | <div> | ||
3371 | 276 | <table class="details" border="1" cellpadding="3" | ||
3372 | 277 | cellspacing="0" width="100%" bgcolor="white"> | ||
3373 | 278 | <tr><td> | ||
3374 | 279 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3375 | 280 | <tr valign="top"><td> | ||
3376 | 281 | <h3 class="epydoc"><span class="sig"><span class="sig-name">ffind</span>(<span class="sig-arg">path</span>, | ||
3377 | 282 | <span class="sig-arg">shellglobs</span>=<span class="sig-default">None</span>, | ||
3378 | 283 | <span class="sig-arg">namefs</span>=<span class="sig-default">None</span>, | ||
3379 | 284 | <span class="sig-arg">relative</span>=<span class="sig-default">True</span>)</span> | ||
3380 | 285 | </h3> | ||
3381 | 286 | </td><td align="right" valign="top" | ||
3382 | 287 | ><span class="codelink"><a href="scriptutil-pysrc.html#ffind">source code</a></span> | ||
3383 | 288 | </td> | ||
3384 | 289 | </table> | ||
3385 | 290 | |||
3386 | 291 | <p>Find files in the directory tree starting at 'path' (filtered by Unix | ||
3387 | 292 | shell-style wildcards ('shellglobs') and/or the functions in the 'namefs' | ||
3388 | 293 | sequence).</p> | ||
3389 | 294 | <p>Please not that the shell wildcards work in a cumulative fashion i.e. | ||
3390 | 295 | each of them is applied to the full set of file *names* found.</p> | ||
3391 | 296 | Conversely, all the functions in 'namefs' | ||
3392 | 297 | <ul> | ||
3393 | 298 | <li> | ||
3394 | 299 | only get to see the output of their respective predecessor | ||
3395 | 300 | function in the sequence (with the obvious exception of the first | ||
3396 | 301 | function) | ||
3397 | 302 | </li> | ||
3398 | 303 | <li> | ||
3399 | 304 | are applied to the full file *path* (whereas the shell-style | ||
3400 | 305 | wildcards are only applied to the file *names*) | ||
3401 | 306 | </li> | ||
3402 | 307 | </ul> | ||
3403 | 308 | <dl class="fields"> | ||
3404 | 309 | <dt>Parameters:</dt> | ||
3405 | 310 | <dd><ul class="nomargin-top"> | ||
3406 | 311 | <li><strong class="pname"><code>path</code></strong> (string) - starting path of the directory tree to be searched</li> | ||
3407 | 312 | <li><strong class="pname"><code>shellglobs</code></strong> (sequence) - an optional sequence of Unix shell-style wildcards that are to | ||
3408 | 313 | be applied to the file *names* found</li> | ||
3409 | 314 | <li><strong class="pname"><code>namefs</code></strong> (sequence) - an optional sequence of functions to be applied to the file | ||
3410 | 315 | *paths* found</li> | ||
3411 | 316 | <li><strong class="pname"><code>relative</code></strong> (bool) - a boolean flag that determines whether absolute or relative | ||
3412 | 317 | paths should be returned</li> | ||
3413 | 318 | </ul></dd> | ||
3414 | 319 | <dt>Returns: sequence</dt> | ||
3415 | 320 | <dd>paths for files found</dd> | ||
3416 | 321 | </dl> | ||
3417 | 322 | </td></tr></table> | ||
3418 | 323 | </div> | ||
3419 | 324 | <a name="ffindgrep"></a> | ||
3420 | 325 | <div> | ||
3421 | 326 | <table class="details" border="1" cellpadding="3" | ||
3422 | 327 | cellspacing="0" width="100%" bgcolor="white"> | ||
3423 | 328 | <tr><td> | ||
3424 | 329 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3425 | 330 | <tr valign="top"><td> | ||
3426 | 331 | <h3 class="epydoc"><span class="sig"><span class="sig-name">ffindgrep</span>(<span class="sig-arg">path</span>, | ||
3427 | 332 | <span class="sig-arg">regexl</span>, | ||
3428 | 333 | <span class="sig-arg">shellglobs</span>=<span class="sig-default">None</span>, | ||
3429 | 334 | <span class="sig-arg">namefs</span>=<span class="sig-default">None</span>, | ||
3430 | 335 | <span class="sig-arg">relative</span>=<span class="sig-default">True</span>, | ||
3431 | 336 | <span class="sig-arg">linenums</span>=<span class="sig-default">False</span>)</span> | ||
3432 | 337 | </h3> | ||
3433 | 338 | </td><td align="right" valign="top" | ||
3434 | 339 | ><span class="codelink"><a href="scriptutil-pysrc.html#ffindgrep">source code</a></span> | ||
3435 | 340 | </td> | ||
3436 | 341 | </table> | ||
3437 | 342 | |||
3438 | 343 | <p>Find files in the directory tree starting at 'path' (filtered by Unix | ||
3439 | 344 | shell-style wildcards ('shellglobs') and/or the functions in the 'namefs' | ||
3440 | 345 | sequence) and search inside these.</p> | ||
3441 | 346 | Additionaly, the file content will be filtered by the regular | ||
3442 | 347 | expressions in the 'regexl' sequence. Each entry in the latter is a | ||
3443 | 348 | <ul> | ||
3444 | 349 | <li> | ||
3445 | 350 | either a string (with the regex definition) | ||
3446 | 351 | </li> | ||
3447 | 352 | <li> | ||
3448 | 353 | or a tuple with arguments accepted by re.compile() (the re.M and | ||
3449 | 354 | re.S flags will have no effect though) | ||
3450 | 355 | </li> | ||
3451 | 356 | </ul> | ||
3452 | 357 | For all the files that pass the file name/content tests the function | ||
3453 | 358 | returns a dictionary where the | ||
3454 | 359 | <ul> | ||
3455 | 360 | <li> | ||
3456 | 361 | key is the file name and the | ||
3457 | 362 | </li> | ||
3458 | 363 | <li> | ||
3459 | 364 | value is a string with lines filtered by 'regexl' | ||
3460 | 365 | </li> | ||
3461 | 366 | </ul> | ||
3462 | 367 | <dl class="fields"> | ||
3463 | 368 | <dt>Parameters:</dt> | ||
3464 | 369 | <dd><ul class="nomargin-top"> | ||
3465 | 370 | <li><strong class="pname"><code>path</code></strong> (string) - starting path of the directory tree to be searched</li> | ||
3466 | 371 | <li><strong class="pname"><code>shellglobs</code></strong> (sequence) - an optional sequence of Unix shell-style wildcards that are to | ||
3467 | 372 | be applied to the file *names* found</li> | ||
3468 | 373 | <li><strong class="pname"><code>namefs</code></strong> (sequence) - an optional sequence of functions to be applied to the file | ||
3469 | 374 | *paths* found</li> | ||
3470 | 375 | <li><strong class="pname"><code>relative</code></strong> (bool) - a boolean flag that determines whether absolute or relative | ||
3471 | 376 | paths should be returned</li> | ||
3472 | 377 | <li><strong class="pname"><code>linenums</code></strong> (bool) - turns on line numbers for found files (like grep -n)</li> | ||
3473 | 378 | </ul></dd> | ||
3474 | 379 | <dt>Returns: dict</dt> | ||
3475 | 380 | <dd>file name (key) and lines filtered by 'regexl' (value)</dd> | ||
3476 | 381 | </dl> | ||
3477 | 382 | </td></tr></table> | ||
3478 | 383 | </div> | ||
3479 | 384 | <a name="freplace"></a> | ||
3480 | 385 | <div> | ||
3481 | 386 | <table class="details" border="1" cellpadding="3" | ||
3482 | 387 | cellspacing="0" width="100%" bgcolor="white"> | ||
3483 | 388 | <tr><td> | ||
3484 | 389 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3485 | 390 | <tr valign="top"><td> | ||
3486 | 391 | <h3 class="epydoc"><span class="sig"><span class="sig-name">freplace</span>(<span class="sig-arg">path</span>, | ||
3487 | 392 | <span class="sig-arg">regexl</span>, | ||
3488 | 393 | <span class="sig-arg">shellglobs</span>=<span class="sig-default">None</span>, | ||
3489 | 394 | <span class="sig-arg">namefs</span>=<span class="sig-default">None</span>, | ||
3490 | 395 | <span class="sig-arg">bext</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">.bak</code><code class="variable-quote">'</code></span>)</span> | ||
3491 | 396 | </h3> | ||
3492 | 397 | </td><td align="right" valign="top" | ||
3493 | 398 | ><span class="codelink"><a href="scriptutil-pysrc.html#freplace">source code</a></span> | ||
3494 | 399 | </td> | ||
3495 | 400 | </table> | ||
3496 | 401 | |||
3497 | 402 | <p>Find files in the directory tree starting at 'path' (filtered by Unix | ||
3498 | 403 | shell-style wildcards ('shellglobs') and/or the functions in the 'namefs' | ||
3499 | 404 | sequence) and perform an in-place search/replace operation on these.</p> | ||
3500 | 405 | <p>Additionally, an in-place search/replace operation is performed on the | ||
3501 | 406 | content of all the files (whose names passed the tests) using the regular | ||
3502 | 407 | expressions in 'regexl'.</p> | ||
3503 | 408 | Please note: 'regexl' is a sequence of 3-tuples, each having the | ||
3504 | 409 | following elements: | ||
3505 | 410 | <ul> | ||
3506 | 411 | <li> | ||
3507 | 412 | search string (Python regex syntax) | ||
3508 | 413 | </li> | ||
3509 | 414 | <li> | ||
3510 | 415 | replace string (Python regex syntax) | ||
3511 | 416 | </li> | ||
3512 | 417 | <li> | ||
3513 | 418 | regex flags or 'None' (re.compile syntax) | ||
3514 | 419 | </li> | ||
3515 | 420 | </ul> | ||
3516 | 421 | Copies of the modified files are saved in backup files using the | ||
3517 | 422 | extension specified in 'bext'. | ||
3518 | 423 | <dl class="fields"> | ||
3519 | 424 | <dt>Parameters:</dt> | ||
3520 | 425 | <dd><ul class="nomargin-top"> | ||
3521 | 426 | <li><strong class="pname"><code>path</code></strong> (string) - starting path of the directory tree to be searched</li> | ||
3522 | 427 | <li><strong class="pname"><code>shellglobs</code></strong> (sequence) - an optional sequence of Unix shell-style wildcards that are to | ||
3523 | 428 | be applied to the file *names* found</li> | ||
3524 | 429 | <li><strong class="pname"><code>namefs</code></strong> (sequence) - an optional sequence of functions to be applied to the file | ||
3525 | 430 | *paths* found</li> | ||
3526 | 431 | </ul></dd> | ||
3527 | 432 | <dt>Returns: number</dt> | ||
3528 | 433 | <dd>total number of files modified</dd> | ||
3529 | 434 | </dl> | ||
3530 | 435 | </td></tr></table> | ||
3531 | 436 | </div> | ||
3532 | 437 | <a name="printr"></a> | ||
3533 | 438 | <div> | ||
3534 | 439 | <table class="details" border="1" cellpadding="3" | ||
3535 | 440 | cellspacing="0" width="100%" bgcolor="white"> | ||
3536 | 441 | <tr><td> | ||
3537 | 442 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
3538 | 443 | <tr valign="top"><td> | ||
3539 | 444 | <h3 class="epydoc"><span class="sig"><span class="sig-name">printr</span>(<span class="sig-arg">results</span>)</span> | ||
3540 | 445 | </h3> | ||
3541 | 446 | </td><td align="right" valign="top" | ||
3542 | 447 | ><span class="codelink"><a href="scriptutil-pysrc.html#printr">source code</a></span> | ||
3543 | 448 | </td> | ||
3544 | 449 | </table> | ||
3545 | 450 | |||
3546 | 451 | <p>Print the results of the ffind()/ffindgrep() functions.</p> | ||
3547 | 452 | The output format is similar to the one used by the UNIX find | ||
3548 | 453 | utility. | ||
3549 | 454 | <dl class="fields"> | ||
3550 | 455 | </dl> | ||
3551 | 456 | </td></tr></table> | ||
3552 | 457 | </div> | ||
3553 | 458 | <br /> | ||
3554 | 459 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
3555 | 460 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
3556 | 461 | bgcolor="#a0c0ff" cellspacing="0"> | ||
3557 | 462 | <tr valign="middle"> | ||
3558 | 463 | <!-- Home link --> | ||
3559 | 464 | <th bgcolor="#70b0f0" class="navbar-select" | ||
3560 | 465 | > Home </th> | ||
3561 | 466 | |||
3562 | 467 | <!-- Tree link --> | ||
3563 | 468 | <th> <a | ||
3564 | 469 | href="module-tree.html">Trees</a> </th> | ||
3565 | 470 | |||
3566 | 471 | <!-- Index link --> | ||
3567 | 472 | <th> <a | ||
3568 | 473 | href="identifier-index.html">Indices</a> </th> | ||
3569 | 474 | |||
3570 | 475 | <!-- Help link --> | ||
3571 | 476 | <th> <a | ||
3572 | 477 | href="help.html">Help</a> </th> | ||
3573 | 478 | |||
3574 | 479 | <!-- Project homepage --> | ||
3575 | 480 | <th class="navbar" align="right" width="100%"> | ||
3576 | 481 | <table border="0" cellpadding="0" cellspacing="0"> | ||
3577 | 482 | <tr><th class="navbar" align="center" | ||
3578 | 483 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
3579 | 484 | </tr></table></th> | ||
3580 | 485 | </tr> | ||
3581 | 486 | </table> | ||
3582 | 487 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
3583 | 488 | <tr> | ||
3584 | 489 | <td align="left" class="footer"> | ||
3585 | 490 | Generated by Epydoc 3.0beta1 on Thu May 22 18:10:51 2008 | ||
3586 | 491 | </td> | ||
3587 | 492 | <td align="right" class="footer"> | ||
3588 | 493 | <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a> | ||
3589 | 494 | </td> | ||
3590 | 495 | </tr> | ||
3591 | 496 | </table> | ||
3592 | 497 | |||
3593 | 498 | <script type="text/javascript"> | ||
3594 | 499 | <!-- | ||
3595 | 500 | // Private objects are initially displayed (because if | ||
3596 | 501 | // javascript is turned off then we want them to be | ||
3597 | 502 | // visible); but by default, we want to hide them. So hide | ||
3598 | 503 | // them unless we have a cookie that says to show them. | ||
3599 | 504 | checkCookie() | ||
3600 | 505 | // --> | ||
3601 | 506 | </script> | ||
3602 | 507 | |||
3603 | 508 | </body> | ||
3604 | 509 | </html> | ||
3605 | 510 | 0 | ||
3606 | === added file 'doc/html/scriptutil-pysrc.html' | |||
3607 | --- doc/html/scriptutil-pysrc.html 1970-01-01 00:00:00 +0000 | |||
3608 | +++ doc/html/scriptutil-pysrc.html 2009-12-26 22:06:14 +0000 | |||
3609 | @@ -0,0 +1,121 @@ | |||
3610 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
3611 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
3612 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
3613 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
3614 | 5 | <head> | ||
3615 | 6 | <title>scriptutil</title> | ||
3616 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
3617 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
3618 | 9 | </head> | ||
3619 | 10 | |||
3620 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
3621 | 12 | alink="#204080"> | ||
3622 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
3623 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
3624 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
3625 | 16 | <tr valign="middle"> | ||
3626 | 17 | <!-- Home link --> | ||
3627 | 18 | <th bgcolor="#70b0f0" class="navbar-select" | ||
3628 | 19 | > Home </th> | ||
3629 | 20 | |||
3630 | 21 | <!-- Tree link --> | ||
3631 | 22 | <th> <a | ||
3632 | 23 | href="module-tree.html">Trees</a> </th> | ||
3633 | 24 | |||
3634 | 25 | <!-- Index link --> | ||
3635 | 26 | <th> <a | ||
3636 | 27 | href="identifier-index.html">Indices</a> </th> | ||
3637 | 28 | |||
3638 | 29 | <!-- Help link --> | ||
3639 | 30 | <th> <a | ||
3640 | 31 | href="help.html">Help</a> </th> | ||
3641 | 32 | |||
3642 | 33 | <!-- Project homepage --> | ||
3643 | 34 | <th class="navbar" align="right" width="100%"> | ||
3644 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
3645 | 36 | <tr><th class="navbar" align="center" | ||
3646 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
3647 | 38 | </tr></table></th> | ||
3648 | 39 | </tr> | ||
3649 | 40 | </table> | ||
3650 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
3651 | 42 | <tr valign="top"> | ||
3652 | 43 | <td width="100%"> | ||
3653 | 44 | <span class="breadcrumbs"> | ||
3654 | 45 | Package scriptutil | ||
3655 | 46 | </span> | ||
3656 | 47 | </td> | ||
3657 | 48 | <td> | ||
3658 | 49 | <table cellpadding="0" cellspacing="0"> | ||
3659 | 50 | <!-- hide/show private --> | ||
3660 | 51 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
3661 | 52 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
3662 | 53 | <tr><td align="right"><span class="options" | ||
3663 | 54 | >[<a href="frames.html" target="_top">frames</a | ||
3664 | 55 | >] | <a href="scriptutil-pysrc.html" | ||
3665 | 56 | target="_top">no frames</a>]</span></td></tr> | ||
3666 | 57 | </table> | ||
3667 | 58 | </td> | ||
3668 | 59 | </tr> | ||
3669 | 60 | </table> | ||
3670 | 61 | <h1 class="epydoc">Source Code for <a href="scriptutil-module.html">Package scriptutil</a></h1> | ||
3671 | 62 | <pre class="py-src"> | ||
3672 | 63 | <a name="L1"></a><tt class="py-lineno">1</tt> <tt class="py-line"> </tt> | ||
3673 | 64 | <a name="L2"></a><tt class="py-lineno">2</tt> <tt class="py-line"> </tt><script type="text/javascript"> | ||
3674 | 65 | <!-- | ||
3675 | 66 | expandto(location.href); | ||
3676 | 67 | // --> | ||
3677 | 68 | </script> | ||
3678 | 69 | </pre> | ||
3679 | 70 | <br /> | ||
3680 | 71 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
3681 | 72 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
3682 | 73 | bgcolor="#a0c0ff" cellspacing="0"> | ||
3683 | 74 | <tr valign="middle"> | ||
3684 | 75 | <!-- Home link --> | ||
3685 | 76 | <th bgcolor="#70b0f0" class="navbar-select" | ||
3686 | 77 | > Home </th> | ||
3687 | 78 | |||
3688 | 79 | <!-- Tree link --> | ||
3689 | 80 | <th> <a | ||
3690 | 81 | href="module-tree.html">Trees</a> </th> | ||
3691 | 82 | |||
3692 | 83 | <!-- Index link --> | ||
3693 | 84 | <th> <a | ||
3694 | 85 | href="identifier-index.html">Indices</a> </th> | ||
3695 | 86 | |||
3696 | 87 | <!-- Help link --> | ||
3697 | 88 | <th> <a | ||
3698 | 89 | href="help.html">Help</a> </th> | ||
3699 | 90 | |||
3700 | 91 | <!-- Project homepage --> | ||
3701 | 92 | <th class="navbar" align="right" width="100%"> | ||
3702 | 93 | <table border="0" cellpadding="0" cellspacing="0"> | ||
3703 | 94 | <tr><th class="navbar" align="center" | ||
3704 | 95 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
3705 | 96 | </tr></table></th> | ||
3706 | 97 | </tr> | ||
3707 | 98 | </table> | ||
3708 | 99 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
3709 | 100 | <tr> | ||
3710 | 101 | <td align="left" class="footer"> | ||
3711 | 102 | Generated by Epydoc 3.0.1 on Sat Dec 26 23:01:34 2009 | ||
3712 | 103 | </td> | ||
3713 | 104 | <td align="right" class="footer"> | ||
3714 | 105 | <a target="mainFrame" href="http://epydoc.sourceforge.net" | ||
3715 | 106 | >http://epydoc.sourceforge.net</a> | ||
3716 | 107 | </td> | ||
3717 | 108 | </tr> | ||
3718 | 109 | </table> | ||
3719 | 110 | |||
3720 | 111 | <script type="text/javascript"> | ||
3721 | 112 | <!-- | ||
3722 | 113 | // Private objects are initially displayed (because if | ||
3723 | 114 | // javascript is turned off then we want them to be | ||
3724 | 115 | // visible); but by default, we want to hide them. So hide | ||
3725 | 116 | // them unless we have a cookie that says to show them. | ||
3726 | 117 | checkCookie(); | ||
3727 | 118 | // --> | ||
3728 | 119 | </script> | ||
3729 | 120 | </body> | ||
3730 | 121 | </html> | ||
3731 | 0 | 122 | ||
3732 | === removed file 'doc/html/scriptutil-pysrc.html' | |||
3733 | --- doc/html/scriptutil-pysrc.html 2009-12-26 20:49:38 +0000 | |||
3734 | +++ doc/html/scriptutil-pysrc.html 1970-01-01 00:00:00 +0000 | |||
3735 | @@ -1,388 +0,0 @@ | |||
3736 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
3737 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
3738 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
3739 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
3740 | 5 | <head> | ||
3741 | 6 | <title>scriptutil</title> | ||
3742 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
3743 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
3744 | 9 | </head> | ||
3745 | 10 | |||
3746 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
3747 | 12 | alink="#204080"> | ||
3748 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
3749 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
3750 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
3751 | 16 | <tr valign="middle"> | ||
3752 | 17 | <!-- Home link --> | ||
3753 | 18 | <th bgcolor="#70b0f0" class="navbar-select" | ||
3754 | 19 | > Home </th> | ||
3755 | 20 | |||
3756 | 21 | <!-- Tree link --> | ||
3757 | 22 | <th> <a | ||
3758 | 23 | href="module-tree.html">Trees</a> </th> | ||
3759 | 24 | |||
3760 | 25 | <!-- Index link --> | ||
3761 | 26 | <th> <a | ||
3762 | 27 | href="identifier-index.html">Indices</a> </th> | ||
3763 | 28 | |||
3764 | 29 | <!-- Help link --> | ||
3765 | 30 | <th> <a | ||
3766 | 31 | href="help.html">Help</a> </th> | ||
3767 | 32 | |||
3768 | 33 | <!-- Project homepage --> | ||
3769 | 34 | <th class="navbar" align="right" width="100%"> | ||
3770 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
3771 | 36 | <tr><th class="navbar" align="center" | ||
3772 | 37 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
3773 | 38 | </tr></table></th> | ||
3774 | 39 | </tr> | ||
3775 | 40 | </table> | ||
3776 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
3777 | 42 | <tr valign="top"> | ||
3778 | 43 | <td width="100%"> | ||
3779 | 44 | <span class="breadcrumbs"> | ||
3780 | 45 | Script scriptutil | ||
3781 | 46 | </span> | ||
3782 | 47 | </td> | ||
3783 | 48 | <td> | ||
3784 | 49 | <table cellpadding="0" cellspacing="0"> | ||
3785 | 50 | <!-- hide/show private --> | ||
3786 | 51 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
3787 | 52 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
3788 | 53 | <tr><td align="right"><span class="options" | ||
3789 | 54 | >[<a href="frames.html" target="_top">frames</a | ||
3790 | 55 | >] | <a href="scriptutil-pysrc.html" | ||
3791 | 56 | target="_top">no frames</a>]</span></td></tr> | ||
3792 | 57 | </table> | ||
3793 | 58 | </td> | ||
3794 | 59 | </tr> | ||
3795 | 60 | </table> | ||
3796 | 61 | <h1 class="epydoc">Source Code for <a href="scriptutil-module.html">Script scriptutil</a></h1> | ||
3797 | 62 | <pre class="py-src"> | ||
3798 | 63 | <a name="L1"></a><tt class="py-lineno"> 1</tt> <tt class="py-line"><tt class="py-comment">#!/usr/bin/env python</tt> </tt> | ||
3799 | 64 | <a name="L2"></a><tt class="py-lineno"> 2</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># encoding: utf-8</tt> </tt> | ||
3800 | 65 | <a name="L3"></a><tt class="py-lineno"> 3</tt> <tt class="py-line"><tt class="py-comment"></tt> </tt> | ||
3801 | 66 | <a name="L4"></a><tt class="py-lineno"> 4</tt> <tt class="py-line"><tt class="py-docstring">"""</tt> </tt> | ||
3802 | 67 | <a name="L5"></a><tt class="py-lineno"> 5</tt> <tt class="py-line"><tt class="py-docstring">Copyright (c) 2008, Muharem Hrnjadovic</tt> </tt> | ||
3803 | 68 | <a name="L6"></a><tt class="py-lineno"> 6</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3804 | 69 | <a name="L7"></a><tt class="py-lineno"> 7</tt> <tt class="py-line"><tt class="py-docstring">All rights reserved.</tt> </tt> | ||
3805 | 70 | <a name="L8"></a><tt class="py-lineno"> 8</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3806 | 71 | <a name="L9"></a><tt class="py-lineno"> 9</tt> <tt class="py-line"><tt class="py-docstring">Redistribution and use in source and binary forms, with or without </tt> </tt> | ||
3807 | 72 | <a name="L10"></a><tt class="py-lineno"> 10</tt> <tt class="py-line"><tt class="py-docstring">modification, are permitted provided that the following conditions</tt> </tt> | ||
3808 | 73 | <a name="L11"></a><tt class="py-lineno"> 11</tt> <tt class="py-line"><tt class="py-docstring">are met:</tt> </tt> | ||
3809 | 74 | <a name="L12"></a><tt class="py-lineno"> 12</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3810 | 75 | <a name="L13"></a><tt class="py-lineno"> 13</tt> <tt class="py-line"><tt class="py-docstring"> - Redistributions of source code must retain the above copyright notice,</tt> </tt> | ||
3811 | 76 | <a name="L14"></a><tt class="py-lineno"> 14</tt> <tt class="py-line"><tt class="py-docstring"> this list of conditions and the following disclaimer.</tt> </tt> | ||
3812 | 77 | <a name="L15"></a><tt class="py-lineno"> 15</tt> <tt class="py-line"><tt class="py-docstring"> - Redistributions in binary form must reproduce the above copyright</tt> </tt> | ||
3813 | 78 | <a name="L16"></a><tt class="py-lineno"> 16</tt> <tt class="py-line"><tt class="py-docstring"> notice, this list of conditions and the following disclaimer in the</tt> </tt> | ||
3814 | 79 | <a name="L17"></a><tt class="py-lineno"> 17</tt> <tt class="py-line"><tt class="py-docstring"> documentation and/or other materials provided with the distribution.</tt> </tt> | ||
3815 | 80 | <a name="L18"></a><tt class="py-lineno"> 18</tt> <tt class="py-line"><tt class="py-docstring"> - Neither the name of Muharem Hrnjadovic nor the names of other</tt> </tt> | ||
3816 | 81 | <a name="L19"></a><tt class="py-lineno"> 19</tt> <tt class="py-line"><tt class="py-docstring"> contributors may be used to endorse or promote products derived from</tt> </tt> | ||
3817 | 82 | <a name="L20"></a><tt class="py-lineno"> 20</tt> <tt class="py-line"><tt class="py-docstring"> this software without specific prior written permission.</tt> </tt> | ||
3818 | 83 | <a name="L21"></a><tt class="py-lineno"> 21</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3819 | 84 | <a name="L22"></a><tt class="py-lineno"> 22</tt> <tt class="py-line"><tt class="py-docstring">THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS</tt> </tt> | ||
3820 | 85 | <a name="L23"></a><tt class="py-lineno"> 23</tt> <tt class="py-line"><tt class="py-docstring">"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT</tt> </tt> | ||
3821 | 86 | <a name="L24"></a><tt class="py-lineno"> 24</tt> <tt class="py-line"><tt class="py-docstring">LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR</tt> </tt> | ||
3822 | 87 | <a name="L25"></a><tt class="py-lineno"> 25</tt> <tt class="py-line"><tt class="py-docstring">A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR</tt> </tt> | ||
3823 | 88 | <a name="L26"></a><tt class="py-lineno"> 26</tt> <tt class="py-line"><tt class="py-docstring">CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,</tt> </tt> | ||
3824 | 89 | <a name="L27"></a><tt class="py-lineno"> 27</tt> <tt class="py-line"><tt class="py-docstring">EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,</tt> </tt> | ||
3825 | 90 | <a name="L28"></a><tt class="py-lineno"> 28</tt> <tt class="py-line"><tt class="py-docstring">PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR</tt> </tt> | ||
3826 | 91 | <a name="L29"></a><tt class="py-lineno"> 29</tt> <tt class="py-line"><tt class="py-docstring">PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF</tt> </tt> | ||
3827 | 92 | <a name="L30"></a><tt class="py-lineno"> 30</tt> <tt class="py-line"><tt class="py-docstring">LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING</tt> </tt> | ||
3828 | 93 | <a name="L31"></a><tt class="py-lineno"> 31</tt> <tt class="py-line"><tt class="py-docstring">NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS</tt> </tt> | ||
3829 | 94 | <a name="L32"></a><tt class="py-lineno"> 32</tt> <tt class="py-line"><tt class="py-docstring">SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</tt> </tt> | ||
3830 | 95 | <a name="L33"></a><tt class="py-lineno"> 33</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3831 | 96 | <a name="L34"></a><tt class="py-lineno"> 34</tt> <tt class="py-line"><tt class="py-docstring">---------------------------------------------------------------------------</tt> </tt> | ||
3832 | 97 | <a name="L35"></a><tt class="py-lineno"> 35</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3833 | 98 | <a name="L36"></a><tt class="py-lineno"> 36</tt> <tt class="py-line"><tt class="py-docstring">Module providing functions commonly used in shell scripting:</tt> </tt> | ||
3834 | 99 | <a name="L37"></a><tt class="py-lineno"> 37</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3835 | 100 | <a name="L38"></a><tt class="py-lineno"> 38</tt> <tt class="py-line"><tt class="py-docstring"> - ffind() : finds files in a directory tree</tt> </tt> | ||
3836 | 101 | <a name="L39"></a><tt class="py-lineno"> 39</tt> <tt class="py-line"><tt class="py-docstring"> - ffindgrep(): finds files in a directory tree and matches their</tt> </tt> | ||
3837 | 102 | <a name="L40"></a><tt class="py-lineno"> 40</tt> <tt class="py-line"><tt class="py-docstring"> content to regular expressions</tt> </tt> | ||
3838 | 103 | <a name="L41"></a><tt class="py-lineno"> 41</tt> <tt class="py-line"><tt class="py-docstring"> - freplace() : in-place search/replace of files in a directory tree</tt> </tt> | ||
3839 | 104 | <a name="L42"></a><tt class="py-lineno"> 42</tt> <tt class="py-line"><tt class="py-docstring"> with regular expressions</tt> </tt> | ||
3840 | 105 | <a name="L43"></a><tt class="py-lineno"> 43</tt> <tt class="py-line"><tt class="py-docstring"> - printr() : prints the results of the ffind()/ffindgrep() functions</tt> </tt> | ||
3841 | 106 | <a name="L44"></a><tt class="py-lineno"> 44</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3842 | 107 | <a name="L45"></a><tt class="py-lineno"> 45</tt> <tt class="py-line"><tt class="py-docstring">Please see the U{tutorial <http://muharem.wordpress.com/2007/05/20/python-find-files-using-unix-shell-style-wildcards/>} as well as the documentation strings of the particular functions for detailed information.</tt> </tt> | ||
3843 | 108 | <a name="L46"></a><tt class="py-lineno"> 46</tt> <tt class="py-line"><tt class="py-docstring">"""</tt> </tt> | ||
3844 | 109 | <a name="L47"></a><tt class="py-lineno"> 47</tt> <tt class="py-line"> </tt> | ||
3845 | 110 | <a name="L48"></a><tt class="py-lineno"> 48</tt> <tt class="py-line"><tt class="py-name">__version__</tt> <tt class="py-op">=</tt> <tt class="py-string">"1.1"</tt> </tt> | ||
3846 | 111 | <a name="L49"></a><tt class="py-lineno"> 49</tt> <tt class="py-line"> </tt> | ||
3847 | 112 | <a name="L50"></a><tt class="py-lineno"> 50</tt> <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">fnmatch</tt><tt class="py-op">,</tt> <tt class="py-name">itertools</tt><tt class="py-op">,</tt> <tt class="py-name">os</tt><tt class="py-op">,</tt> <tt class="py-name">sys</tt><tt class="py-op">,</tt> <tt class="py-name">re</tt><tt class="py-op">,</tt> <tt class="py-name">types</tt> </tt> | ||
3848 | 113 | <a name="L51"></a><tt class="py-lineno"> 51</tt> <tt class="py-line"> </tt> | ||
3849 | 114 | <a name="ScriptError"></a><div id="ScriptError-def"><a name="L52"></a><tt class="py-lineno"> 52</tt> <a class="py-toggle" href="#" id="ScriptError-toggle" onclick="return toggle('ScriptError');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="scriptutil.ScriptError-class.html">ScriptError</a><tt class="py-op">(</tt><tt class="py-base-class">Exception</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
3850 | 115 | </div><div id="ScriptError-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="ScriptError-expanded"><a name="L53"></a><tt class="py-lineno"> 53</tt> <tt class="py-line"> <tt class="py-docstring">"""The exception raised in case of failures."""</tt> </tt> | ||
3851 | 116 | </div><a name="L54"></a><tt class="py-lineno"> 54</tt> <tt class="py-line"> </tt> | ||
3852 | 117 | <a name="ffind"></a><div id="ffind-def"><a name="L55"></a><tt class="py-lineno"> 55</tt> <a class="py-toggle" href="#" id="ffind-toggle" onclick="return toggle('ffind');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="scriptutil-module.html#ffind">ffind</a><tt class="py-op">(</tt><tt class="py-param">path</tt><tt class="py-op">,</tt> <tt class="py-param">shellglobs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">namefs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">relative</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
3853 | 118 | </div><div id="ffind-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="ffind-expanded"><a name="L56"></a><tt class="py-lineno"> 56</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt> | ||
3854 | 119 | <a name="L57"></a><tt class="py-lineno"> 57</tt> <tt class="py-line"><tt class="py-docstring"> Find files in the directory tree starting at 'path' (filtered by</tt> </tt> | ||
3855 | 120 | <a name="L58"></a><tt class="py-lineno"> 58</tt> <tt class="py-line"><tt class="py-docstring"> Unix shell-style wildcards ('shellglobs') and/or the functions in</tt> </tt> | ||
3856 | 121 | <a name="L59"></a><tt class="py-lineno"> 59</tt> <tt class="py-line"><tt class="py-docstring"> the 'namefs' sequence).</tt> </tt> | ||
3857 | 122 | <a name="L60"></a><tt class="py-lineno"> 60</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3858 | 123 | <a name="L61"></a><tt class="py-lineno"> 61</tt> <tt class="py-line"><tt class="py-docstring"> Please not that the shell wildcards work in a cumulative fashion</tt> </tt> | ||
3859 | 124 | <a name="L62"></a><tt class="py-lineno"> 62</tt> <tt class="py-line"><tt class="py-docstring"> i.e. each of them is applied to the full set of file *names* found.</tt> </tt> | ||
3860 | 125 | <a name="L63"></a><tt class="py-lineno"> 63</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3861 | 126 | <a name="L64"></a><tt class="py-lineno"> 64</tt> <tt class="py-line"><tt class="py-docstring"> Conversely, all the functions in 'namefs'</tt> </tt> | ||
3862 | 127 | <a name="L65"></a><tt class="py-lineno"> 65</tt> <tt class="py-line"><tt class="py-docstring"> - only get to see the output of their respective predecessor</tt> </tt> | ||
3863 | 128 | <a name="L66"></a><tt class="py-lineno"> 66</tt> <tt class="py-line"><tt class="py-docstring"> function in the sequence (with the obvious exception of the</tt> </tt> | ||
3864 | 129 | <a name="L67"></a><tt class="py-lineno"> 67</tt> <tt class="py-line"><tt class="py-docstring"> first function)</tt> </tt> | ||
3865 | 130 | <a name="L68"></a><tt class="py-lineno"> 68</tt> <tt class="py-line"><tt class="py-docstring"> - are applied to the full file *path* (whereas the shell-style</tt> </tt> | ||
3866 | 131 | <a name="L69"></a><tt class="py-lineno"> 69</tt> <tt class="py-line"><tt class="py-docstring"> wildcards are only applied to the file *names*)</tt> </tt> | ||
3867 | 132 | <a name="L70"></a><tt class="py-lineno"> 70</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3868 | 133 | <a name="L71"></a><tt class="py-lineno"> 71</tt> <tt class="py-line"><tt class="py-docstring"> @type path: string</tt> </tt> | ||
3869 | 134 | <a name="L72"></a><tt class="py-lineno"> 72</tt> <tt class="py-line"><tt class="py-docstring"> @param path: starting path of the directory tree to be searched</tt> </tt> | ||
3870 | 135 | <a name="L73"></a><tt class="py-lineno"> 73</tt> <tt class="py-line"><tt class="py-docstring"> @type shellglobs: sequence</tt> </tt> | ||
3871 | 136 | <a name="L74"></a><tt class="py-lineno"> 74</tt> <tt class="py-line"><tt class="py-docstring"> @param shellglobs: an optional sequence of Unix shell-style wildcards</tt> </tt> | ||
3872 | 137 | <a name="L75"></a><tt class="py-lineno"> 75</tt> <tt class="py-line"><tt class="py-docstring"> that are to be applied to the file *names* found</tt> </tt> | ||
3873 | 138 | <a name="L76"></a><tt class="py-lineno"> 76</tt> <tt class="py-line"><tt class="py-docstring"> @type namefs: sequence</tt> </tt> | ||
3874 | 139 | <a name="L77"></a><tt class="py-lineno"> 77</tt> <tt class="py-line"><tt class="py-docstring"> @param namefs: an optional sequence of functions to be applied to the</tt> </tt> | ||
3875 | 140 | <a name="L78"></a><tt class="py-lineno"> 78</tt> <tt class="py-line"><tt class="py-docstring"> file *paths* found</tt> </tt> | ||
3876 | 141 | <a name="L79"></a><tt class="py-lineno"> 79</tt> <tt class="py-line"><tt class="py-docstring"> @type relative: bool</tt> </tt> | ||
3877 | 142 | <a name="L80"></a><tt class="py-lineno"> 80</tt> <tt class="py-line"><tt class="py-docstring"> @param relative: a boolean flag that determines whether absolute or</tt> </tt> | ||
3878 | 143 | <a name="L81"></a><tt class="py-lineno"> 81</tt> <tt class="py-line"><tt class="py-docstring"> relative paths should be returned</tt> </tt> | ||
3879 | 144 | <a name="L82"></a><tt class="py-lineno"> 82</tt> <tt class="py-line"><tt class="py-docstring"> @rtype: sequence</tt> </tt> | ||
3880 | 145 | <a name="L83"></a><tt class="py-lineno"> 83</tt> <tt class="py-line"><tt class="py-docstring"> @return: paths for files found</tt> </tt> | ||
3881 | 146 | <a name="L84"></a><tt class="py-lineno"> 84</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt> | ||
3882 | 147 | <a name="L85"></a><tt class="py-lineno"> 85</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">access</tt><tt class="py-op">(</tt><tt class="py-name">path</tt><tt class="py-op">,</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">R_OK</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
3883 | 148 | <a name="L86"></a><tt class="py-lineno"> 86</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-0" class="py-name" targets="Class scriptutil.ScriptError=scriptutil.ScriptError-class.html"><a title="scriptutil.ScriptError" class="py-name" href="#" onclick="return doclink('link-0', 'ScriptError', 'link-0');">ScriptError</a></tt><tt class="py-op">(</tt><tt class="py-string">"cannot access path: '%s'"</tt> <tt class="py-op">%</tt> <tt class="py-name">path</tt><tt class="py-op">)</tt> </tt> | ||
3884 | 149 | <a name="L87"></a><tt class="py-lineno"> 87</tt> <tt class="py-line"> </tt> | ||
3885 | 150 | <a name="L88"></a><tt class="py-lineno"> 88</tt> <tt class="py-line"> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> <tt class="py-comment"># result list</tt> </tt> | ||
3886 | 151 | <a name="L89"></a><tt class="py-lineno"> 89</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt> | ||
3887 | 152 | <a name="L90"></a><tt class="py-lineno"> 90</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">dir</tt><tt class="py-op">,</tt> <tt class="py-name">subdirs</tt><tt class="py-op">,</tt> <tt class="py-name">files</tt> <tt class="py-keyword">in</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">walk</tt><tt class="py-op">(</tt><tt class="py-name">path</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
3888 | 153 | <a name="L91"></a><tt class="py-lineno"> 91</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">shellglobs</tt><tt class="py-op">:</tt> </tt> | ||
3889 | 154 | <a name="L92"></a><tt class="py-lineno"> 92</tt> <tt class="py-line"> <tt class="py-name">matched</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt> | ||
3890 | 155 | <a name="L93"></a><tt class="py-lineno"> 93</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">pattern</tt> <tt class="py-keyword">in</tt> <tt class="py-name">shellglobs</tt><tt class="py-op">:</tt> </tt> | ||
3891 | 156 | <a name="L94"></a><tt class="py-lineno"> 94</tt> <tt class="py-line"> <tt class="py-name">filterf</tt> <tt class="py-op">=</tt> <tt class="py-keyword">lambda</tt> <tt class="py-name">s</tt><tt class="py-op">:</tt> <tt class="py-name">fnmatch</tt><tt class="py-op">.</tt><tt class="py-name">fnmatchcase</tt><tt class="py-op">(</tt><tt class="py-name">s</tt><tt class="py-op">,</tt> <tt class="py-name">pattern</tt><tt class="py-op">)</tt> </tt> | ||
3892 | 157 | <a name="L95"></a><tt class="py-lineno"> 95</tt> <tt class="py-line"> <tt class="py-name">matched</tt><tt class="py-op">.</tt><tt class="py-name">extend</tt><tt class="py-op">(</tt><tt class="py-name">filter</tt><tt class="py-op">(</tt><tt class="py-name">filterf</tt><tt class="py-op">,</tt> <tt class="py-name">files</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
3893 | 158 | <a name="L96"></a><tt class="py-lineno"> 96</tt> <tt class="py-line"> <tt class="py-name">fileList</tt><tt class="py-op">.</tt><tt class="py-name">extend</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-string">'%s%s%s'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">dir</tt><tt class="py-op">,</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">sep</tt><tt class="py-op">,</tt> <tt class="py-name">f</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">f</tt> <tt class="py-keyword">in</tt> <tt class="py-name">matched</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt> | ||
3894 | 159 | <a name="L97"></a><tt class="py-lineno"> 97</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt> | ||
3895 | 160 | <a name="L98"></a><tt class="py-lineno"> 98</tt> <tt class="py-line"> <tt class="py-name">fileList</tt><tt class="py-op">.</tt><tt class="py-name">extend</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-string">'%s%s%s'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">dir</tt><tt class="py-op">,</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">sep</tt><tt class="py-op">,</tt> <tt class="py-name">f</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">f</tt> <tt class="py-keyword">in</tt> <tt class="py-name">files</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt> | ||
3896 | 161 | <a name="L99"></a><tt class="py-lineno"> 99</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">relative</tt><tt class="py-op">:</tt> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt class="py-name">map</tt><tt class="py-op">(</tt><tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">path</tt><tt class="py-op">.</tt><tt class="py-name">abspath</tt><tt class="py-op">,</tt> <tt class="py-name">fileList</tt><tt class="py-op">)</tt> </tt> | ||
3897 | 162 | <a name="L100"></a><tt class="py-lineno">100</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">namefs</tt><tt class="py-op">:</tt> </tt> | ||
3898 | 163 | <a name="L101"></a><tt class="py-lineno">101</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">ff</tt> <tt class="py-keyword">in</tt> <tt class="py-name">namefs</tt><tt class="py-op">:</tt> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt class="py-name">filter</tt><tt class="py-op">(</tt><tt class="py-name">ff</tt><tt class="py-op">,</tt> <tt class="py-name">fileList</tt><tt class="py-op">)</tt> </tt> | ||
3899 | 164 | <a name="L102"></a><tt class="py-lineno">102</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">Exception</tt><tt class="py-op">,</tt> <tt class="py-name">e</tt><tt class="py-op">:</tt> <tt class="py-keyword">raise</tt> <tt id="link-1" class="py-name"><a title="scriptutil.ScriptError" class="py-name" href="#" onclick="return doclink('link-1', 'ScriptError', 'link-0');">ScriptError</a></tt><tt class="py-op">(</tt><tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
3900 | 165 | <a name="L103"></a><tt class="py-lineno">103</tt> <tt class="py-line"> <tt class="py-keyword">return</tt><tt class="py-op">(</tt><tt class="py-name">fileList</tt><tt class="py-op">)</tt> </tt> | ||
3901 | 166 | </div><a name="L104"></a><tt class="py-lineno">104</tt> <tt class="py-line"> </tt> | ||
3902 | 167 | <a name="ffindgrep"></a><div id="ffindgrep-def"><a name="L105"></a><tt class="py-lineno">105</tt> <a class="py-toggle" href="#" id="ffindgrep-toggle" onclick="return toggle('ffindgrep');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="scriptutil-module.html#ffindgrep">ffindgrep</a><tt class="py-op">(</tt><tt class="py-param">path</tt><tt class="py-op">,</tt> <tt class="py-param">regexl</tt><tt class="py-op">,</tt> <tt class="py-param">shellglobs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">namefs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> </tt> | ||
3903 | 168 | <a name="L106"></a><tt class="py-lineno">106</tt> <tt class="py-line"> <tt class="py-param">relative</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> <tt class="py-param">linenums</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
3904 | 169 | </div><div id="ffindgrep-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="ffindgrep-expanded"><a name="L107"></a><tt class="py-lineno">107</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt> | ||
3905 | 170 | <a name="L108"></a><tt class="py-lineno">108</tt> <tt class="py-line"><tt class="py-docstring"> Find files in the directory tree starting at 'path' (filtered by</tt> </tt> | ||
3906 | 171 | <a name="L109"></a><tt class="py-lineno">109</tt> <tt class="py-line"><tt class="py-docstring"> Unix shell-style wildcards ('shellglobs') and/or the functions in</tt> </tt> | ||
3907 | 172 | <a name="L110"></a><tt class="py-lineno">110</tt> <tt class="py-line"><tt class="py-docstring"> the 'namefs' sequence) and search inside these.</tt> </tt> | ||
3908 | 173 | <a name="L111"></a><tt class="py-lineno">111</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3909 | 174 | <a name="L112"></a><tt class="py-lineno">112</tt> <tt class="py-line"><tt class="py-docstring"> Additionaly, the file content will be filtered by the regular</tt> </tt> | ||
3910 | 175 | <a name="L113"></a><tt class="py-lineno">113</tt> <tt class="py-line"><tt class="py-docstring"> expressions in the 'regexl' sequence. Each entry in the latter</tt> </tt> | ||
3911 | 176 | <a name="L114"></a><tt class="py-lineno">114</tt> <tt class="py-line"><tt class="py-docstring"> is a</tt> </tt> | ||
3912 | 177 | <a name="L115"></a><tt class="py-lineno">115</tt> <tt class="py-line"><tt class="py-docstring"> </tt> </tt> | ||
3913 | 178 | <a name="L116"></a><tt class="py-lineno">116</tt> <tt class="py-line"><tt class="py-docstring"> - either a string (with the regex definition)</tt> </tt> | ||
3914 | 179 | <a name="L117"></a><tt class="py-lineno">117</tt> <tt class="py-line"><tt class="py-docstring"> - or a tuple with arguments accepted by re.compile() (the</tt> </tt> | ||
3915 | 180 | <a name="L118"></a><tt class="py-lineno">118</tt> <tt class="py-line"><tt class="py-docstring"> re.M and re.S flags will have no effect though)</tt> </tt> | ||
3916 | 181 | <a name="L119"></a><tt class="py-lineno">119</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3917 | 182 | <a name="L120"></a><tt class="py-lineno">120</tt> <tt class="py-line"><tt class="py-docstring"> For all the files that pass the file name/content tests the function</tt> </tt> | ||
3918 | 183 | <a name="L121"></a><tt class="py-lineno">121</tt> <tt class="py-line"><tt class="py-docstring"> returns a dictionary where the</tt> </tt> | ||
3919 | 184 | <a name="L122"></a><tt class="py-lineno">122</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3920 | 185 | <a name="L123"></a><tt class="py-lineno">123</tt> <tt class="py-line"><tt class="py-docstring"> - key is the file name and the</tt> </tt> | ||
3921 | 186 | <a name="L124"></a><tt class="py-lineno">124</tt> <tt class="py-line"><tt class="py-docstring"> - value is a string with lines filtered by 'regexl'</tt> </tt> | ||
3922 | 187 | <a name="L125"></a><tt class="py-lineno">125</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3923 | 188 | <a name="L126"></a><tt class="py-lineno">126</tt> <tt class="py-line"><tt class="py-docstring"> @type path: string</tt> </tt> | ||
3924 | 189 | <a name="L127"></a><tt class="py-lineno">127</tt> <tt class="py-line"><tt class="py-docstring"> @param path: starting path of the directory tree to be searched</tt> </tt> | ||
3925 | 190 | <a name="L128"></a><tt class="py-lineno">128</tt> <tt class="py-line"><tt class="py-docstring"> @type shellglobs: sequence</tt> </tt> | ||
3926 | 191 | <a name="L129"></a><tt class="py-lineno">129</tt> <tt class="py-line"><tt class="py-docstring"> @param shellglobs: an optional sequence of Unix shell-style wildcards</tt> </tt> | ||
3927 | 192 | <a name="L130"></a><tt class="py-lineno">130</tt> <tt class="py-line"><tt class="py-docstring"> that are to be applied to the file *names* found</tt> </tt> | ||
3928 | 193 | <a name="L131"></a><tt class="py-lineno">131</tt> <tt class="py-line"><tt class="py-docstring"> @type namefs: sequence</tt> </tt> | ||
3929 | 194 | <a name="L132"></a><tt class="py-lineno">132</tt> <tt class="py-line"><tt class="py-docstring"> @param namefs: an optional sequence of functions to be applied to the</tt> </tt> | ||
3930 | 195 | <a name="L133"></a><tt class="py-lineno">133</tt> <tt class="py-line"><tt class="py-docstring"> file *paths* found</tt> </tt> | ||
3931 | 196 | <a name="L134"></a><tt class="py-lineno">134</tt> <tt class="py-line"><tt class="py-docstring"> @type relative: bool</tt> </tt> | ||
3932 | 197 | <a name="L135"></a><tt class="py-lineno">135</tt> <tt class="py-line"><tt class="py-docstring"> @param relative: a boolean flag that determines whether absolute or</tt> </tt> | ||
3933 | 198 | <a name="L136"></a><tt class="py-lineno">136</tt> <tt class="py-line"><tt class="py-docstring"> relative paths should be returned</tt> </tt> | ||
3934 | 199 | <a name="L137"></a><tt class="py-lineno">137</tt> <tt class="py-line"><tt class="py-docstring"> @type linenums: bool</tt> </tt> | ||
3935 | 200 | <a name="L138"></a><tt class="py-lineno">138</tt> <tt class="py-line"><tt class="py-docstring"> @param linenums: turns on line numbers for found files (like grep -n)</tt> </tt> | ||
3936 | 201 | <a name="L139"></a><tt class="py-lineno">139</tt> <tt class="py-line"><tt class="py-docstring"> @rtype: dict</tt> </tt> | ||
3937 | 202 | <a name="L140"></a><tt class="py-lineno">140</tt> <tt class="py-line"><tt class="py-docstring"> @return: file name (key) and lines filtered by 'regexl' (value)</tt> </tt> | ||
3938 | 203 | <a name="L141"></a><tt class="py-lineno">141</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt> | ||
3939 | 204 | <a name="L142"></a><tt class="py-lineno">142</tt> <tt class="py-line"> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt id="link-2" class="py-name" targets="Function scriptutil.ffind()=scriptutil-module.html#ffind"><a title="scriptutil.ffind" class="py-name" href="#" onclick="return doclink('link-2', 'ffind', 'link-2');">ffind</a></tt><tt class="py-op">(</tt><tt class="py-name">path</tt><tt class="py-op">,</tt> <tt class="py-name">shellglobs</tt><tt class="py-op">=</tt><tt class="py-name">shellglobs</tt><tt class="py-op">,</tt> </tt> | ||
3940 | 205 | <a name="L143"></a><tt class="py-lineno">143</tt> <tt class="py-line"> <tt class="py-name">namefs</tt><tt class="py-op">=</tt><tt class="py-name">namefs</tt><tt class="py-op">,</tt> <tt class="py-name">relative</tt><tt class="py-op">=</tt><tt class="py-name">relative</tt><tt class="py-op">)</tt> </tt> | ||
3941 | 206 | <a name="L144"></a><tt class="py-lineno">144</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">fileList</tt><tt class="py-op">:</tt> <tt class="py-keyword">return</tt> <tt class="py-name">dict</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
3942 | 207 | <a name="L145"></a><tt class="py-lineno">145</tt> <tt class="py-line"> </tt> | ||
3943 | 208 | <a name="L146"></a><tt class="py-lineno">146</tt> <tt class="py-line"> <tt class="py-name">result</tt> <tt class="py-op">=</tt> <tt class="py-name">dict</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
3944 | 209 | <a name="L147"></a><tt class="py-lineno">147</tt> <tt class="py-line"> </tt> | ||
3945 | 210 | <a name="L148"></a><tt class="py-lineno">148</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt> | ||
3946 | 211 | <a name="L149"></a><tt class="py-lineno">149</tt> <tt class="py-line"> <tt class="py-comment"># first compile the regular expressions</tt> </tt> | ||
3947 | 212 | <a name="L150"></a><tt class="py-lineno">150</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">ffuncs</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt> | ||
3948 | 213 | <a name="L151"></a><tt class="py-lineno">151</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">redata</tt> <tt class="py-keyword">in</tt> <tt class="py-name">regexl</tt><tt class="py-op">:</tt> </tt> | ||
3949 | 214 | <a name="L152"></a><tt class="py-lineno">152</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">type</tt><tt class="py-op">(</tt><tt class="py-name">redata</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">types</tt><tt class="py-op">.</tt><tt class="py-name">StringType</tt><tt class="py-op">:</tt> </tt> | ||
3950 | 215 | <a name="L153"></a><tt class="py-lineno">153</tt> <tt class="py-line"> <tt class="py-name">ffuncs</tt><tt class="py-op">.</tt><tt class="py-name">append</tt><tt class="py-op">(</tt><tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt><tt class="py-name">redata</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">search</tt><tt class="py-op">)</tt> </tt> | ||
3951 | 216 | <a name="L154"></a><tt class="py-lineno">154</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">type</tt><tt class="py-op">(</tt><tt class="py-name">redata</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">types</tt><tt class="py-op">.</tt><tt class="py-name">TupleType</tt><tt class="py-op">:</tt> </tt> | ||
3952 | 217 | <a name="L155"></a><tt class="py-lineno">155</tt> <tt class="py-line"> <tt class="py-name">ffuncs</tt><tt class="py-op">.</tt><tt class="py-name">append</tt><tt class="py-op">(</tt><tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt><tt class="py-op">*</tt><tt class="py-name">redata</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">search</tt><tt class="py-op">)</tt> </tt> | ||
3953 | 218 | <a name="L156"></a><tt class="py-lineno">156</tt> <tt class="py-line"> <tt class="py-comment"># now grep in the files found</tt> </tt> | ||
3954 | 219 | <a name="L157"></a><tt class="py-lineno">157</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">for</tt> <tt class="py-name">file</tt> <tt class="py-keyword">in</tt> <tt class="py-name">fileList</tt><tt class="py-op">:</tt> </tt> | ||
3955 | 220 | <a name="L158"></a><tt class="py-lineno">158</tt> <tt class="py-line"> <tt class="py-comment"># read file content</tt> </tt> | ||
3956 | 221 | <a name="L159"></a><tt class="py-lineno">159</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">fhandle</tt> <tt class="py-op">=</tt> <tt class="py-name">open</tt><tt class="py-op">(</tt><tt class="py-name">file</tt><tt class="py-op">,</tt> <tt class="py-string">'r'</tt><tt class="py-op">)</tt> </tt> | ||
3957 | 222 | <a name="L160"></a><tt class="py-lineno">160</tt> <tt class="py-line"> <tt class="py-name">fcontent</tt> <tt class="py-op">=</tt> <tt class="py-name">fhandle</tt><tt class="py-op">.</tt><tt class="py-name">read</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
3958 | 223 | <a name="L161"></a><tt class="py-lineno">161</tt> <tt class="py-line"> <tt class="py-name">fhandle</tt><tt class="py-op">.</tt><tt class="py-name">close</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
3959 | 224 | <a name="L162"></a><tt class="py-lineno">162</tt> <tt class="py-line"> <tt class="py-comment"># split file content in lines</tt> </tt> | ||
3960 | 225 | <a name="L163"></a><tt class="py-lineno">163</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-name">linenums</tt><tt class="py-op">:</tt> <tt class="py-name">lines</tt> <tt class="py-op">=</tt> <tt class="py-name">zip</tt><tt class="py-op">(</tt><tt class="py-name">itertools</tt><tt class="py-op">.</tt><tt class="py-name">count</tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">fcontent</tt><tt class="py-op">.</tt><tt class="py-name">splitlines</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
3961 | 226 | <a name="L164"></a><tt class="py-lineno">164</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> <tt class="py-name">lines</tt> <tt class="py-op">=</tt> <tt class="py-name">fcontent</tt><tt class="py-op">.</tt><tt class="py-name">splitlines</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
3962 | 227 | <a name="L165"></a><tt class="py-lineno">165</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">ff</tt> <tt class="py-keyword">in</tt> <tt class="py-name">ffuncs</tt><tt class="py-op">:</tt> </tt> | ||
3963 | 228 | <a name="L166"></a><tt class="py-lineno">166</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">linenums</tt><tt class="py-op">:</tt> <tt class="py-name">lines</tt> <tt class="py-op">=</tt> <tt class="py-name">filter</tt><tt class="py-op">(</tt><tt class="py-keyword">lambda</tt> <tt class="py-name">t</tt><tt class="py-op">:</tt> <tt class="py-name">ff</tt><tt class="py-op">(</tt><tt class="py-name">t</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">lines</tt><tt class="py-op">)</tt> </tt> | ||
3964 | 229 | <a name="L167"></a><tt class="py-lineno">167</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> <tt class="py-name">lines</tt> <tt class="py-op">=</tt> <tt class="py-name">filter</tt><tt class="py-op">(</tt><tt class="py-name">ff</tt><tt class="py-op">,</tt> <tt class="py-name">lines</tt><tt class="py-op">)</tt> </tt> | ||
3965 | 230 | <a name="L168"></a><tt class="py-lineno">168</tt> <tt class="py-line"> <tt class="py-comment"># there's no point in applying the remaining regular</tt> </tt> | ||
3966 | 231 | <a name="L169"></a><tt class="py-lineno">169</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># expressions if we don't have any matching lines any more</tt> </tt> | ||
3967 | 232 | <a name="L170"></a><tt class="py-lineno">170</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">lines</tt><tt class="py-op">:</tt> <tt class="py-keyword">break</tt> </tt> | ||
3968 | 233 | <a name="L171"></a><tt class="py-lineno">171</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt> | ||
3969 | 234 | <a name="L172"></a><tt class="py-lineno">172</tt> <tt class="py-line"> <tt class="py-comment"># the loop terminated normally; add this file to the</tt> </tt> | ||
3970 | 235 | <a name="L173"></a><tt class="py-lineno">173</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># result set if there are any lines that matched</tt> </tt> | ||
3971 | 236 | <a name="L174"></a><tt class="py-lineno">174</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-name">lines</tt><tt class="py-op">:</tt> </tt> | ||
3972 | 237 | <a name="L175"></a><tt class="py-lineno">175</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">linenums</tt><tt class="py-op">:</tt> </tt> | ||
3973 | 238 | <a name="L176"></a><tt class="py-lineno">176</tt> <tt class="py-line"> <tt class="py-name">result</tt><tt class="py-op">[</tt><tt class="py-name">file</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt class="py-string">'\n'</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-string">"%d:%s"</tt> <tt class="py-op">%</tt> <tt class="py-name">t</tt> <tt class="py-keyword">for</tt> <tt class="py-name">t</tt> <tt class="py-keyword">in</tt> <tt class="py-name">lines</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt> | ||
3974 | 239 | <a name="L177"></a><tt class="py-lineno">177</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt> | ||
3975 | 240 | <a name="L178"></a><tt class="py-lineno">178</tt> <tt class="py-line"> <tt class="py-name">result</tt><tt class="py-op">[</tt><tt class="py-name">file</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt class="py-string">'\n'</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-name">map</tt><tt class="py-op">(</tt><tt class="py-name">str</tt><tt class="py-op">,</tt> <tt class="py-name">lines</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
3976 | 241 | <a name="L179"></a><tt class="py-lineno">179</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">Exception</tt><tt class="py-op">,</tt> <tt class="py-name">e</tt><tt class="py-op">:</tt> <tt class="py-keyword">raise</tt> <tt id="link-3" class="py-name"><a title="scriptutil.ScriptError" class="py-name" href="#" onclick="return doclink('link-3', 'ScriptError', 'link-0');">ScriptError</a></tt><tt class="py-op">(</tt><tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
3977 | 242 | <a name="L180"></a><tt class="py-lineno">180</tt> <tt class="py-line"> <tt class="py-keyword">return</tt><tt class="py-op">(</tt><tt class="py-name">result</tt><tt class="py-op">)</tt> </tt> | ||
3978 | 243 | </div><a name="L181"></a><tt class="py-lineno">181</tt> <tt class="py-line"> </tt> | ||
3979 | 244 | <a name="freplace"></a><div id="freplace-def"><a name="L182"></a><tt class="py-lineno">182</tt> <a class="py-toggle" href="#" id="freplace-toggle" onclick="return toggle('freplace');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="scriptutil-module.html#freplace">freplace</a><tt class="py-op">(</tt><tt class="py-param">path</tt><tt class="py-op">,</tt> <tt class="py-param">regexl</tt><tt class="py-op">,</tt> <tt class="py-param">shellglobs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">namefs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">bext</tt><tt class="py-op">=</tt><tt class="py-string">'.bak'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
3980 | 245 | </div><div id="freplace-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="freplace-expanded"><a name="L183"></a><tt class="py-lineno">183</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt> | ||
3981 | 246 | <a name="L184"></a><tt class="py-lineno">184</tt> <tt class="py-line"><tt class="py-docstring"> Find files in the directory tree starting at 'path' (filtered by</tt> </tt> | ||
3982 | 247 | <a name="L185"></a><tt class="py-lineno">185</tt> <tt class="py-line"><tt class="py-docstring"> Unix shell-style wildcards ('shellglobs') and/or the functions in</tt> </tt> | ||
3983 | 248 | <a name="L186"></a><tt class="py-lineno">186</tt> <tt class="py-line"><tt class="py-docstring"> the 'namefs' sequence) and perform an in-place search/replace</tt> </tt> | ||
3984 | 249 | <a name="L187"></a><tt class="py-lineno">187</tt> <tt class="py-line"><tt class="py-docstring"> operation on these.</tt> </tt> | ||
3985 | 250 | <a name="L188"></a><tt class="py-lineno">188</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3986 | 251 | <a name="L189"></a><tt class="py-lineno">189</tt> <tt class="py-line"><tt class="py-docstring"> Additionally, an in-place search/replace operation is performed</tt> </tt> | ||
3987 | 252 | <a name="L190"></a><tt class="py-lineno">190</tt> <tt class="py-line"><tt class="py-docstring"> on the content of all the files (whose names passed the tests)</tt> </tt> | ||
3988 | 253 | <a name="L191"></a><tt class="py-lineno">191</tt> <tt class="py-line"><tt class="py-docstring"> using the regular expressions in 'regexl'.</tt> </tt> | ||
3989 | 254 | <a name="L192"></a><tt class="py-lineno">192</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3990 | 255 | <a name="L193"></a><tt class="py-lineno">193</tt> <tt class="py-line"><tt class="py-docstring"> Please note: 'regexl' is a sequence of 3-tuples, each having the</tt> </tt> | ||
3991 | 256 | <a name="L194"></a><tt class="py-lineno">194</tt> <tt class="py-line"><tt class="py-docstring"> following elements:</tt> </tt> | ||
3992 | 257 | <a name="L195"></a><tt class="py-lineno">195</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3993 | 258 | <a name="L196"></a><tt class="py-lineno">196</tt> <tt class="py-line"><tt class="py-docstring"> - search string (Python regex syntax)</tt> </tt> | ||
3994 | 259 | <a name="L197"></a><tt class="py-lineno">197</tt> <tt class="py-line"><tt class="py-docstring"> - replace string (Python regex syntax)</tt> </tt> | ||
3995 | 260 | <a name="L198"></a><tt class="py-lineno">198</tt> <tt class="py-line"><tt class="py-docstring"> - regex flags or 'None' (re.compile syntax)</tt> </tt> | ||
3996 | 261 | <a name="L199"></a><tt class="py-lineno">199</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
3997 | 262 | <a name="L200"></a><tt class="py-lineno">200</tt> <tt class="py-line"><tt class="py-docstring"> Copies of the modified files are saved in backup files using the</tt> </tt> | ||
3998 | 263 | <a name="L201"></a><tt class="py-lineno">201</tt> <tt class="py-line"><tt class="py-docstring"> extension specified in 'bext'.</tt> </tt> | ||
3999 | 264 | <a name="L202"></a><tt class="py-lineno">202</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
4000 | 265 | <a name="L203"></a><tt class="py-lineno">203</tt> <tt class="py-line"><tt class="py-docstring"> @type path: string</tt> </tt> | ||
4001 | 266 | <a name="L204"></a><tt class="py-lineno">204</tt> <tt class="py-line"><tt class="py-docstring"> @param path: starting path of the directory tree to be searched</tt> </tt> | ||
4002 | 267 | <a name="L205"></a><tt class="py-lineno">205</tt> <tt class="py-line"><tt class="py-docstring"> @type shellglobs: sequence</tt> </tt> | ||
4003 | 268 | <a name="L206"></a><tt class="py-lineno">206</tt> <tt class="py-line"><tt class="py-docstring"> @param shellglobs: an optional sequence of Unix shell-style wildcards</tt> </tt> | ||
4004 | 269 | <a name="L207"></a><tt class="py-lineno">207</tt> <tt class="py-line"><tt class="py-docstring"> that are to be applied to the file *names* found</tt> </tt> | ||
4005 | 270 | <a name="L208"></a><tt class="py-lineno">208</tt> <tt class="py-line"><tt class="py-docstring"> @type namefs: sequence</tt> </tt> | ||
4006 | 271 | <a name="L209"></a><tt class="py-lineno">209</tt> <tt class="py-line"><tt class="py-docstring"> @param namefs: an optional sequence of functions to be applied to the</tt> </tt> | ||
4007 | 272 | <a name="L210"></a><tt class="py-lineno">210</tt> <tt class="py-line"><tt class="py-docstring"> file *paths* found</tt> </tt> | ||
4008 | 273 | <a name="L211"></a><tt class="py-lineno">211</tt> <tt class="py-line"><tt class="py-docstring"> @rtype: number</tt> </tt> | ||
4009 | 274 | <a name="L212"></a><tt class="py-lineno">212</tt> <tt class="py-line"><tt class="py-docstring"> @return: total number of files modified</tt> </tt> | ||
4010 | 275 | <a name="L213"></a><tt class="py-lineno">213</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt> | ||
4011 | 276 | <a name="L214"></a><tt class="py-lineno">214</tt> <tt class="py-line"> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt id="link-4" class="py-name"><a title="scriptutil.ffind" class="py-name" href="#" onclick="return doclink('link-4', 'ffind', 'link-2');">ffind</a></tt><tt class="py-op">(</tt><tt class="py-name">path</tt><tt class="py-op">,</tt> <tt class="py-name">shellglobs</tt><tt class="py-op">=</tt><tt class="py-name">shellglobs</tt><tt class="py-op">,</tt> <tt class="py-name">namefs</tt><tt class="py-op">=</tt><tt class="py-name">namefs</tt><tt class="py-op">)</tt> </tt> | ||
4012 | 277 | <a name="L215"></a><tt class="py-lineno">215</tt> <tt class="py-line"> </tt> | ||
4013 | 278 | <a name="L216"></a><tt class="py-lineno">216</tt> <tt class="py-line"> <tt class="py-comment"># return if no files found</tt> </tt> | ||
4014 | 279 | <a name="L217"></a><tt class="py-lineno">217</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">fileList</tt><tt class="py-op">:</tt> <tt class="py-keyword">return</tt> <tt class="py-number">0</tt> </tt> | ||
4015 | 280 | <a name="L218"></a><tt class="py-lineno">218</tt> <tt class="py-line"> </tt> | ||
4016 | 281 | <a name="L219"></a><tt class="py-lineno">219</tt> <tt class="py-line"> <tt class="py-name">filesChanged</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt> | ||
4017 | 282 | <a name="L220"></a><tt class="py-lineno">220</tt> <tt class="py-line"> </tt> | ||
4018 | 283 | <a name="L221"></a><tt class="py-lineno">221</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt> | ||
4019 | 284 | <a name="L222"></a><tt class="py-lineno">222</tt> <tt class="py-line"> <tt class="py-name">cffl</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt> | ||
4020 | 285 | <a name="L223"></a><tt class="py-lineno">223</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">searchs</tt><tt class="py-op">,</tt> <tt class="py-name">replaces</tt><tt class="py-op">,</tt> <tt class="py-name">reflags</tt> <tt class="py-keyword">in</tt> <tt class="py-name">regexl</tt><tt class="py-op">:</tt> </tt> | ||
4021 | 286 | <a name="L224"></a><tt class="py-lineno">224</tt> <tt class="py-line"> <tt class="py-comment"># prepare the required regex objects, check whether we need</tt> </tt> | ||
4022 | 287 | <a name="L225"></a><tt class="py-lineno">225</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># to pass any regex compilation flags</tt> </tt> | ||
4023 | 288 | <a name="L226"></a><tt class="py-lineno">226</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-name">reflags</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> <tt class="py-name">regex</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt><tt class="py-name">searchs</tt><tt class="py-op">,</tt> <tt class="py-name">reflags</tt><tt class="py-op">)</tt> </tt> | ||
4024 | 289 | <a name="L227"></a><tt class="py-lineno">227</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> <tt class="py-name">regex</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt><tt class="py-name">searchs</tt><tt class="py-op">)</tt> </tt> | ||
4025 | 290 | <a name="L228"></a><tt class="py-lineno">228</tt> <tt class="py-line"> <tt class="py-name">cffl</tt><tt class="py-op">.</tt><tt class="py-name">append</tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt class="py-name">regex</tt><tt class="py-op">.</tt><tt class="py-name">subn</tt><tt class="py-op">,</tt> <tt class="py-name">replaces</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
4026 | 291 | <a name="L229"></a><tt class="py-lineno">229</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">file</tt> <tt class="py-keyword">in</tt> <tt class="py-name">fileList</tt><tt class="py-op">:</tt> </tt> | ||
4027 | 292 | <a name="L230"></a><tt class="py-lineno">230</tt> <tt class="py-line"> <tt class="py-comment"># read file content</tt> </tt> | ||
4028 | 293 | <a name="L231"></a><tt class="py-lineno">231</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">fhandle</tt> <tt class="py-op">=</tt> <tt class="py-name">open</tt><tt class="py-op">(</tt><tt class="py-name">file</tt><tt class="py-op">,</tt> <tt class="py-string">'r'</tt><tt class="py-op">)</tt> </tt> | ||
4029 | 294 | <a name="L232"></a><tt class="py-lineno">232</tt> <tt class="py-line"> <tt class="py-name">text</tt> <tt class="py-op">=</tt> <tt class="py-name">fhandle</tt><tt class="py-op">.</tt><tt class="py-name">read</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
4030 | 295 | <a name="L233"></a><tt class="py-lineno">233</tt> <tt class="py-line"> <tt class="py-name">fhandle</tt><tt class="py-op">.</tt><tt class="py-name">close</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
4031 | 296 | <a name="L234"></a><tt class="py-lineno">234</tt> <tt class="py-line"> <tt class="py-name">substitutions</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt> | ||
4032 | 297 | <a name="L235"></a><tt class="py-lineno">235</tt> <tt class="py-line"> <tt class="py-comment"># unpack the subn() function and the replace string</tt> </tt> | ||
4033 | 298 | <a name="L236"></a><tt class="py-lineno">236</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">for</tt> <tt class="py-name">subnfunc</tt><tt class="py-op">,</tt> <tt class="py-name">replaces</tt> <tt class="py-keyword">in</tt> <tt class="py-name">cffl</tt><tt class="py-op">:</tt> </tt> | ||
4034 | 299 | <a name="L237"></a><tt class="py-lineno">237</tt> <tt class="py-line"> <tt class="py-name">text</tt><tt class="py-op">,</tt> <tt class="py-name">numOfChanges</tt> <tt class="py-op">=</tt> <tt class="py-name">subnfunc</tt><tt class="py-op">(</tt><tt class="py-name">replaces</tt><tt class="py-op">,</tt> <tt class="py-name">text</tt><tt class="py-op">)</tt> </tt> | ||
4035 | 300 | <a name="L238"></a><tt class="py-lineno">238</tt> <tt class="py-line"> <tt class="py-name">substitutions</tt> <tt class="py-op">+=</tt> <tt class="py-name">numOfChanges</tt> </tt> | ||
4036 | 301 | <a name="L239"></a><tt class="py-lineno">239</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">substitutions</tt><tt class="py-op">:</tt> </tt> | ||
4037 | 302 | <a name="L240"></a><tt class="py-lineno">240</tt> <tt class="py-line"> <tt class="py-comment"># first move away the original file</tt> </tt> | ||
4038 | 303 | <a name="L241"></a><tt class="py-lineno">241</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">bakFileName</tt> <tt class="py-op">=</tt> <tt class="py-string">'%s%s'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">file</tt><tt class="py-op">,</tt> <tt class="py-name">bext</tt><tt class="py-op">)</tt> </tt> | ||
4039 | 304 | <a name="L242"></a><tt class="py-lineno">242</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">path</tt><tt class="py-op">.</tt><tt class="py-name">exists</tt><tt class="py-op">(</tt><tt class="py-name">bakFileName</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">unlink</tt><tt class="py-op">(</tt><tt class="py-name">bakFileName</tt><tt class="py-op">)</tt> </tt> | ||
4040 | 305 | <a name="L243"></a><tt class="py-lineno">243</tt> <tt class="py-line"> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">rename</tt><tt class="py-op">(</tt><tt class="py-name">file</tt><tt class="py-op">,</tt> <tt class="py-name">bakFileName</tt><tt class="py-op">)</tt> </tt> | ||
4041 | 306 | <a name="L244"></a><tt class="py-lineno">244</tt> <tt class="py-line"> <tt class="py-comment"># now write the new file content</tt> </tt> | ||
4042 | 307 | <a name="L245"></a><tt class="py-lineno">245</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">fhandle</tt> <tt class="py-op">=</tt> <tt class="py-name">open</tt><tt class="py-op">(</tt><tt class="py-name">file</tt><tt class="py-op">,</tt> <tt class="py-string">'w'</tt><tt class="py-op">)</tt> </tt> | ||
4043 | 308 | <a name="L246"></a><tt class="py-lineno">246</tt> <tt class="py-line"> <tt class="py-name">fhandle</tt><tt class="py-op">.</tt><tt class="py-name">write</tt><tt class="py-op">(</tt><tt class="py-name">text</tt><tt class="py-op">)</tt> </tt> | ||
4044 | 309 | <a name="L247"></a><tt class="py-lineno">247</tt> <tt class="py-line"> <tt class="py-name">fhandle</tt><tt class="py-op">.</tt><tt class="py-name">close</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt> | ||
4045 | 310 | <a name="L248"></a><tt class="py-lineno">248</tt> <tt class="py-line"> <tt class="py-name">filesChanged</tt> <tt class="py-op">+=</tt> <tt class="py-number">1</tt> </tt> | ||
4046 | 311 | <a name="L249"></a><tt class="py-lineno">249</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">Exception</tt><tt class="py-op">,</tt> <tt class="py-name">e</tt><tt class="py-op">:</tt> <tt class="py-keyword">raise</tt> <tt id="link-5" class="py-name"><a title="scriptutil.ScriptError" class="py-name" href="#" onclick="return doclink('link-5', 'ScriptError', 'link-0');">ScriptError</a></tt><tt class="py-op">(</tt><tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
4047 | 312 | <a name="L250"></a><tt class="py-lineno">250</tt> <tt class="py-line"> </tt> | ||
4048 | 313 | <a name="L251"></a><tt class="py-lineno">251</tt> <tt class="py-line"> <tt class="py-comment"># Returns the number of files that had some of their content changed</tt> </tt> | ||
4049 | 314 | <a name="L252"></a><tt class="py-lineno">252</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">return</tt><tt class="py-op">(</tt><tt class="py-name">filesChanged</tt><tt class="py-op">)</tt> </tt> | ||
4050 | 315 | </div><a name="L253"></a><tt class="py-lineno">253</tt> <tt class="py-line"> </tt> | ||
4051 | 316 | <a name="printr"></a><div id="printr-def"><a name="L254"></a><tt class="py-lineno">254</tt> <a class="py-toggle" href="#" id="printr-toggle" onclick="return toggle('printr');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="scriptutil-module.html#printr">printr</a><tt class="py-op">(</tt><tt class="py-param">results</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4052 | 317 | </div><div id="printr-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="printr-expanded"><a name="L255"></a><tt class="py-lineno">255</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt> | ||
4053 | 318 | <a name="L256"></a><tt class="py-lineno">256</tt> <tt class="py-line"><tt class="py-docstring"> Print the results of the ffind()/ffindgrep() functions.</tt> </tt> | ||
4054 | 319 | <a name="L257"></a><tt class="py-lineno">257</tt> <tt class="py-line"><tt class="py-docstring"> </tt> </tt> | ||
4055 | 320 | <a name="L258"></a><tt class="py-lineno">258</tt> <tt class="py-line"><tt class="py-docstring"> The output format is similar to the one used by the UNIX find utility.</tt> </tt> | ||
4056 | 321 | <a name="L259"></a><tt class="py-lineno">259</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt> | ||
4057 | 322 | <a name="L260"></a><tt class="py-lineno">260</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">type</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">types</tt><tt class="py-op">.</tt><tt class="py-name">DictType</tt><tt class="py-op">:</tt> </tt> | ||
4058 | 323 | <a name="L261"></a><tt class="py-lineno">261</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">f</tt> <tt class="py-keyword">in</tt> <tt class="py-name">sorted</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">.</tt><tt class="py-name">keys</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4059 | 324 | <a name="L262"></a><tt class="py-lineno">262</tt> <tt class="py-line"> <tt class="py-name">sys</tt><tt class="py-op">.</tt><tt class="py-name">stdout</tt><tt class="py-op">.</tt><tt class="py-name">write</tt><tt class="py-op">(</tt><tt class="py-string">"%s\n%s\n"</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">[</tt><tt class="py-name">f</tt><tt class="py-op">]</tt><tt class="py-op">,</tt><tt class="py-name">f</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
4060 | 325 | <a name="L263"></a><tt class="py-lineno">263</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt> | ||
4061 | 326 | <a name="L264"></a><tt class="py-lineno">264</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">f</tt> <tt class="py-keyword">in</tt> <tt class="py-name">sorted</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4062 | 327 | <a name="L265"></a><tt class="py-lineno">265</tt> <tt class="py-line"> <tt class="py-name">sys</tt><tt class="py-op">.</tt><tt class="py-name">stdout</tt><tt class="py-op">.</tt><tt class="py-name">write</tt><tt class="py-op">(</tt><tt class="py-string">"%s\n"</tt> <tt class="py-op">%</tt> <tt class="py-name">f</tt><tt class="py-op">)</tt> </tt> | ||
4063 | 328 | </div><a name="L266"></a><tt class="py-lineno">266</tt> <tt class="py-line"> </tt> | ||
4064 | 329 | <a name="L267"></a><tt class="py-lineno">267</tt> <tt class="py-line"><tt class="py-keyword">if</tt> <tt class="py-name">__name__</tt> <tt class="py-op">==</tt> <tt class="py-string">'__main__'</tt><tt class="py-op">:</tt> </tt> | ||
4065 | 330 | <a name="L268"></a><tt class="py-lineno">268</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt> | ||
4066 | 331 | <a name="L269"></a><tt class="py-lineno">269</tt> <tt class="py-line"> </tt><script type="text/javascript"> | ||
4067 | 332 | <!-- | ||
4068 | 333 | expandto(location.href); | ||
4069 | 334 | // --> | ||
4070 | 335 | </script> | ||
4071 | 336 | </pre> | ||
4072 | 337 | <br /> | ||
4073 | 338 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
4074 | 339 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
4075 | 340 | bgcolor="#a0c0ff" cellspacing="0"> | ||
4076 | 341 | <tr valign="middle"> | ||
4077 | 342 | <!-- Home link --> | ||
4078 | 343 | <th bgcolor="#70b0f0" class="navbar-select" | ||
4079 | 344 | > Home </th> | ||
4080 | 345 | |||
4081 | 346 | <!-- Tree link --> | ||
4082 | 347 | <th> <a | ||
4083 | 348 | href="module-tree.html">Trees</a> </th> | ||
4084 | 349 | |||
4085 | 350 | <!-- Index link --> | ||
4086 | 351 | <th> <a | ||
4087 | 352 | href="identifier-index.html">Indices</a> </th> | ||
4088 | 353 | |||
4089 | 354 | <!-- Help link --> | ||
4090 | 355 | <th> <a | ||
4091 | 356 | href="help.html">Help</a> </th> | ||
4092 | 357 | |||
4093 | 358 | <!-- Project homepage --> | ||
4094 | 359 | <th class="navbar" align="right" width="100%"> | ||
4095 | 360 | <table border="0" cellpadding="0" cellspacing="0"> | ||
4096 | 361 | <tr><th class="navbar" align="center" | ||
4097 | 362 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
4098 | 363 | </tr></table></th> | ||
4099 | 364 | </tr> | ||
4100 | 365 | </table> | ||
4101 | 366 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
4102 | 367 | <tr> | ||
4103 | 368 | <td align="left" class="footer"> | ||
4104 | 369 | Generated by Epydoc 3.0beta1 on Thu May 22 18:10:51 2008 | ||
4105 | 370 | </td> | ||
4106 | 371 | <td align="right" class="footer"> | ||
4107 | 372 | <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a> | ||
4108 | 373 | </td> | ||
4109 | 374 | </tr> | ||
4110 | 375 | </table> | ||
4111 | 376 | |||
4112 | 377 | <script type="text/javascript"> | ||
4113 | 378 | <!-- | ||
4114 | 379 | // Private objects are initially displayed (because if | ||
4115 | 380 | // javascript is turned off then we want them to be | ||
4116 | 381 | // visible); but by default, we want to hide them. So hide | ||
4117 | 382 | // them unless we have a cookie that says to show them. | ||
4118 | 383 | checkCookie() | ||
4119 | 384 | // --> | ||
4120 | 385 | </script> | ||
4121 | 386 | |||
4122 | 387 | </body> | ||
4123 | 388 | </html> | ||
4124 | 389 | 0 | ||
4125 | === removed file 'doc/html/scriptutil.ScriptError-class.html' | |||
4126 | --- doc/html/scriptutil.ScriptError-class.html 2009-12-26 20:49:38 +0000 | |||
4127 | +++ doc/html/scriptutil.ScriptError-class.html 1970-01-01 00:00:00 +0000 | |||
4128 | @@ -1,197 +0,0 @@ | |||
4129 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
4130 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
4131 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
4132 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
4133 | 5 | <head> | ||
4134 | 6 | <title>scriptutil.ScriptError</title> | ||
4135 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
4136 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
4137 | 9 | </head> | ||
4138 | 10 | |||
4139 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
4140 | 12 | alink="#204080"> | ||
4141 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
4142 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
4143 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
4144 | 16 | <tr valign="middle"> | ||
4145 | 17 | <!-- Home link --> | ||
4146 | 18 | <th> <a | ||
4147 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
4148 | 20 | |||
4149 | 21 | <!-- Tree link --> | ||
4150 | 22 | <th> <a | ||
4151 | 23 | href="module-tree.html">Trees</a> </th> | ||
4152 | 24 | |||
4153 | 25 | <!-- Index link --> | ||
4154 | 26 | <th> <a | ||
4155 | 27 | href="identifier-index.html">Indices</a> </th> | ||
4156 | 28 | |||
4157 | 29 | <!-- Help link --> | ||
4158 | 30 | <th> <a | ||
4159 | 31 | href="help.html">Help</a> </th> | ||
4160 | 32 | |||
4161 | 33 | <!-- Project homepage --> | ||
4162 | 34 | <th class="navbar" align="right" width="100%"> | ||
4163 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
4164 | 36 | <tr><th class="navbar" align="center" | ||
4165 | 37 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
4166 | 38 | </tr></table></th> | ||
4167 | 39 | </tr> | ||
4168 | 40 | </table> | ||
4169 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
4170 | 42 | <tr valign="top"> | ||
4171 | 43 | <td width="100%"> | ||
4172 | 44 | <span class="breadcrumbs"> | ||
4173 | 45 | <a href="scriptutil-module.html">Script scriptutil</a> :: | ||
4174 | 46 | Class ScriptError | ||
4175 | 47 | </span> | ||
4176 | 48 | </td> | ||
4177 | 49 | <td> | ||
4178 | 50 | <table cellpadding="0" cellspacing="0"> | ||
4179 | 51 | <!-- hide/show private --> | ||
4180 | 52 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
4181 | 53 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
4182 | 54 | <tr><td align="right"><span class="options" | ||
4183 | 55 | >[<a href="frames.html" target="_top">frames</a | ||
4184 | 56 | >] | <a href="scriptutil.ScriptError-class.html" | ||
4185 | 57 | target="_top">no frames</a>]</span></td></tr> | ||
4186 | 58 | </table> | ||
4187 | 59 | </td> | ||
4188 | 60 | </tr> | ||
4189 | 61 | </table> | ||
4190 | 62 | <!-- ==================== CLASS DESCRIPTION ==================== --> | ||
4191 | 63 | <h1 class="epydoc">Class ScriptError</h1><span class="codelink"><a href="scriptutil-pysrc.html#ScriptError">source code</a></span><br /><br /> | ||
4192 | 64 | <pre class="base-tree"> | ||
4193 | 65 | object --+ | ||
4194 | 66 | | | ||
4195 | 67 | exceptions.BaseException --+ | ||
4196 | 68 | | | ||
4197 | 69 | exceptions.Exception --+ | ||
4198 | 70 | | | ||
4199 | 71 | <strong class="uidshort">ScriptError</strong> | ||
4200 | 72 | </pre> | ||
4201 | 73 | |||
4202 | 74 | <hr /> | ||
4203 | 75 | The exception raised in case of failures.<br /><br /> | ||
4204 | 76 | |||
4205 | 77 | <!-- ==================== INSTANCE METHODS ==================== --> | ||
4206 | 78 | <a name="section-InstanceMethods"></a> | ||
4207 | 79 | <table class="summary" border="1" cellpadding="3" | ||
4208 | 80 | cellspacing="0" width="100%" bgcolor="white"> | ||
4209 | 81 | <tr bgcolor="#70b0f0" class="table-header"> | ||
4210 | 82 | <td colspan="2" class="table-header"> | ||
4211 | 83 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
4212 | 84 | <tr valign="top"> | ||
4213 | 85 | <td align="left"><span class="table-header">Instance Methods</span></td> | ||
4214 | 86 | <td align="right" valign="top" | ||
4215 | 87 | ><span class="options">[<a href="#section-InstanceMethods" | ||
4216 | 88 | class="privatelink" onclick="toggle_private();" | ||
4217 | 89 | >hide private</a>]</span></td> | ||
4218 | 90 | </tr> | ||
4219 | 91 | </table> | ||
4220 | 92 | </td> | ||
4221 | 93 | </tr> | ||
4222 | 94 | <tr> | ||
4223 | 95 | <td colspan="2" class="summary"> | ||
4224 | 96 | <p class="indent-wrapped-lines"><b>Inherited from <code>exceptions.Exception</code></b>: | ||
4225 | 97 | <code>__init__</code>, | ||
4226 | 98 | <code>__new__</code> | ||
4227 | 99 | </p> | ||
4228 | 100 | <p class="indent-wrapped-lines"><b>Inherited from <code>exceptions.BaseException</code></b>: | ||
4229 | 101 | <code>__delattr__</code>, | ||
4230 | 102 | <code>__getattribute__</code>, | ||
4231 | 103 | <code>__getitem__</code>, | ||
4232 | 104 | <code>__getslice__</code>, | ||
4233 | 105 | <code>__reduce__</code>, | ||
4234 | 106 | <code>__repr__</code>, | ||
4235 | 107 | <code>__setattr__</code>, | ||
4236 | 108 | <code>__setstate__</code>, | ||
4237 | 109 | <code>__str__</code> | ||
4238 | 110 | </p> | ||
4239 | 111 | <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>: | ||
4240 | 112 | <code>__hash__</code>, | ||
4241 | 113 | <code>__reduce_ex__</code> | ||
4242 | 114 | </p> | ||
4243 | 115 | </td> | ||
4244 | 116 | </tr> | ||
4245 | 117 | </table> | ||
4246 | 118 | <!-- ==================== PROPERTIES ==================== --> | ||
4247 | 119 | <a name="section-Properties"></a> | ||
4248 | 120 | <table class="summary" border="1" cellpadding="3" | ||
4249 | 121 | cellspacing="0" width="100%" bgcolor="white"> | ||
4250 | 122 | <tr bgcolor="#70b0f0" class="table-header"> | ||
4251 | 123 | <td colspan="2" class="table-header"> | ||
4252 | 124 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
4253 | 125 | <tr valign="top"> | ||
4254 | 126 | <td align="left"><span class="table-header">Properties</span></td> | ||
4255 | 127 | <td align="right" valign="top" | ||
4256 | 128 | ><span class="options">[<a href="#section-Properties" | ||
4257 | 129 | class="privatelink" onclick="toggle_private();" | ||
4258 | 130 | >hide private</a>]</span></td> | ||
4259 | 131 | </tr> | ||
4260 | 132 | </table> | ||
4261 | 133 | </td> | ||
4262 | 134 | </tr> | ||
4263 | 135 | <tr> | ||
4264 | 136 | <td colspan="2" class="summary"> | ||
4265 | 137 | <p class="indent-wrapped-lines"><b>Inherited from <code>exceptions.BaseException</code></b>: | ||
4266 | 138 | <code>args</code>, | ||
4267 | 139 | <code>message</code> | ||
4268 | 140 | </p> | ||
4269 | 141 | <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>: | ||
4270 | 142 | <code>__class__</code> | ||
4271 | 143 | </p> | ||
4272 | 144 | </td> | ||
4273 | 145 | </tr> | ||
4274 | 146 | </table> | ||
4275 | 147 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
4276 | 148 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
4277 | 149 | bgcolor="#a0c0ff" cellspacing="0"> | ||
4278 | 150 | <tr valign="middle"> | ||
4279 | 151 | <!-- Home link --> | ||
4280 | 152 | <th> <a | ||
4281 | 153 | href="scriptutil-module.html">Home</a> </th> | ||
4282 | 154 | |||
4283 | 155 | <!-- Tree link --> | ||
4284 | 156 | <th> <a | ||
4285 | 157 | href="module-tree.html">Trees</a> </th> | ||
4286 | 158 | |||
4287 | 159 | <!-- Index link --> | ||
4288 | 160 | <th> <a | ||
4289 | 161 | href="identifier-index.html">Indices</a> </th> | ||
4290 | 162 | |||
4291 | 163 | <!-- Help link --> | ||
4292 | 164 | <th> <a | ||
4293 | 165 | href="help.html">Help</a> </th> | ||
4294 | 166 | |||
4295 | 167 | <!-- Project homepage --> | ||
4296 | 168 | <th class="navbar" align="right" width="100%"> | ||
4297 | 169 | <table border="0" cellpadding="0" cellspacing="0"> | ||
4298 | 170 | <tr><th class="navbar" align="center" | ||
4299 | 171 | ><a class="navbar" target="_top" href="http://hrnjad.net/src/scriptutil">Module scriptutil</a></th> | ||
4300 | 172 | </tr></table></th> | ||
4301 | 173 | </tr> | ||
4302 | 174 | </table> | ||
4303 | 175 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
4304 | 176 | <tr> | ||
4305 | 177 | <td align="left" class="footer"> | ||
4306 | 178 | Generated by Epydoc 3.0beta1 on Thu May 22 18:10:51 2008 | ||
4307 | 179 | </td> | ||
4308 | 180 | <td align="right" class="footer"> | ||
4309 | 181 | <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a> | ||
4310 | 182 | </td> | ||
4311 | 183 | </tr> | ||
4312 | 184 | </table> | ||
4313 | 185 | |||
4314 | 186 | <script type="text/javascript"> | ||
4315 | 187 | <!-- | ||
4316 | 188 | // Private objects are initially displayed (because if | ||
4317 | 189 | // javascript is turned off then we want them to be | ||
4318 | 190 | // visible); but by default, we want to hide them. So hide | ||
4319 | 191 | // them unless we have a cookie that says to show them. | ||
4320 | 192 | checkCookie() | ||
4321 | 193 | // --> | ||
4322 | 194 | </script> | ||
4323 | 195 | |||
4324 | 196 | </body> | ||
4325 | 197 | </html> | ||
4326 | 198 | 0 | ||
4327 | === added file 'doc/html/scriptutil.find-module.html' | |||
4328 | --- doc/html/scriptutil.find-module.html 1970-01-01 00:00:00 +0000 | |||
4329 | +++ doc/html/scriptutil.find-module.html 2009-12-26 22:06:14 +0000 | |||
4330 | @@ -0,0 +1,494 @@ | |||
4331 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
4332 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
4333 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
4334 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
4335 | 5 | <head> | ||
4336 | 6 | <title>scriptutil.find</title> | ||
4337 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
4338 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
4339 | 9 | </head> | ||
4340 | 10 | |||
4341 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
4342 | 12 | alink="#204080"> | ||
4343 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
4344 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
4345 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
4346 | 16 | <tr valign="middle"> | ||
4347 | 17 | <!-- Home link --> | ||
4348 | 18 | <th> <a | ||
4349 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
4350 | 20 | |||
4351 | 21 | <!-- Tree link --> | ||
4352 | 22 | <th> <a | ||
4353 | 23 | href="module-tree.html">Trees</a> </th> | ||
4354 | 24 | |||
4355 | 25 | <!-- Index link --> | ||
4356 | 26 | <th> <a | ||
4357 | 27 | href="identifier-index.html">Indices</a> </th> | ||
4358 | 28 | |||
4359 | 29 | <!-- Help link --> | ||
4360 | 30 | <th> <a | ||
4361 | 31 | href="help.html">Help</a> </th> | ||
4362 | 32 | |||
4363 | 33 | <!-- Project homepage --> | ||
4364 | 34 | <th class="navbar" align="right" width="100%"> | ||
4365 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
4366 | 36 | <tr><th class="navbar" align="center" | ||
4367 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
4368 | 38 | </tr></table></th> | ||
4369 | 39 | </tr> | ||
4370 | 40 | </table> | ||
4371 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
4372 | 42 | <tr valign="top"> | ||
4373 | 43 | <td width="100%"> | ||
4374 | 44 | <span class="breadcrumbs"> | ||
4375 | 45 | <a href="scriptutil-module.html">Package scriptutil</a> :: | ||
4376 | 46 | Script find | ||
4377 | 47 | </span> | ||
4378 | 48 | </td> | ||
4379 | 49 | <td> | ||
4380 | 50 | <table cellpadding="0" cellspacing="0"> | ||
4381 | 51 | <!-- hide/show private --> | ||
4382 | 52 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
4383 | 53 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
4384 | 54 | <tr><td align="right"><span class="options" | ||
4385 | 55 | >[<a href="frames.html" target="_top">frames</a | ||
4386 | 56 | >] | <a href="scriptutil.find-module.html" | ||
4387 | 57 | target="_top">no frames</a>]</span></td></tr> | ||
4388 | 58 | </table> | ||
4389 | 59 | </td> | ||
4390 | 60 | </tr> | ||
4391 | 61 | </table> | ||
4392 | 62 | <!-- ==================== MODULE DESCRIPTION ==================== --> | ||
4393 | 63 | <h1 class="epydoc">Module find</h1><p class="nomargin-top"><span class="codelink"><a href="scriptutil.find-pysrc.html">source code</a></span></p> | ||
4394 | 64 | <p>Functions commonly used in shell scripting:</p> | ||
4395 | 65 | <ul> | ||
4396 | 66 | <li> | ||
4397 | 67 | find() : finds files in a directory tree | ||
4398 | 68 | </li> | ||
4399 | 69 | <li> | ||
4400 | 70 | grep(): finds files in a directory tree and matches their content to | ||
4401 | 71 | regular expressions | ||
4402 | 72 | </li> | ||
4403 | 73 | <li> | ||
4404 | 74 | replace() : in-place search/replace of files in a directory tree with | ||
4405 | 75 | regular expressions | ||
4406 | 76 | </li> | ||
4407 | 77 | <li> | ||
4408 | 78 | pprint() : prints the results of the find()/grep() functions | ||
4409 | 79 | </li> | ||
4410 | 80 | </ul> | ||
4411 | 81 | <p>Please see the <a | ||
4412 | 82 | href="http://muharem.wordpress.com/2007/05/20/python-find-files-using-unix-shell-style-wildcards/" | ||
4413 | 83 | target="_top">tutorial</a> as well as the documentation strings of the | ||
4414 | 84 | particular functions for detailed information.</p> | ||
4415 | 85 | |||
4416 | 86 | <!-- ==================== CLASSES ==================== --> | ||
4417 | 87 | <a name="section-Classes"></a> | ||
4418 | 88 | <table class="summary" border="1" cellpadding="3" | ||
4419 | 89 | cellspacing="0" width="100%" bgcolor="white"> | ||
4420 | 90 | <tr bgcolor="#70b0f0" class="table-header"> | ||
4421 | 91 | <td colspan="2" class="table-header"> | ||
4422 | 92 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
4423 | 93 | <tr valign="top"> | ||
4424 | 94 | <td align="left"><span class="table-header">Classes</span></td> | ||
4425 | 95 | <td align="right" valign="top" | ||
4426 | 96 | ><span class="options">[<a href="#section-Classes" | ||
4427 | 97 | class="privatelink" onclick="toggle_private();" | ||
4428 | 98 | >hide private</a>]</span></td> | ||
4429 | 99 | </tr> | ||
4430 | 100 | </table> | ||
4431 | 101 | </td> | ||
4432 | 102 | </tr> | ||
4433 | 103 | <tr> | ||
4434 | 104 | <td width="15%" align="right" valign="top" class="summary"> | ||
4435 | 105 | <span class="summary-type"> </span> | ||
4436 | 106 | </td><td class="summary"> | ||
4437 | 107 | <a href="scriptutil.find.ScriptError-class.html" class="summary-name">ScriptError</a><br /> | ||
4438 | 108 | The exception raised in case of failures. | ||
4439 | 109 | </td> | ||
4440 | 110 | </tr> | ||
4441 | 111 | </table> | ||
4442 | 112 | <!-- ==================== FUNCTIONS ==================== --> | ||
4443 | 113 | <a name="section-Functions"></a> | ||
4444 | 114 | <table class="summary" border="1" cellpadding="3" | ||
4445 | 115 | cellspacing="0" width="100%" bgcolor="white"> | ||
4446 | 116 | <tr bgcolor="#70b0f0" class="table-header"> | ||
4447 | 117 | <td colspan="2" class="table-header"> | ||
4448 | 118 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
4449 | 119 | <tr valign="top"> | ||
4450 | 120 | <td align="left"><span class="table-header">Functions</span></td> | ||
4451 | 121 | <td align="right" valign="top" | ||
4452 | 122 | ><span class="options">[<a href="#section-Functions" | ||
4453 | 123 | class="privatelink" onclick="toggle_private();" | ||
4454 | 124 | >hide private</a>]</span></td> | ||
4455 | 125 | </tr> | ||
4456 | 126 | </table> | ||
4457 | 127 | </td> | ||
4458 | 128 | </tr> | ||
4459 | 129 | <tr> | ||
4460 | 130 | <td width="15%" align="right" valign="top" class="summary"> | ||
4461 | 131 | <span class="summary-type">sequence</span> | ||
4462 | 132 | </td><td class="summary"> | ||
4463 | 133 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4464 | 134 | <tr> | ||
4465 | 135 | <td><span class="summary-sig"><a href="scriptutil.find-module.html#find" class="summary-sig-name">find</a>(<span class="summary-sig-arg">path</span>, | ||
4466 | 136 | <span class="summary-sig-arg">shellglobs</span>=<span class="summary-sig-default">None</span>, | ||
4467 | 137 | <span class="summary-sig-arg">namefs</span>=<span class="summary-sig-default">None</span>, | ||
4468 | 138 | <span class="summary-sig-arg">relative</span>=<span class="summary-sig-default">True</span>)</span><br /> | ||
4469 | 139 | Find files in the directory tree starting at 'path' (filtered by Unix | ||
4470 | 140 | shell-style wildcards ('shellglobs') and/or the functions in the | ||
4471 | 141 | 'namefs' sequence).</td> | ||
4472 | 142 | <td align="right" valign="top"> | ||
4473 | 143 | <span class="codelink"><a href="scriptutil.find-pysrc.html#find">source code</a></span> | ||
4474 | 144 | |||
4475 | 145 | </td> | ||
4476 | 146 | </tr> | ||
4477 | 147 | </table> | ||
4478 | 148 | |||
4479 | 149 | </td> | ||
4480 | 150 | </tr> | ||
4481 | 151 | <tr> | ||
4482 | 152 | <td width="15%" align="right" valign="top" class="summary"> | ||
4483 | 153 | <span class="summary-type">dict</span> | ||
4484 | 154 | </td><td class="summary"> | ||
4485 | 155 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4486 | 156 | <tr> | ||
4487 | 157 | <td><span class="summary-sig"><a href="scriptutil.find-module.html#grep" class="summary-sig-name">grep</a>(<span class="summary-sig-arg">path</span>, | ||
4488 | 158 | <span class="summary-sig-arg">regexl</span>, | ||
4489 | 159 | <span class="summary-sig-arg">shellglobs</span>=<span class="summary-sig-default">None</span>, | ||
4490 | 160 | <span class="summary-sig-arg">namefs</span>=<span class="summary-sig-default">None</span>, | ||
4491 | 161 | <span class="summary-sig-arg">relative</span>=<span class="summary-sig-default">True</span>, | ||
4492 | 162 | <span class="summary-sig-arg">linenums</span>=<span class="summary-sig-default">False</span>)</span><br /> | ||
4493 | 163 | Find files in the directory tree starting at 'path' (filtered by Unix | ||
4494 | 164 | shell-style wildcards ('shellglobs') and/or the functions in the | ||
4495 | 165 | 'namefs' sequence) and search inside these.</td> | ||
4496 | 166 | <td align="right" valign="top"> | ||
4497 | 167 | <span class="codelink"><a href="scriptutil.find-pysrc.html#grep">source code</a></span> | ||
4498 | 168 | |||
4499 | 169 | </td> | ||
4500 | 170 | </tr> | ||
4501 | 171 | </table> | ||
4502 | 172 | |||
4503 | 173 | </td> | ||
4504 | 174 | </tr> | ||
4505 | 175 | <tr> | ||
4506 | 176 | <td width="15%" align="right" valign="top" class="summary"> | ||
4507 | 177 | <span class="summary-type">number</span> | ||
4508 | 178 | </td><td class="summary"> | ||
4509 | 179 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4510 | 180 | <tr> | ||
4511 | 181 | <td><span class="summary-sig"><a href="scriptutil.find-module.html#replace" class="summary-sig-name">replace</a>(<span class="summary-sig-arg">path</span>, | ||
4512 | 182 | <span class="summary-sig-arg">regexl</span>, | ||
4513 | 183 | <span class="summary-sig-arg">shellglobs</span>=<span class="summary-sig-default">None</span>, | ||
4514 | 184 | <span class="summary-sig-arg">namefs</span>=<span class="summary-sig-default">None</span>, | ||
4515 | 185 | <span class="summary-sig-arg">bext</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">.bak</code><code class="variable-quote">'</code></span>)</span><br /> | ||
4516 | 186 | Find files in the directory tree starting at 'path' (filtered by Unix | ||
4517 | 187 | shell-style wildcards ('shellglobs') and/or the functions in the | ||
4518 | 188 | 'namefs' sequence) and perform an in-place search/replace operation | ||
4519 | 189 | on these.</td> | ||
4520 | 190 | <td align="right" valign="top"> | ||
4521 | 191 | <span class="codelink"><a href="scriptutil.find-pysrc.html#replace">source code</a></span> | ||
4522 | 192 | |||
4523 | 193 | </td> | ||
4524 | 194 | </tr> | ||
4525 | 195 | </table> | ||
4526 | 196 | |||
4527 | 197 | </td> | ||
4528 | 198 | </tr> | ||
4529 | 199 | <tr> | ||
4530 | 200 | <td width="15%" align="right" valign="top" class="summary"> | ||
4531 | 201 | <span class="summary-type"> </span> | ||
4532 | 202 | </td><td class="summary"> | ||
4533 | 203 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4534 | 204 | <tr> | ||
4535 | 205 | <td><span class="summary-sig"><a href="scriptutil.find-module.html#pprint" class="summary-sig-name">pprint</a>(<span class="summary-sig-arg">results</span>)</span><br /> | ||
4536 | 206 | Print the results of the find()/grep() functions.</td> | ||
4537 | 207 | <td align="right" valign="top"> | ||
4538 | 208 | <span class="codelink"><a href="scriptutil.find-pysrc.html#pprint">source code</a></span> | ||
4539 | 209 | |||
4540 | 210 | </td> | ||
4541 | 211 | </tr> | ||
4542 | 212 | </table> | ||
4543 | 213 | |||
4544 | 214 | </td> | ||
4545 | 215 | </tr> | ||
4546 | 216 | </table> | ||
4547 | 217 | <!-- ==================== VARIABLES ==================== --> | ||
4548 | 218 | <a name="section-Variables"></a> | ||
4549 | 219 | <table class="summary" border="1" cellpadding="3" | ||
4550 | 220 | cellspacing="0" width="100%" bgcolor="white"> | ||
4551 | 221 | <tr bgcolor="#70b0f0" class="table-header"> | ||
4552 | 222 | <td colspan="2" class="table-header"> | ||
4553 | 223 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
4554 | 224 | <tr valign="top"> | ||
4555 | 225 | <td align="left"><span class="table-header">Variables</span></td> | ||
4556 | 226 | <td align="right" valign="top" | ||
4557 | 227 | ><span class="options">[<a href="#section-Variables" | ||
4558 | 228 | class="privatelink" onclick="toggle_private();" | ||
4559 | 229 | >hide private</a>]</span></td> | ||
4560 | 230 | </tr> | ||
4561 | 231 | </table> | ||
4562 | 232 | </td> | ||
4563 | 233 | </tr> | ||
4564 | 234 | <tr> | ||
4565 | 235 | <td width="15%" align="right" valign="top" class="summary"> | ||
4566 | 236 | <span class="summary-type"> </span> | ||
4567 | 237 | </td><td class="summary"> | ||
4568 | 238 | <a name="__package__"></a><span class="summary-name">__package__</span> = <code title="'scriptutil'"><code class="variable-quote">'</code><code class="variable-string">scriptutil</code><code class="variable-quote">'</code></code> | ||
4569 | 239 | </td> | ||
4570 | 240 | </tr> | ||
4571 | 241 | </table> | ||
4572 | 242 | <!-- ==================== FUNCTION DETAILS ==================== --> | ||
4573 | 243 | <a name="section-FunctionDetails"></a> | ||
4574 | 244 | <table class="details" border="1" cellpadding="3" | ||
4575 | 245 | cellspacing="0" width="100%" bgcolor="white"> | ||
4576 | 246 | <tr bgcolor="#70b0f0" class="table-header"> | ||
4577 | 247 | <td colspan="2" class="table-header"> | ||
4578 | 248 | <table border="0" cellpadding="0" cellspacing="0" width="100%"> | ||
4579 | 249 | <tr valign="top"> | ||
4580 | 250 | <td align="left"><span class="table-header">Function Details</span></td> | ||
4581 | 251 | <td align="right" valign="top" | ||
4582 | 252 | ><span class="options">[<a href="#section-FunctionDetails" | ||
4583 | 253 | class="privatelink" onclick="toggle_private();" | ||
4584 | 254 | >hide private</a>]</span></td> | ||
4585 | 255 | </tr> | ||
4586 | 256 | </table> | ||
4587 | 257 | </td> | ||
4588 | 258 | </tr> | ||
4589 | 259 | </table> | ||
4590 | 260 | <a name="find"></a> | ||
4591 | 261 | <div> | ||
4592 | 262 | <table class="details" border="1" cellpadding="3" | ||
4593 | 263 | cellspacing="0" width="100%" bgcolor="white"> | ||
4594 | 264 | <tr><td> | ||
4595 | 265 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4596 | 266 | <tr valign="top"><td> | ||
4597 | 267 | <h3 class="epydoc"><span class="sig"><span class="sig-name">find</span>(<span class="sig-arg">path</span>, | ||
4598 | 268 | <span class="sig-arg">shellglobs</span>=<span class="sig-default">None</span>, | ||
4599 | 269 | <span class="sig-arg">namefs</span>=<span class="sig-default">None</span>, | ||
4600 | 270 | <span class="sig-arg">relative</span>=<span class="sig-default">True</span>)</span> | ||
4601 | 271 | </h3> | ||
4602 | 272 | </td><td align="right" valign="top" | ||
4603 | 273 | ><span class="codelink"><a href="scriptutil.find-pysrc.html#find">source code</a></span> | ||
4604 | 274 | </td> | ||
4605 | 275 | </tr></table> | ||
4606 | 276 | |||
4607 | 277 | <p>Find files in the directory tree starting at 'path' (filtered by Unix | ||
4608 | 278 | shell-style wildcards ('shellglobs') and/or the functions in the 'namefs' | ||
4609 | 279 | sequence).</p> | ||
4610 | 280 | <p>Please not that the shell wildcards work in a cumulative fashion i.e. | ||
4611 | 281 | each of them is applied to the full set of file *names* found.</p> | ||
4612 | 282 | <p>Conversely, all the functions in 'namefs'</p> | ||
4613 | 283 | <ul> | ||
4614 | 284 | <li> | ||
4615 | 285 | only get to see the output of their respective predecessor function | ||
4616 | 286 | in the sequence (with the obvious exception of the first function) | ||
4617 | 287 | </li> | ||
4618 | 288 | <li> | ||
4619 | 289 | are applied to the full file *path* (whereas the shell-style | ||
4620 | 290 | wildcards are only applied to the file *names*) | ||
4621 | 291 | </li> | ||
4622 | 292 | </ul> | ||
4623 | 293 | <dl class="fields"> | ||
4624 | 294 | <dt>Parameters:</dt> | ||
4625 | 295 | <dd><ul class="nomargin-top"> | ||
4626 | 296 | <li><strong class="pname"><code>path</code></strong> (string) - starting path of the directory tree to be searched</li> | ||
4627 | 297 | <li><strong class="pname"><code>shellglobs</code></strong> (sequence) - an optional sequence of Unix shell-style wildcards that are to be | ||
4628 | 298 | applied to the file *names* found</li> | ||
4629 | 299 | <li><strong class="pname"><code>namefs</code></strong> (sequence) - an optional sequence of functions to be applied to the file | ||
4630 | 300 | *paths* found</li> | ||
4631 | 301 | <li><strong class="pname"><code>relative</code></strong> (bool) - a boolean flag that determines whether absolute or relative paths | ||
4632 | 302 | should be returned</li> | ||
4633 | 303 | </ul></dd> | ||
4634 | 304 | <dt>Returns: sequence</dt> | ||
4635 | 305 | <dd>paths for files found</dd> | ||
4636 | 306 | </dl> | ||
4637 | 307 | </td></tr></table> | ||
4638 | 308 | </div> | ||
4639 | 309 | <a name="grep"></a> | ||
4640 | 310 | <div> | ||
4641 | 311 | <table class="details" border="1" cellpadding="3" | ||
4642 | 312 | cellspacing="0" width="100%" bgcolor="white"> | ||
4643 | 313 | <tr><td> | ||
4644 | 314 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4645 | 315 | <tr valign="top"><td> | ||
4646 | 316 | <h3 class="epydoc"><span class="sig"><span class="sig-name">grep</span>(<span class="sig-arg">path</span>, | ||
4647 | 317 | <span class="sig-arg">regexl</span>, | ||
4648 | 318 | <span class="sig-arg">shellglobs</span>=<span class="sig-default">None</span>, | ||
4649 | 319 | <span class="sig-arg">namefs</span>=<span class="sig-default">None</span>, | ||
4650 | 320 | <span class="sig-arg">relative</span>=<span class="sig-default">True</span>, | ||
4651 | 321 | <span class="sig-arg">linenums</span>=<span class="sig-default">False</span>)</span> | ||
4652 | 322 | </h3> | ||
4653 | 323 | </td><td align="right" valign="top" | ||
4654 | 324 | ><span class="codelink"><a href="scriptutil.find-pysrc.html#grep">source code</a></span> | ||
4655 | 325 | </td> | ||
4656 | 326 | </tr></table> | ||
4657 | 327 | |||
4658 | 328 | <p>Find files in the directory tree starting at 'path' (filtered by Unix | ||
4659 | 329 | shell-style wildcards ('shellglobs') and/or the functions in the 'namefs' | ||
4660 | 330 | sequence) and search inside these.</p> | ||
4661 | 331 | <p>Additionaly, the file content will be filtered by the regular | ||
4662 | 332 | expressions in the 'regexl' sequence. Each entry in the latter is a</p> | ||
4663 | 333 | <ul> | ||
4664 | 334 | <li> | ||
4665 | 335 | either a string (with the regex definition) | ||
4666 | 336 | </li> | ||
4667 | 337 | <li> | ||
4668 | 338 | or a tuple with arguments accepted by re.compile() (the re.M and re.S | ||
4669 | 339 | flags will have no effect though) | ||
4670 | 340 | </li> | ||
4671 | 341 | </ul> | ||
4672 | 342 | <p>For all the files that pass the file name/content tests the function | ||
4673 | 343 | returns a dictionary where the</p> | ||
4674 | 344 | <ul> | ||
4675 | 345 | <li> | ||
4676 | 346 | key is the file name and the | ||
4677 | 347 | </li> | ||
4678 | 348 | <li> | ||
4679 | 349 | value is a string with lines filtered by 'regexl' | ||
4680 | 350 | </li> | ||
4681 | 351 | </ul> | ||
4682 | 352 | <dl class="fields"> | ||
4683 | 353 | <dt>Parameters:</dt> | ||
4684 | 354 | <dd><ul class="nomargin-top"> | ||
4685 | 355 | <li><strong class="pname"><code>path</code></strong> (string) - starting path of the directory tree to be searched</li> | ||
4686 | 356 | <li><strong class="pname"><code>shellglobs</code></strong> (sequence) - an optional sequence of Unix shell-style wildcards that are to be | ||
4687 | 357 | applied to the file *names* found</li> | ||
4688 | 358 | <li><strong class="pname"><code>namefs</code></strong> (sequence) - an optional sequence of functions to be applied to the file | ||
4689 | 359 | *paths* found</li> | ||
4690 | 360 | <li><strong class="pname"><code>relative</code></strong> (bool) - a boolean flag that determines whether absolute or relative paths | ||
4691 | 361 | should be returned</li> | ||
4692 | 362 | <li><strong class="pname"><code>linenums</code></strong> (bool) - turns on line numbers for found files (like grep -n)</li> | ||
4693 | 363 | </ul></dd> | ||
4694 | 364 | <dt>Returns: dict</dt> | ||
4695 | 365 | <dd>file name (key) and lines filtered by 'regexl' (value)</dd> | ||
4696 | 366 | </dl> | ||
4697 | 367 | </td></tr></table> | ||
4698 | 368 | </div> | ||
4699 | 369 | <a name="replace"></a> | ||
4700 | 370 | <div> | ||
4701 | 371 | <table class="details" border="1" cellpadding="3" | ||
4702 | 372 | cellspacing="0" width="100%" bgcolor="white"> | ||
4703 | 373 | <tr><td> | ||
4704 | 374 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4705 | 375 | <tr valign="top"><td> | ||
4706 | 376 | <h3 class="epydoc"><span class="sig"><span class="sig-name">replace</span>(<span class="sig-arg">path</span>, | ||
4707 | 377 | <span class="sig-arg">regexl</span>, | ||
4708 | 378 | <span class="sig-arg">shellglobs</span>=<span class="sig-default">None</span>, | ||
4709 | 379 | <span class="sig-arg">namefs</span>=<span class="sig-default">None</span>, | ||
4710 | 380 | <span class="sig-arg">bext</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">.bak</code><code class="variable-quote">'</code></span>)</span> | ||
4711 | 381 | </h3> | ||
4712 | 382 | </td><td align="right" valign="top" | ||
4713 | 383 | ><span class="codelink"><a href="scriptutil.find-pysrc.html#replace">source code</a></span> | ||
4714 | 384 | </td> | ||
4715 | 385 | </tr></table> | ||
4716 | 386 | |||
4717 | 387 | <p>Find files in the directory tree starting at 'path' (filtered by Unix | ||
4718 | 388 | shell-style wildcards ('shellglobs') and/or the functions in the 'namefs' | ||
4719 | 389 | sequence) and perform an in-place search/replace operation on these.</p> | ||
4720 | 390 | <p>Additionally, an in-place search/replace operation is performed on the | ||
4721 | 391 | content of all the files (whose names passed the tests) using the regular | ||
4722 | 392 | expressions in 'regexl'.</p> | ||
4723 | 393 | <p>Please note: 'regexl' is a sequence of 3-tuples, each having the | ||
4724 | 394 | following elements:</p> | ||
4725 | 395 | <ul> | ||
4726 | 396 | <li> | ||
4727 | 397 | search string (Python regex syntax) | ||
4728 | 398 | </li> | ||
4729 | 399 | <li> | ||
4730 | 400 | replace string (Python regex syntax) | ||
4731 | 401 | </li> | ||
4732 | 402 | <li> | ||
4733 | 403 | regex flags or 'None' (re.compile syntax) | ||
4734 | 404 | </li> | ||
4735 | 405 | </ul> | ||
4736 | 406 | <p>Copies of the modified files are saved in backup files using the | ||
4737 | 407 | extension specified in 'bext'.</p> | ||
4738 | 408 | <dl class="fields"> | ||
4739 | 409 | <dt>Parameters:</dt> | ||
4740 | 410 | <dd><ul class="nomargin-top"> | ||
4741 | 411 | <li><strong class="pname"><code>path</code></strong> (string) - starting path of the directory tree to be searched</li> | ||
4742 | 412 | <li><strong class="pname"><code>shellglobs</code></strong> (sequence) - an optional sequence of Unix shell-style wildcards that are to be | ||
4743 | 413 | applied to the file *names* found</li> | ||
4744 | 414 | <li><strong class="pname"><code>namefs</code></strong> (sequence) - an optional sequence of functions to be applied to the file | ||
4745 | 415 | *paths* found</li> | ||
4746 | 416 | </ul></dd> | ||
4747 | 417 | <dt>Returns: number</dt> | ||
4748 | 418 | <dd>total number of files modified</dd> | ||
4749 | 419 | </dl> | ||
4750 | 420 | </td></tr></table> | ||
4751 | 421 | </div> | ||
4752 | 422 | <a name="pprint"></a> | ||
4753 | 423 | <div> | ||
4754 | 424 | <table class="details" border="1" cellpadding="3" | ||
4755 | 425 | cellspacing="0" width="100%" bgcolor="white"> | ||
4756 | 426 | <tr><td> | ||
4757 | 427 | <table width="100%" cellpadding="0" cellspacing="0" border="0"> | ||
4758 | 428 | <tr valign="top"><td> | ||
4759 | 429 | <h3 class="epydoc"><span class="sig"><span class="sig-name">pprint</span>(<span class="sig-arg">results</span>)</span> | ||
4760 | 430 | </h3> | ||
4761 | 431 | </td><td align="right" valign="top" | ||
4762 | 432 | ><span class="codelink"><a href="scriptutil.find-pysrc.html#pprint">source code</a></span> | ||
4763 | 433 | </td> | ||
4764 | 434 | </tr></table> | ||
4765 | 435 | |||
4766 | 436 | <p>Print the results of the find()/grep() functions.</p> | ||
4767 | 437 | <p>The output format is similar to the one used by the UNIX find | ||
4768 | 438 | utility.</p> | ||
4769 | 439 | <dl class="fields"> | ||
4770 | 440 | </dl> | ||
4771 | 441 | </td></tr></table> | ||
4772 | 442 | </div> | ||
4773 | 443 | <br /> | ||
4774 | 444 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
4775 | 445 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
4776 | 446 | bgcolor="#a0c0ff" cellspacing="0"> | ||
4777 | 447 | <tr valign="middle"> | ||
4778 | 448 | <!-- Home link --> | ||
4779 | 449 | <th> <a | ||
4780 | 450 | href="scriptutil-module.html">Home</a> </th> | ||
4781 | 451 | |||
4782 | 452 | <!-- Tree link --> | ||
4783 | 453 | <th> <a | ||
4784 | 454 | href="module-tree.html">Trees</a> </th> | ||
4785 | 455 | |||
4786 | 456 | <!-- Index link --> | ||
4787 | 457 | <th> <a | ||
4788 | 458 | href="identifier-index.html">Indices</a> </th> | ||
4789 | 459 | |||
4790 | 460 | <!-- Help link --> | ||
4791 | 461 | <th> <a | ||
4792 | 462 | href="help.html">Help</a> </th> | ||
4793 | 463 | |||
4794 | 464 | <!-- Project homepage --> | ||
4795 | 465 | <th class="navbar" align="right" width="100%"> | ||
4796 | 466 | <table border="0" cellpadding="0" cellspacing="0"> | ||
4797 | 467 | <tr><th class="navbar" align="center" | ||
4798 | 468 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
4799 | 469 | </tr></table></th> | ||
4800 | 470 | </tr> | ||
4801 | 471 | </table> | ||
4802 | 472 | <table border="0" cellpadding="0" cellspacing="0" width="100%%"> | ||
4803 | 473 | <tr> | ||
4804 | 474 | <td align="left" class="footer"> | ||
4805 | 475 | Generated by Epydoc 3.0.1 on Sat Dec 26 23:01:34 2009 | ||
4806 | 476 | </td> | ||
4807 | 477 | <td align="right" class="footer"> | ||
4808 | 478 | <a target="mainFrame" href="http://epydoc.sourceforge.net" | ||
4809 | 479 | >http://epydoc.sourceforge.net</a> | ||
4810 | 480 | </td> | ||
4811 | 481 | </tr> | ||
4812 | 482 | </table> | ||
4813 | 483 | |||
4814 | 484 | <script type="text/javascript"> | ||
4815 | 485 | <!-- | ||
4816 | 486 | // Private objects are initially displayed (because if | ||
4817 | 487 | // javascript is turned off then we want them to be | ||
4818 | 488 | // visible); but by default, we want to hide them. So hide | ||
4819 | 489 | // them unless we have a cookie that says to show them. | ||
4820 | 490 | checkCookie(); | ||
4821 | 491 | // --> | ||
4822 | 492 | </script> | ||
4823 | 493 | </body> | ||
4824 | 494 | </html> | ||
4825 | 0 | 495 | ||
4826 | === added file 'doc/html/scriptutil.find-pysrc.html' | |||
4827 | --- doc/html/scriptutil.find-pysrc.html 1970-01-01 00:00:00 +0000 | |||
4828 | +++ doc/html/scriptutil.find-pysrc.html 2009-12-26 22:06:14 +0000 | |||
4829 | @@ -0,0 +1,390 @@ | |||
4830 | 1 | <?xml version="1.0" encoding="ascii"?> | ||
4831 | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
4832 | 3 | "DTD/xhtml1-transitional.dtd"> | ||
4833 | 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
4834 | 5 | <head> | ||
4835 | 6 | <title>scriptutil.find</title> | ||
4836 | 7 | <link rel="stylesheet" href="epydoc.css" type="text/css" /> | ||
4837 | 8 | <script type="text/javascript" src="epydoc.js"></script> | ||
4838 | 9 | </head> | ||
4839 | 10 | |||
4840 | 11 | <body bgcolor="white" text="black" link="blue" vlink="#204080" | ||
4841 | 12 | alink="#204080"> | ||
4842 | 13 | <!-- ==================== NAVIGATION BAR ==================== --> | ||
4843 | 14 | <table class="navbar" border="0" width="100%" cellpadding="0" | ||
4844 | 15 | bgcolor="#a0c0ff" cellspacing="0"> | ||
4845 | 16 | <tr valign="middle"> | ||
4846 | 17 | <!-- Home link --> | ||
4847 | 18 | <th> <a | ||
4848 | 19 | href="scriptutil-module.html">Home</a> </th> | ||
4849 | 20 | |||
4850 | 21 | <!-- Tree link --> | ||
4851 | 22 | <th> <a | ||
4852 | 23 | href="module-tree.html">Trees</a> </th> | ||
4853 | 24 | |||
4854 | 25 | <!-- Index link --> | ||
4855 | 26 | <th> <a | ||
4856 | 27 | href="identifier-index.html">Indices</a> </th> | ||
4857 | 28 | |||
4858 | 29 | <!-- Help link --> | ||
4859 | 30 | <th> <a | ||
4860 | 31 | href="help.html">Help</a> </th> | ||
4861 | 32 | |||
4862 | 33 | <!-- Project homepage --> | ||
4863 | 34 | <th class="navbar" align="right" width="100%"> | ||
4864 | 35 | <table border="0" cellpadding="0" cellspacing="0"> | ||
4865 | 36 | <tr><th class="navbar" align="center" | ||
4866 | 37 | ><a class="navbar" target="_top" href="https://launchpad.net/py-script">Project Homepage</a></th> | ||
4867 | 38 | </tr></table></th> | ||
4868 | 39 | </tr> | ||
4869 | 40 | </table> | ||
4870 | 41 | <table width="100%" cellpadding="0" cellspacing="0"> | ||
4871 | 42 | <tr valign="top"> | ||
4872 | 43 | <td width="100%"> | ||
4873 | 44 | <span class="breadcrumbs"> | ||
4874 | 45 | <a href="scriptutil-module.html">Package scriptutil</a> :: | ||
4875 | 46 | Script find | ||
4876 | 47 | </span> | ||
4877 | 48 | </td> | ||
4878 | 49 | <td> | ||
4879 | 50 | <table cellpadding="0" cellspacing="0"> | ||
4880 | 51 | <!-- hide/show private --> | ||
4881 | 52 | <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" | ||
4882 | 53 | onclick="toggle_private();">hide private</a>]</span></td></tr> | ||
4883 | 54 | <tr><td align="right"><span class="options" | ||
4884 | 55 | >[<a href="frames.html" target="_top">frames</a | ||
4885 | 56 | >] | <a href="scriptutil.find-pysrc.html" | ||
4886 | 57 | target="_top">no frames</a>]</span></td></tr> | ||
4887 | 58 | </table> | ||
4888 | 59 | </td> | ||
4889 | 60 | </tr> | ||
4890 | 61 | </table> | ||
4891 | 62 | <h1 class="epydoc">Source Code for <a href="scriptutil.find-module.html">Script scriptutil.find</a></h1> | ||
4892 | 63 | <pre class="py-src"> | ||
4893 | 64 | <a name="L1"></a><tt class="py-lineno"> 1</tt> <tt class="py-line"><tt class="py-comment">#!/usr/bin/env python</tt> </tt> | ||
4894 | 65 | <a name="L2"></a><tt class="py-lineno"> 2</tt> <tt class="py-line"><tt class="py-comment"># encoding: utf-8</tt> </tt> | ||
4895 | 66 | <a name="L3"></a><tt class="py-lineno"> 3</tt> <tt class="py-line"> </tt> | ||
4896 | 67 | <a name="L4"></a><tt class="py-lineno"> 4</tt> <tt class="py-line"> </tt> | ||
4897 | 68 | <a name="L5"></a><tt class="py-lineno"> 5</tt> <tt class="py-line"><tt class="py-comment"># This file is part of py-script (https://launchpad.net/py-script)</tt> </tt> | ||
4898 | 69 | <a name="L6"></a><tt class="py-lineno"> 6</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt> | ||
4899 | 70 | <a name="L7"></a><tt class="py-lineno"> 7</tt> <tt class="py-line"><tt class="py-comment"># Copyright (C) 2009 Muharem Hrnjadovic <muharem@linux.com></tt> </tt> | ||
4900 | 71 | <a name="L8"></a><tt class="py-lineno"> 8</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt> | ||
4901 | 72 | <a name="L9"></a><tt class="py-lineno"> 9</tt> <tt class="py-line"><tt class="py-comment"># This program is free software; you can redistribute it and/or modify</tt> </tt> | ||
4902 | 73 | <a name="L10"></a><tt class="py-lineno"> 10</tt> <tt class="py-line"><tt class="py-comment"># it under the terms of the GNU General Public License as published by</tt> </tt> | ||
4903 | 74 | <a name="L11"></a><tt class="py-lineno"> 11</tt> <tt class="py-line"><tt class="py-comment"># the Free Software Foundation; either version 2 of the License, or</tt> </tt> | ||
4904 | 75 | <a name="L12"></a><tt class="py-lineno"> 12</tt> <tt class="py-line"><tt class="py-comment"># (at your option) any later version.</tt> </tt> | ||
4905 | 76 | <a name="L13"></a><tt class="py-lineno"> 13</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt> | ||
4906 | 77 | <a name="L14"></a><tt class="py-lineno"> 14</tt> <tt class="py-line"><tt class="py-comment"># This program is distributed in the hope that it will be useful,</tt> </tt> | ||
4907 | 78 | <a name="L15"></a><tt class="py-lineno"> 15</tt> <tt class="py-line"><tt class="py-comment"># but WITHOUT ANY WARRANTY; without even the implied warranty of</tt> </tt> | ||
4908 | 79 | <a name="L16"></a><tt class="py-lineno"> 16</tt> <tt class="py-line"><tt class="py-comment"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</tt> </tt> | ||
4909 | 80 | <a name="L17"></a><tt class="py-lineno"> 17</tt> <tt class="py-line"><tt class="py-comment"># GNU General Public License for more details.</tt> </tt> | ||
4910 | 81 | <a name="L18"></a><tt class="py-lineno"> 18</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt> | ||
4911 | 82 | <a name="L19"></a><tt class="py-lineno"> 19</tt> <tt class="py-line"><tt class="py-comment"># You should have received a copy of the GNU General Public License along</tt> </tt> | ||
4912 | 83 | <a name="L20"></a><tt class="py-lineno"> 20</tt> <tt class="py-line"><tt class="py-comment"># with this program; if not, write to the Free Software Foundation, Inc.,</tt> </tt> | ||
4913 | 84 | <a name="L21"></a><tt class="py-lineno"> 21</tt> <tt class="py-line"><tt class="py-comment"># 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.</tt> </tt> | ||
4914 | 85 | <a name="L22"></a><tt class="py-lineno"> 22</tt> <tt class="py-line"> </tt> | ||
4915 | 86 | <a name="L23"></a><tt class="py-lineno"> 23</tt> <tt class="py-line"> </tt> | ||
4916 | 87 | <a name="L24"></a><tt class="py-lineno"> 24</tt> <tt class="py-line"><tt class="py-docstring">"""</tt> </tt> | ||
4917 | 88 | <a name="L25"></a><tt class="py-lineno"> 25</tt> <tt class="py-line"><tt class="py-docstring">Functions commonly used in shell scripting:</tt> </tt> | ||
4918 | 89 | <a name="L26"></a><tt class="py-lineno"> 26</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
4919 | 90 | <a name="L27"></a><tt class="py-lineno"> 27</tt> <tt class="py-line"><tt class="py-docstring"> - find() : finds files in a directory tree</tt> </tt> | ||
4920 | 91 | <a name="L28"></a><tt class="py-lineno"> 28</tt> <tt class="py-line"><tt class="py-docstring"> - grep(): finds files in a directory tree and matches their</tt> </tt> | ||
4921 | 92 | <a name="L29"></a><tt class="py-lineno"> 29</tt> <tt class="py-line"><tt class="py-docstring"> content to regular expressions</tt> </tt> | ||
4922 | 93 | <a name="L30"></a><tt class="py-lineno"> 30</tt> <tt class="py-line"><tt class="py-docstring"> - replace() : in-place search/replace of files in a directory tree</tt> </tt> | ||
4923 | 94 | <a name="L31"></a><tt class="py-lineno"> 31</tt> <tt class="py-line"><tt class="py-docstring"> with regular expressions</tt> </tt> | ||
4924 | 95 | <a name="L32"></a><tt class="py-lineno"> 32</tt> <tt class="py-line"><tt class="py-docstring"> - pprint() : prints the results of the find()/grep() functions</tt> </tt> | ||
4925 | 96 | <a name="L33"></a><tt class="py-lineno"> 33</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
4926 | 97 | <a name="L34"></a><tt class="py-lineno"> 34</tt> <tt class="py-line"><tt class="py-docstring">Please see the U{tutorial <http://muharem.wordpress.com/2007/05/20/python-find-files-using-unix-shell-style-wildcards/>} as well as the documentation strings of the particular functions for detailed information.</tt> </tt> | ||
4927 | 98 | <a name="L35"></a><tt class="py-lineno"> 35</tt> <tt class="py-line"><tt class="py-docstring">"""</tt> </tt> | ||
4928 | 99 | <a name="L36"></a><tt class="py-lineno"> 36</tt> <tt class="py-line"> </tt> | ||
4929 | 100 | <a name="L37"></a><tt class="py-lineno"> 37</tt> <tt class="py-line"> </tt> | ||
4930 | 101 | <a name="L38"></a><tt class="py-lineno"> 38</tt> <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">fnmatch</tt> </tt> | ||
4931 | 102 | <a name="L39"></a><tt class="py-lineno"> 39</tt> <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">itertools</tt> </tt> | ||
4932 | 103 | <a name="L40"></a><tt class="py-lineno"> 40</tt> <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">os</tt> </tt> | ||
4933 | 104 | <a name="L41"></a><tt class="py-lineno"> 41</tt> <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">sys</tt> </tt> | ||
4934 | 105 | <a name="L42"></a><tt class="py-lineno"> 42</tt> <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">re</tt> </tt> | ||
4935 | 106 | <a name="L43"></a><tt class="py-lineno"> 43</tt> <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">types</tt> </tt> | ||
4936 | 107 | <a name="L44"></a><tt class="py-lineno"> 44</tt> <tt class="py-line"> </tt> | ||
4937 | 108 | <a name="L45"></a><tt class="py-lineno"> 45</tt> <tt class="py-line"> </tt> | ||
4938 | 109 | <a name="ScriptError"></a><div id="ScriptError-def"><a name="L46"></a><tt class="py-lineno"> 46</tt> <a class="py-toggle" href="#" id="ScriptError-toggle" onclick="return toggle('ScriptError');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="scriptutil.find.ScriptError-class.html">ScriptError</a><tt class="py-op">(</tt><tt class="py-base-class">Exception</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4939 | 110 | </div><div id="ScriptError-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="ScriptError-expanded"><a name="L47"></a><tt class="py-lineno"> 47</tt> <tt class="py-line"> <tt class="py-docstring">"""The exception raised in case of failures."""</tt> </tt> | ||
4940 | 111 | </div><a name="L48"></a><tt class="py-lineno"> 48</tt> <tt class="py-line"> </tt> | ||
4941 | 112 | <a name="L49"></a><tt class="py-lineno"> 49</tt> <tt class="py-line"> </tt> | ||
4942 | 113 | <a name="find"></a><div id="find-def"><a name="L50"></a><tt class="py-lineno"> 50</tt> <a class="py-toggle" href="#" id="find-toggle" onclick="return toggle('find');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="scriptutil.find-module.html#find">find</a><tt class="py-op">(</tt><tt class="py-param">path</tt><tt class="py-op">,</tt> <tt class="py-param">shellglobs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">namefs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">relative</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4943 | 114 | </div><div id="find-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="find-expanded"><a name="L51"></a><tt class="py-lineno"> 51</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt> | ||
4944 | 115 | <a name="L52"></a><tt class="py-lineno"> 52</tt> <tt class="py-line"><tt class="py-docstring"> Find files in the directory tree starting at 'path' (filtered by</tt> </tt> | ||
4945 | 116 | <a name="L53"></a><tt class="py-lineno"> 53</tt> <tt class="py-line"><tt class="py-docstring"> Unix shell-style wildcards ('shellglobs') and/or the functions in</tt> </tt> | ||
4946 | 117 | <a name="L54"></a><tt class="py-lineno"> 54</tt> <tt class="py-line"><tt class="py-docstring"> the 'namefs' sequence).</tt> </tt> | ||
4947 | 118 | <a name="L55"></a><tt class="py-lineno"> 55</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
4948 | 119 | <a name="L56"></a><tt class="py-lineno"> 56</tt> <tt class="py-line"><tt class="py-docstring"> Please not that the shell wildcards work in a cumulative fashion</tt> </tt> | ||
4949 | 120 | <a name="L57"></a><tt class="py-lineno"> 57</tt> <tt class="py-line"><tt class="py-docstring"> i.e. each of them is applied to the full set of file *names* found.</tt> </tt> | ||
4950 | 121 | <a name="L58"></a><tt class="py-lineno"> 58</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
4951 | 122 | <a name="L59"></a><tt class="py-lineno"> 59</tt> <tt class="py-line"><tt class="py-docstring"> Conversely, all the functions in 'namefs'</tt> </tt> | ||
4952 | 123 | <a name="L60"></a><tt class="py-lineno"> 60</tt> <tt class="py-line"><tt class="py-docstring"> - only get to see the output of their respective predecessor</tt> </tt> | ||
4953 | 124 | <a name="L61"></a><tt class="py-lineno"> 61</tt> <tt class="py-line"><tt class="py-docstring"> function in the sequence (with the obvious exception of the</tt> </tt> | ||
4954 | 125 | <a name="L62"></a><tt class="py-lineno"> 62</tt> <tt class="py-line"><tt class="py-docstring"> first function)</tt> </tt> | ||
4955 | 126 | <a name="L63"></a><tt class="py-lineno"> 63</tt> <tt class="py-line"><tt class="py-docstring"> - are applied to the full file *path* (whereas the shell-style</tt> </tt> | ||
4956 | 127 | <a name="L64"></a><tt class="py-lineno"> 64</tt> <tt class="py-line"><tt class="py-docstring"> wildcards are only applied to the file *names*)</tt> </tt> | ||
4957 | 128 | <a name="L65"></a><tt class="py-lineno"> 65</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
4958 | 129 | <a name="L66"></a><tt class="py-lineno"> 66</tt> <tt class="py-line"><tt class="py-docstring"> @type path: string</tt> </tt> | ||
4959 | 130 | <a name="L67"></a><tt class="py-lineno"> 67</tt> <tt class="py-line"><tt class="py-docstring"> @param path: starting path of the directory tree to be searched</tt> </tt> | ||
4960 | 131 | <a name="L68"></a><tt class="py-lineno"> 68</tt> <tt class="py-line"><tt class="py-docstring"> @type shellglobs: sequence</tt> </tt> | ||
4961 | 132 | <a name="L69"></a><tt class="py-lineno"> 69</tt> <tt class="py-line"><tt class="py-docstring"> @param shellglobs: an optional sequence of Unix shell-style wildcards</tt> </tt> | ||
4962 | 133 | <a name="L70"></a><tt class="py-lineno"> 70</tt> <tt class="py-line"><tt class="py-docstring"> that are to be applied to the file *names* found</tt> </tt> | ||
4963 | 134 | <a name="L71"></a><tt class="py-lineno"> 71</tt> <tt class="py-line"><tt class="py-docstring"> @type namefs: sequence</tt> </tt> | ||
4964 | 135 | <a name="L72"></a><tt class="py-lineno"> 72</tt> <tt class="py-line"><tt class="py-docstring"> @param namefs: an optional sequence of functions to be applied to the</tt> </tt> | ||
4965 | 136 | <a name="L73"></a><tt class="py-lineno"> 73</tt> <tt class="py-line"><tt class="py-docstring"> file *paths* found</tt> </tt> | ||
4966 | 137 | <a name="L74"></a><tt class="py-lineno"> 74</tt> <tt class="py-line"><tt class="py-docstring"> @type relative: bool</tt> </tt> | ||
4967 | 138 | <a name="L75"></a><tt class="py-lineno"> 75</tt> <tt class="py-line"><tt class="py-docstring"> @param relative: a boolean flag that determines whether absolute or</tt> </tt> | ||
4968 | 139 | <a name="L76"></a><tt class="py-lineno"> 76</tt> <tt class="py-line"><tt class="py-docstring"> relative paths should be returned</tt> </tt> | ||
4969 | 140 | <a name="L77"></a><tt class="py-lineno"> 77</tt> <tt class="py-line"><tt class="py-docstring"> @rtype: sequence</tt> </tt> | ||
4970 | 141 | <a name="L78"></a><tt class="py-lineno"> 78</tt> <tt class="py-line"><tt class="py-docstring"> @return: paths for files found</tt> </tt> | ||
4971 | 142 | <a name="L79"></a><tt class="py-lineno"> 79</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt> | ||
4972 | 143 | <a name="L80"></a><tt class="py-lineno"> 80</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">access</tt><tt class="py-op">(</tt><tt class="py-name">path</tt><tt class="py-op">,</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">R_OK</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4973 | 144 | <a name="L81"></a><tt class="py-lineno"> 81</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-0" class="py-name" targets="Class scriptutil.find.ScriptError=scriptutil.find.ScriptError-class.html"><a title="scriptutil.find.ScriptError" class="py-name" href="#" onclick="return doclink('link-0', 'ScriptError', 'link-0');">ScriptError</a></tt><tt class="py-op">(</tt><tt class="py-string">"cannot access path: '%s'"</tt> <tt class="py-op">%</tt> <tt class="py-name">path</tt><tt class="py-op">)</tt> </tt> | ||
4974 | 145 | <a name="L82"></a><tt class="py-lineno"> 82</tt> <tt class="py-line"> </tt> | ||
4975 | 146 | <a name="L83"></a><tt class="py-lineno"> 83</tt> <tt class="py-line"> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> <tt class="py-comment"># result list</tt> </tt> | ||
4976 | 147 | <a name="L84"></a><tt class="py-lineno"> 84</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt> | ||
4977 | 148 | <a name="L85"></a><tt class="py-lineno"> 85</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">dir</tt><tt class="py-op">,</tt> <tt class="py-name">subdirs</tt><tt class="py-op">,</tt> <tt class="py-name">files</tt> <tt class="py-keyword">in</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">walk</tt><tt class="py-op">(</tt><tt class="py-name">path</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4978 | 149 | <a name="L86"></a><tt class="py-lineno"> 86</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">shellglobs</tt><tt class="py-op">:</tt> </tt> | ||
4979 | 150 | <a name="L87"></a><tt class="py-lineno"> 87</tt> <tt class="py-line"> <tt class="py-name">matched</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt> | ||
4980 | 151 | <a name="L88"></a><tt class="py-lineno"> 88</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">pattern</tt> <tt class="py-keyword">in</tt> <tt class="py-name">shellglobs</tt><tt class="py-op">:</tt> </tt> | ||
4981 | 152 | <a name="L89"></a><tt class="py-lineno"> 89</tt> <tt class="py-line"> <tt class="py-name">filterf</tt> <tt class="py-op">=</tt> <tt class="py-keyword">lambda</tt> <tt class="py-name">s</tt><tt class="py-op">:</tt> <tt class="py-name">fnmatch</tt><tt class="py-op">.</tt><tt class="py-name">fnmatchcase</tt><tt class="py-op">(</tt><tt class="py-name">s</tt><tt class="py-op">,</tt> <tt class="py-name">pattern</tt><tt class="py-op">)</tt> </tt> | ||
4982 | 153 | <a name="L90"></a><tt class="py-lineno"> 90</tt> <tt class="py-line"> <tt class="py-name">matched</tt><tt class="py-op">.</tt><tt class="py-name">extend</tt><tt class="py-op">(</tt><tt class="py-name">filter</tt><tt class="py-op">(</tt><tt class="py-name">filterf</tt><tt class="py-op">,</tt> <tt class="py-name">files</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
4983 | 154 | <a name="L91"></a><tt class="py-lineno"> 91</tt> <tt class="py-line"> <tt class="py-name">fileList</tt><tt class="py-op">.</tt><tt class="py-name">extend</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-string">'%s%s%s'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">dir</tt><tt class="py-op">,</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">sep</tt><tt class="py-op">,</tt> <tt class="py-name">f</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">f</tt> <tt class="py-keyword">in</tt> <tt class="py-name">matched</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt> | ||
4984 | 155 | <a name="L92"></a><tt class="py-lineno"> 92</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt> | ||
4985 | 156 | <a name="L93"></a><tt class="py-lineno"> 93</tt> <tt class="py-line"> <tt class="py-name">fileList</tt><tt class="py-op">.</tt><tt class="py-name">extend</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-string">'%s%s%s'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">dir</tt><tt class="py-op">,</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">sep</tt><tt class="py-op">,</tt> <tt class="py-name">f</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">f</tt> <tt class="py-keyword">in</tt> <tt class="py-name">files</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt> | ||
4986 | 157 | <a name="L94"></a><tt class="py-lineno"> 94</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">relative</tt><tt class="py-op">:</tt> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt class="py-name">map</tt><tt class="py-op">(</tt><tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">path</tt><tt class="py-op">.</tt><tt class="py-name">abspath</tt><tt class="py-op">,</tt> <tt class="py-name">fileList</tt><tt class="py-op">)</tt> </tt> | ||
4987 | 158 | <a name="L95"></a><tt class="py-lineno"> 95</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">namefs</tt><tt class="py-op">:</tt> </tt> | ||
4988 | 159 | <a name="L96"></a><tt class="py-lineno"> 96</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">ff</tt> <tt class="py-keyword">in</tt> <tt class="py-name">namefs</tt><tt class="py-op">:</tt> <tt class="py-name">fileList</tt> <tt class="py-op">=</tt> <tt class="py-name">filter</tt><tt class="py-op">(</tt><tt class="py-name">ff</tt><tt class="py-op">,</tt> <tt class="py-name">fileList</tt><tt class="py-op">)</tt> </tt> | ||
4989 | 160 | <a name="L97"></a><tt class="py-lineno"> 97</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">Exception</tt><tt class="py-op">,</tt> <tt class="py-name">e</tt><tt class="py-op">:</tt> <tt class="py-keyword">raise</tt> <tt id="link-1" class="py-name"><a title="scriptutil.find.ScriptError" class="py-name" href="#" onclick="return doclink('link-1', 'ScriptError', 'link-0');">ScriptError</a></tt><tt class="py-op">(</tt><tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt> | ||
4990 | 161 | <a name="L98"></a><tt class="py-lineno"> 98</tt> <tt class="py-line"> <tt class="py-keyword">return</tt><tt class="py-op">(</tt><tt class="py-name">fileList</tt><tt class="py-op">)</tt> </tt> | ||
4991 | 162 | </div><a name="L99"></a><tt class="py-lineno"> 99</tt> <tt class="py-line"> </tt> | ||
4992 | 163 | <a name="L100"></a><tt class="py-lineno">100</tt> <tt class="py-line"> </tt> | ||
4993 | 164 | <a name="grep"></a><div id="grep-def"><a name="L101"></a><tt class="py-lineno">101</tt> <a class="py-toggle" href="#" id="grep-toggle" onclick="return toggle('grep');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="scriptutil.find-module.html#grep">grep</a><tt class="py-op">(</tt><tt class="py-param">path</tt><tt class="py-op">,</tt> <tt class="py-param">regexl</tt><tt class="py-op">,</tt> <tt class="py-param">shellglobs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">namefs</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> </tt> | ||
4994 | 165 | <a name="L102"></a><tt class="py-lineno">102</tt> <tt class="py-line"> <tt class="py-param">relative</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> <tt class="py-param">linenums</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt> | ||
4995 | 166 | </div><div id="grep-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="grep-expanded"><a name="L103"></a><tt class="py-lineno">103</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt> | ||
4996 | 167 | <a name="L104"></a><tt class="py-lineno">104</tt> <tt class="py-line"><tt class="py-docstring"> Find files in the directory tree starting at 'path' (filtered by</tt> </tt> | ||
4997 | 168 | <a name="L105"></a><tt class="py-lineno">105</tt> <tt class="py-line"><tt class="py-docstring"> Unix shell-style wildcards ('shellglobs') and/or the functions in</tt> </tt> | ||
4998 | 169 | <a name="L106"></a><tt class="py-lineno">106</tt> <tt class="py-line"><tt class="py-docstring"> the 'namefs' sequence) and search inside these.</tt> </tt> | ||
4999 | 170 | <a name="L107"></a><tt class="py-lineno">107</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt> | ||
5000 | 171 | <a name="L108"></a><tt class="py-lineno">108</tt> <tt class="py-line"><tt class="py-docstring"> Additionaly, the file content will be filtered by the regular</tt> </tt> |
The diff has been truncated for viewing.
HTML doc re-generated.