sprout 1.1.15.pre → 1.1.16.pre
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of sprout might be problematic. Click here for more details.
- data/VERSION +1 -1
- data/lib/sprout/executable/base.rb +7 -7
- metadata +101 -252
- data/Gemfile.lock +0 -50
- data/doc/Dir.html +0 -288
- data/doc/Rake/Task.html +0 -184
- data/doc/Sprout.html +0 -740
- data/doc/Sprout/ArchiveUnpacker.html +0 -1246
- data/doc/Sprout/CommandLine.html +0 -520
- data/doc/Sprout/Concern.html +0 -351
- data/doc/Sprout/Errors.html +0 -101
- data/doc/Sprout/Errors/ArchiveUnpackerError.html +0 -125
- data/doc/Sprout/Errors/DestinationExistsError.html +0 -133
- data/doc/Sprout/Errors/DuplicateMemberError.html +0 -132
- data/doc/Sprout/Errors/ExecutableError.html +0 -125
- data/doc/Sprout/Errors/ExecutableRegistrationError.html +0 -132
- data/doc/Sprout/Errors/ExecutionError.html +0 -121
- data/doc/Sprout/Errors/GeneratorError.html +0 -125
- data/doc/Sprout/Errors/InvalidArgumentError.html +0 -132
- data/doc/Sprout/Errors/LoadError.html +0 -121
- data/doc/Sprout/Errors/MissingArgumentError.html +0 -132
- data/doc/Sprout/Errors/MissingExecutableError.html +0 -132
- data/doc/Sprout/Errors/MissingGeneratorError.html +0 -132
- data/doc/Sprout/Errors/MissingTemplateError.html +0 -132
- data/doc/Sprout/Errors/ProcessRunnerError.html +0 -121
- data/doc/Sprout/Errors/RemoteFileLoaderError.html +0 -110
- data/doc/Sprout/Errors/SproutError.html +0 -114
- data/doc/Sprout/Errors/UnknownArchiveType.html +0 -122
- data/doc/Sprout/Errors/UsageError.html +0 -121
- data/doc/Sprout/Errors/ValidationError.html +0 -121
- data/doc/Sprout/Errors/VersionRequirementNotMetError.html +0 -121
- data/doc/Sprout/Executable.html +0 -169
- data/doc/Sprout/Executable/Base.html +0 -2813
- data/doc/Sprout/Executable/Boolean.html +0 -534
- data/doc/Sprout/Executable/CollectionParam.html +0 -483
- data/doc/Sprout/Executable/FileParam.html +0 -484
- data/doc/Sprout/Executable/Files.html +0 -292
- data/doc/Sprout/Executable/Number.html +0 -141
- data/doc/Sprout/Executable/Param.html +0 -2874
- data/doc/Sprout/Executable/ParameterFactory.html +0 -232
- data/doc/Sprout/Executable/Path.html +0 -223
- data/doc/Sprout/Executable/Paths.html +0 -253
- data/doc/Sprout/Executable/Session.html +0 -1513
- data/doc/Sprout/Executable/StringParam.html +0 -213
- data/doc/Sprout/Executable/Strings.html +0 -167
- data/doc/Sprout/Executable/Url.html +0 -160
- data/doc/Sprout/Executable/Urls.html +0 -170
- data/doc/Sprout/FileTarget.html +0 -1109
- data/doc/Sprout/Generator.html +0 -750
- data/doc/Sprout/Generator/Base.html +0 -1902
- data/doc/Sprout/Generator/Command.html +0 -690
- data/doc/Sprout/Generator/DirectoryManifest.html +0 -476
- data/doc/Sprout/Generator/FileManifest.html +0 -643
- data/doc/Sprout/Generator/Manifest.html +0 -377
- data/doc/Sprout/Generator/TemplateManifest.html +0 -194
- data/doc/Sprout/GeneratorGenerator.html +0 -1115
- data/doc/Sprout/Library.html +0 -1146
- data/doc/Sprout/LibraryGenerator.html +0 -331
- data/doc/Sprout/OutputBuffer.html +0 -445
- data/doc/Sprout/Platform.html +0 -714
- data/doc/Sprout/ProcessRunner.html +0 -1707
- data/doc/Sprout/ProgressBar.html +0 -366
- data/doc/Sprout/ProgressBarImpl.html +0 -2109
- data/doc/Sprout/ProgressBarManager.html +0 -424
- data/doc/Sprout/ProgressBarOutputStream.html +0 -406
- data/doc/Sprout/RDocParser.html +0 -211
- data/doc/Sprout/RemoteFileLoader.html +0 -172
- data/doc/Sprout/RemoteFileTarget.html +0 -679
- data/doc/Sprout/ReversedProgressBar.html +0 -184
- data/doc/Sprout/RubyFeature.html +0 -155
- data/doc/Sprout/RubyFeature/ClassMethods.html +0 -1065
- data/doc/Sprout/RubyGenerator.html +0 -786
- data/doc/Sprout/Specification.html +0 -767
- data/doc/Sprout/System.html +0 -191
- data/doc/Sprout/System/BaseSystem.html +0 -1660
- data/doc/Sprout/System/JavaSystem.html +0 -122
- data/doc/Sprout/System/OSXSystem.html +0 -335
- data/doc/Sprout/System/ThreadMock.html +0 -183
- data/doc/Sprout/System/UnixSystem.html +0 -584
- data/doc/Sprout/System/VistaSystem.html +0 -251
- data/doc/Sprout/System/WinNixSystem.html +0 -325
- data/doc/Sprout/System/WinSystem.html +0 -571
- data/doc/Sprout/TestHelper.html +0 -2165
- data/doc/Sprout/ToolGenerator.html +0 -953
- data/doc/Sprout/VERSION.html +0 -118
- data/doc/String.html +0 -290
- data/doc/_index.html +0 -820
- data/doc/class_list.html +0 -36
- data/doc/css/common.css +0 -1
- data/doc/css/full_list.css +0 -53
- data/doc/css/style.css +0 -310
- data/doc/file.README.html +0 -96
- data/doc/file_list.html +0 -41
- data/doc/frames.html +0 -13
- data/doc/index.html +0 -96
- data/doc/js/app.js +0 -202
- data/doc/js/full_list.js +0 -149
- data/doc/js/jquery.js +0 -154
- data/doc/method_list.html +0 -3603
- data/doc/top-level-namespace.html +0 -192
- data/test/fixtures/library/archive/Archive.swc +0 -0
@@ -1,1902 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
4
|
-
<head>
|
5
|
-
<meta name="Content-Type" content="text/html; charset=utf-8" />
|
6
|
-
<title>Class: Sprout::Generator::Base</title>
|
7
|
-
<link rel="stylesheet" href="../../css/style.css" type="text/css" media="screen" charset="utf-8" />
|
8
|
-
<link rel="stylesheet" href="../../css/common.css" type="text/css" media="screen" charset="utf-8" />
|
9
|
-
|
10
|
-
<script type="text/javascript" charset="utf-8">
|
11
|
-
relpath = '../..';
|
12
|
-
if (relpath != '') relpath += '/';
|
13
|
-
</script>
|
14
|
-
<script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
|
15
|
-
<script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
|
16
|
-
|
17
|
-
</head>
|
18
|
-
<body>
|
19
|
-
<script type="text/javascript" charset="utf-8">
|
20
|
-
if (window.top.frames.main) document.body.className = 'frames';
|
21
|
-
</script>
|
22
|
-
|
23
|
-
<div id="header">
|
24
|
-
<div id="menu">
|
25
|
-
|
26
|
-
<a href="../../_index.html">Index (B)</a> »
|
27
|
-
<span class='title'><span class='object_link'><a href="../../Sprout.html" title="Sprout (module)">Sprout</a></span></span> » <span class='title'><span class='object_link'><a href="../Generator.html" title="Sprout::Generator (module)">Generator</a></span></span>
|
28
|
-
»
|
29
|
-
<span class="title">Base</span>
|
30
|
-
|
31
|
-
|
32
|
-
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
33
|
-
</div>
|
34
|
-
|
35
|
-
<div id="search">
|
36
|
-
<a id="class_list_link" href="#">Class List</a>
|
37
|
-
<a id="method_list_link" href="#">Method List</a>
|
38
|
-
<a id ="file_list_link" href="#">File List</a>
|
39
|
-
</div>
|
40
|
-
|
41
|
-
<div class="clear"></div>
|
42
|
-
</div>
|
43
|
-
|
44
|
-
<iframe id="search_frame"></iframe>
|
45
|
-
|
46
|
-
<div id="content"><h1>Class: Sprout::Generator::Base
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
</h1>
|
51
|
-
|
52
|
-
<dl class="box">
|
53
|
-
|
54
|
-
<dt class="r1">Inherits:</dt>
|
55
|
-
<dd class="r1">
|
56
|
-
<span class="inheritName"><span class='object_link'><a href="../Executable/Base.html" title="Sprout::Executable::Base (class)">Executable::Base</a></span></span>
|
57
|
-
|
58
|
-
<ul class="fullTree">
|
59
|
-
<li>Object</li>
|
60
|
-
|
61
|
-
<li class="next"><span class='object_link'><a href="../Executable/Base.html" title="Sprout::Executable::Base (class)">Executable::Base</a></span></li>
|
62
|
-
|
63
|
-
<li class="next">Sprout::Generator::Base</li>
|
64
|
-
|
65
|
-
</ul>
|
66
|
-
<a href="#" class="inheritanceTree">show all</a>
|
67
|
-
|
68
|
-
</dd>
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
<dt class="r2 last">Defined in:</dt>
|
79
|
-
<dd class="r2 last">lib/sprout/generator/base.rb</dd>
|
80
|
-
|
81
|
-
</dl>
|
82
|
-
<div class="clear"></div>
|
83
|
-
|
84
|
-
<div id="subclasses">
|
85
|
-
<h2>Direct Known Subclasses</h2>
|
86
|
-
<p class="children"><span class='object_link'><a href="../GeneratorGenerator.html" title="Sprout::GeneratorGenerator (class)">Sprout::GeneratorGenerator</a></span>, <span class='object_link'><a href="../LibraryGenerator.html" title="Sprout::LibraryGenerator (class)">LibraryGenerator</a></span>, <span class='object_link'><a href="../RubyGenerator.html" title="Sprout::RubyGenerator (class)">RubyGenerator</a></span>, <span class='object_link'><a href="../ToolGenerator.html" title="Sprout::ToolGenerator (class)">ToolGenerator</a></span></p>
|
87
|
-
</div>
|
88
|
-
|
89
|
-
<h2>Constant Summary</h2>
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
<h3 class="inherited">Constants included from <span class='object_link'><a href="../Executable.html" title="Sprout::Executable (module)">Executable</a></span></h3>
|
102
|
-
<p class="inherited"><span class='object_link'><a href="../Executable.html#DEFAULT_FILE_EXPRESSION-constant" title="Sprout::Executable::DEFAULT_FILE_EXPRESSION (constant)">DEFAULT_FILE_EXPRESSION</a></span>, <span class='object_link'><a href="../Executable.html#DEFAULT_PREFIX-constant" title="Sprout::Executable::DEFAULT_PREFIX (constant)">DEFAULT_PREFIX</a></span>, <span class='object_link'><a href="../Executable.html#DEFAULT_SHORT_PREFIX-constant" title="Sprout::Executable::DEFAULT_SHORT_PREFIX (constant)">DEFAULT_SHORT_PREFIX</a></span></p>
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
<h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2>
|
113
|
-
<ul class="summary">
|
114
|
-
|
115
|
-
<li class="public ">
|
116
|
-
<span class="summary_signature">
|
117
|
-
|
118
|
-
<a href="#destroy-instance_method" title="#destroy (instance method)">- (Boolean) <strong>destroy</strong> </a>
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
</span>
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
<span class="summary_desc"><div class='inline'>
|
135
|
-
<p>Insteast of creating, destroy the files.</p>
|
136
|
-
</div></span>
|
137
|
-
|
138
|
-
</li>
|
139
|
-
|
140
|
-
|
141
|
-
<li class="public ">
|
142
|
-
<span class="summary_signature">
|
143
|
-
|
144
|
-
<a href="#force-instance_method" title="#force (instance method)">- (Boolean) <strong>force</strong> </a>
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
</span>
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
<span class="summary_desc"><div class='inline'>
|
161
|
-
<p>Force the creation of files without prompting.</p>
|
162
|
-
</div></span>
|
163
|
-
|
164
|
-
</li>
|
165
|
-
|
166
|
-
|
167
|
-
<li class="public ">
|
168
|
-
<span class="summary_signature">
|
169
|
-
|
170
|
-
<a href="#input-instance_method" title="#input (instance method)">- (String) <strong>input</strong> </a>
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
</span>
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
<span class="summary_desc"><div class='inline'>
|
187
|
-
<p>The primary input for the application or component.</p>
|
188
|
-
</div></span>
|
189
|
-
|
190
|
-
</li>
|
191
|
-
|
192
|
-
|
193
|
-
<li class="public ">
|
194
|
-
<span class="summary_signature">
|
195
|
-
|
196
|
-
<a href="#logger-instance_method" title="#logger (instance method)">- (Object) <strong>logger</strong> </a>
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
</span>
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
<span class="summary_desc"><div class='inline'>
|
213
|
-
<p>Returns the value of attribute logger.</p>
|
214
|
-
</div></span>
|
215
|
-
|
216
|
-
</li>
|
217
|
-
|
218
|
-
|
219
|
-
<li class="public ">
|
220
|
-
<span class="summary_signature">
|
221
|
-
|
222
|
-
<a href="#name-instance_method" title="#name (instance method)">- (Object) <strong>name</strong> </a>
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
</span>
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
<span class="summary_desc"><div class='inline'>
|
239
|
-
<p>The symbol name for which this generator is most appropriate.</p>
|
240
|
-
</div></span>
|
241
|
-
|
242
|
-
</li>
|
243
|
-
|
244
|
-
|
245
|
-
<li class="public ">
|
246
|
-
<span class="summary_signature">
|
247
|
-
|
248
|
-
<a href="#path-instance_method" title="#path (instance method)">- (Path) <strong>path</strong> </a>
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
</span>
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
<span class="summary_desc"><div class='inline'>
|
265
|
-
<p>The directory where files will be created.</p>
|
266
|
-
</div></span>
|
267
|
-
|
268
|
-
</li>
|
269
|
-
|
270
|
-
|
271
|
-
<li class="public ">
|
272
|
-
<span class="summary_signature">
|
273
|
-
|
274
|
-
<a href="#pkg_name-instance_method" title="#pkg_name (instance method)">- (Object) <strong>pkg_name</strong> </a>
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
</span>
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
<span class="summary_desc"><div class='inline'>
|
291
|
-
<p>Returns the value of attribute pkg_name.</p>
|
292
|
-
</div></span>
|
293
|
-
|
294
|
-
</li>
|
295
|
-
|
296
|
-
|
297
|
-
<li class="public ">
|
298
|
-
<span class="summary_signature">
|
299
|
-
|
300
|
-
<a href="#pkg_version-instance_method" title="#pkg_version (instance method)">- (Object) <strong>pkg_version</strong> </a>
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
</span>
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
<span class="summary_desc"><div class='inline'>
|
317
|
-
<p>Returns the value of attribute pkg_version.</p>
|
318
|
-
</div></span>
|
319
|
-
|
320
|
-
</li>
|
321
|
-
|
322
|
-
|
323
|
-
<li class="public ">
|
324
|
-
<span class="summary_signature">
|
325
|
-
|
326
|
-
<a href="#quiet-instance_method" title="#quiet (instance method)">- (Boolean) <strong>quiet</strong> </a>
|
327
|
-
|
328
|
-
|
329
|
-
|
330
|
-
</span>
|
331
|
-
|
332
|
-
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
<span class="summary_desc"><div class='inline'>
|
343
|
-
<p>Run the generator in Quiet mode - do not write status to standard output.</p>
|
344
|
-
</div></span>
|
345
|
-
|
346
|
-
</li>
|
347
|
-
|
348
|
-
|
349
|
-
<li class="public ">
|
350
|
-
<span class="summary_signature">
|
351
|
-
|
352
|
-
<a href="#show_template_paths-instance_method" title="#show_template_paths (instance method)">- (Boolean) <strong>show_template_paths</strong> </a>
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
</span>
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
<span class="summary_desc"><div class='inline'>
|
369
|
-
<p>Display the paths this generator will use to look for templates on this
|
370
|
-
system and exit.</p>
|
371
|
-
</div></span>
|
372
|
-
|
373
|
-
</li>
|
374
|
-
|
375
|
-
|
376
|
-
<li class="public ">
|
377
|
-
<span class="summary_signature">
|
378
|
-
|
379
|
-
<a href="#templates-instance_method" title="#templates (instance method)">- (Array<String> [Paths]) <strong>templates</strong> </a>
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
</span>
|
384
|
-
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
<span class="summary_desc"><div class='inline'>
|
396
|
-
<p>A collection of paths to look in for named templates.</p>
|
397
|
-
</div></span>
|
398
|
-
|
399
|
-
</li>
|
400
|
-
|
401
|
-
|
402
|
-
</ul>
|
403
|
-
|
404
|
-
|
405
|
-
|
406
|
-
<h2>
|
407
|
-
Class Method Summary
|
408
|
-
<small>(<a href="#" class="summary_toggle">collapse</a>)</small>
|
409
|
-
</h2>
|
410
|
-
|
411
|
-
<ul class="summary">
|
412
|
-
|
413
|
-
<li class="public ">
|
414
|
-
<span class="summary_signature">
|
415
|
-
|
416
|
-
<a href="#inherited-class_method" title="inherited (class method)">+ (Object) <strong>inherited</strong>(base) </a>
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
</span>
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
429
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
430
|
-
|
431
|
-
</li>
|
432
|
-
|
433
|
-
|
434
|
-
</ul>
|
435
|
-
|
436
|
-
<h2>
|
437
|
-
Instance Method Summary
|
438
|
-
<small>(<a href="#" class="summary_toggle">collapse</a>)</small>
|
439
|
-
</h2>
|
440
|
-
|
441
|
-
<ul class="summary">
|
442
|
-
|
443
|
-
<li class="public ">
|
444
|
-
<span class="summary_signature">
|
445
|
-
|
446
|
-
<a href="#create_template_paths-instance_method" title="#create_template_paths (instance method)">- (Object) <strong>create_template_paths</strong> </a>
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
</span>
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
460
|
-
|
461
|
-
</li>
|
462
|
-
|
463
|
-
|
464
|
-
<li class="protected ">
|
465
|
-
<span class="summary_signature">
|
466
|
-
|
467
|
-
<a href="#default_search_paths-instance_method" title="#default_search_paths (instance method)">- (Object) <strong>default_search_paths</strong> </a>
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
</span>
|
472
|
-
|
473
|
-
|
474
|
-
<span class="note title protected">protected</span>
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
481
|
-
|
482
|
-
</li>
|
483
|
-
|
484
|
-
|
485
|
-
<li class="protected ">
|
486
|
-
<span class="summary_signature">
|
487
|
-
|
488
|
-
<a href="#directory-instance_method" title="#directory (instance method)">- (Object) <strong>directory</strong>(name, &block) </a>
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
</span>
|
493
|
-
|
494
|
-
|
495
|
-
<span class="note title protected">protected</span>
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
|
501
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
502
|
-
|
503
|
-
</li>
|
504
|
-
|
505
|
-
|
506
|
-
<li class="protected ">
|
507
|
-
<span class="summary_signature">
|
508
|
-
|
509
|
-
<a href="#do_show_template_paths-instance_method" title="#do_show_template_paths (instance method)">- (Object) <strong>do_show_template_paths</strong> </a>
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
</span>
|
514
|
-
|
515
|
-
|
516
|
-
<span class="note title protected">protected</span>
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
523
|
-
|
524
|
-
</li>
|
525
|
-
|
526
|
-
|
527
|
-
<li class="public ">
|
528
|
-
<span class="summary_signature">
|
529
|
-
|
530
|
-
<a href="#execute-instance_method" title="#execute (instance method)">- (Object) <strong>execute</strong> </a>
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
</span>
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
<span class="summary_desc"><div class='inline'>
|
544
|
-
<p>Record the actions and trigger them.</p>
|
545
|
-
</div></span>
|
546
|
-
|
547
|
-
</li>
|
548
|
-
|
549
|
-
|
550
|
-
<li class="protected ">
|
551
|
-
<span class="summary_signature">
|
552
|
-
|
553
|
-
<a href="#file-instance_method" title="#file (instance method)">- (Object) <strong>file</strong>(name, template = nil) </a>
|
554
|
-
|
555
|
-
|
556
|
-
|
557
|
-
</span>
|
558
|
-
|
559
|
-
|
560
|
-
<span class="note title protected">protected</span>
|
561
|
-
|
562
|
-
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
567
|
-
|
568
|
-
</li>
|
569
|
-
|
570
|
-
|
571
|
-
<li class="protected ">
|
572
|
-
<span class="summary_signature">
|
573
|
-
|
574
|
-
<a href="#generator-instance_method" title="#generator (instance method)">- (Object) <strong>generator</strong>(name, options = {}) </a>
|
575
|
-
|
576
|
-
|
577
|
-
|
578
|
-
</span>
|
579
|
-
|
580
|
-
|
581
|
-
<span class="note title protected">protected</span>
|
582
|
-
|
583
|
-
|
584
|
-
|
585
|
-
|
586
|
-
|
587
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
588
|
-
|
589
|
-
</li>
|
590
|
-
|
591
|
-
|
592
|
-
<li class="protected ">
|
593
|
-
<span class="summary_signature">
|
594
|
-
|
595
|
-
<a href="#prepare_command-instance_method" title="#prepare_command (instance method)">- (Object) <strong>prepare_command</strong> </a>
|
596
|
-
|
597
|
-
|
598
|
-
|
599
|
-
</span>
|
600
|
-
|
601
|
-
|
602
|
-
<span class="note title protected">protected</span>
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
609
|
-
|
610
|
-
</li>
|
611
|
-
|
612
|
-
|
613
|
-
<li class="public ">
|
614
|
-
<span class="summary_signature">
|
615
|
-
|
616
|
-
<a href="#resolve_template-instance_method" title="#resolve_template (instance method)">- (Object) <strong>resolve_template</strong>(content) </a>
|
617
|
-
|
618
|
-
|
619
|
-
|
620
|
-
</span>
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
<span class="summary_desc"><div class='inline'>
|
630
|
-
<p>TODO: Add support for arbitrary templating languages.</p>
|
631
|
-
</div></span>
|
632
|
-
|
633
|
-
</li>
|
634
|
-
|
635
|
-
|
636
|
-
<li class="public ">
|
637
|
-
<span class="summary_signature">
|
638
|
-
|
639
|
-
<a href="#say-instance_method" title="#say (instance method)">- (Object) <strong>say</strong>(message) </a>
|
640
|
-
|
641
|
-
|
642
|
-
|
643
|
-
</span>
|
644
|
-
|
645
|
-
|
646
|
-
|
647
|
-
|
648
|
-
|
649
|
-
|
650
|
-
|
651
|
-
|
652
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
653
|
-
|
654
|
-
</li>
|
655
|
-
|
656
|
-
|
657
|
-
<li class="protected ">
|
658
|
-
<span class="summary_signature">
|
659
|
-
|
660
|
-
<a href="#template-instance_method" title="#template (instance method)">- (Object) <strong>template</strong>(name, template = nil) </a>
|
661
|
-
|
662
|
-
|
663
|
-
|
664
|
-
</span>
|
665
|
-
|
666
|
-
|
667
|
-
<span class="note title protected">protected</span>
|
668
|
-
|
669
|
-
|
670
|
-
|
671
|
-
|
672
|
-
|
673
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
674
|
-
|
675
|
-
</li>
|
676
|
-
|
677
|
-
|
678
|
-
<li class="public ">
|
679
|
-
<span class="summary_signature">
|
680
|
-
|
681
|
-
<a href="#template_paths-instance_method" title="#template_paths (instance method)">- (Object) <strong>template_paths</strong> </a>
|
682
|
-
|
683
|
-
|
684
|
-
|
685
|
-
</span>
|
686
|
-
|
687
|
-
|
688
|
-
|
689
|
-
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
|
694
|
-
<span class="summary_desc"><div class='inline'>
|
695
|
-
<p>Returns a collection of templates that were provided on the command line,
|
696
|
-
followed by templates that are created by a concrete generator, followed
|
697
|
-
by the Sprout::Generator.search_paths + 'templates' folders.</p>
|
698
|
-
</div></span>
|
699
|
-
|
700
|
-
</li>
|
701
|
-
|
702
|
-
|
703
|
-
<li class="public ">
|
704
|
-
<span class="summary_signature">
|
705
|
-
|
706
|
-
<a href="#unexecute-instance_method" title="#unexecute (instance method)">- (Object) <strong>unexecute</strong> </a>
|
707
|
-
|
708
|
-
|
709
|
-
|
710
|
-
</span>
|
711
|
-
|
712
|
-
|
713
|
-
|
714
|
-
|
715
|
-
|
716
|
-
|
717
|
-
|
718
|
-
|
719
|
-
<span class="summary_desc"><div class='inline'>
|
720
|
-
<p>Rollback the generator.</p>
|
721
|
-
</div></span>
|
722
|
-
|
723
|
-
</li>
|
724
|
-
|
725
|
-
|
726
|
-
<li class="public ">
|
727
|
-
<span class="summary_signature">
|
728
|
-
|
729
|
-
<a href="#validate-instance_method" title="#validate (instance method)">- (Object) <strong>validate</strong> </a>
|
730
|
-
|
731
|
-
|
732
|
-
|
733
|
-
</span>
|
734
|
-
|
735
|
-
|
736
|
-
|
737
|
-
|
738
|
-
|
739
|
-
|
740
|
-
|
741
|
-
|
742
|
-
<span class="summary_desc"><div class='inline'></div></span>
|
743
|
-
|
744
|
-
</li>
|
745
|
-
|
746
|
-
|
747
|
-
</ul>
|
748
|
-
|
749
|
-
|
750
|
-
|
751
|
-
|
752
|
-
|
753
|
-
|
754
|
-
|
755
|
-
|
756
|
-
|
757
|
-
|
758
|
-
<h3 class="inherited">Methods inherited from <span class='object_link'><a href="../Executable/Base.html" title="Sprout::Executable::Base (class)">Executable::Base</a></span></h3>
|
759
|
-
<p class="inherited"><span class='object_link'><a href="../Executable/Base.html#add_param-class_method" title="Sprout::Executable::Base.add_param (method)">add_param</a></span>, <span class='object_link'><a href="../Executable/Base.html#add_param_alias-class_method" title="Sprout::Executable::Base.add_param_alias (method)">add_param_alias</a></span>, <span class='object_link'><a href="../Executable/Base.html#binary_path-instance_method" title="Sprout::Executable::Base#binary_path (method)">#binary_path</a></span>, <span class='object_link'><a href="../Executable/Base.html#binary_path%3D-instance_method" title="Sprout::Executable::Base#binary_path= (method)">#binary_path=</a></span>, <span class='object_link'><a href="../Executable/Base.html#create_outer_task-instance_method" title="Sprout::Executable::Base#create_outer_task (method)">#create_outer_task</a></span>, <span class='object_link'><a href="../Executable/Base.html#default_file_expression-instance_method" title="Sprout::Executable::Base#default_file_expression (method)">#default_file_expression</a></span>, <span class='object_link'><a href="../Executable/Base.html#execute_delegate-instance_method" title="Sprout::Executable::Base#execute_delegate (method)">#execute_delegate</a></span>, <span class='object_link'><a href="../Executable/Base.html#from_hash-instance_method" title="Sprout::Executable::Base#from_hash (method)">#from_hash</a></span>, <span class='object_link'><a href="../Executable/Base.html#initialize-instance_method" title="Sprout::Executable::Base#initialize (method)">#initialize</a></span>, <span class='object_link'><a href="../Executable/Base.html#library_added-instance_method" title="Sprout::Executable::Base#library_added (method)">#library_added</a></span>, <span class='object_link'><a href="../Executable/Base.html#parse%21-instance_method" title="Sprout::Executable::Base#parse! (method)">#parse!</a></span>, <span class='object_link'><a href="../Executable/Base.html#parse_extra_options%21-instance_method" title="Sprout::Executable::Base#parse_extra_options! (method)">#parse_extra_options!</a></span>, <span class='object_link'><a href="../Executable/Base.html#parse_rake_task_arg-instance_method" title="Sprout::Executable::Base#parse_rake_task_arg (method)">#parse_rake_task_arg</a></span>, <span class='object_link'><a href="../Executable/Base.html#prepare-instance_method" title="Sprout::Executable::Base#prepare (method)">#prepare</a></span>, <span class='object_link'><a href="../Executable/Base.html#set-class_method" title="Sprout::Executable::Base.set (method)">set</a></span>, <span class='object_link'><a href="../Executable/Base.html#static_default_value_collection-class_method" title="Sprout::Executable::Base.static_default_value_collection (method)">static_default_value_collection</a></span>, <span class='object_link'><a href="../Executable/Base.html#static_parameter_collection-class_method" title="Sprout::Executable::Base.static_parameter_collection (method)">static_parameter_collection</a></span>, <span class='object_link'><a href="../Executable/Base.html#stderr-instance_method" title="Sprout::Executable::Base#stderr (method)">#stderr</a></span>, <span class='object_link'><a href="../Executable/Base.html#stderr%3D-instance_method" title="Sprout::Executable::Base#stderr= (method)">#stderr=</a></span>, <span class='object_link'><a href="../Executable/Base.html#stdout-instance_method" title="Sprout::Executable::Base#stdout (method)">#stdout</a></span>, <span class='object_link'><a href="../Executable/Base.html#stdout%3D-instance_method" title="Sprout::Executable::Base#stdout= (method)">#stdout=</a></span>, <span class='object_link'><a href="../Executable/Base.html#system_execute-instance_method" title="Sprout::Executable::Base#system_execute (method)">#system_execute</a></span>, <span class='object_link'><a href="../Executable/Base.html#to_hash-instance_method" title="Sprout::Executable::Base#to_hash (method)">#to_hash</a></span>, <span class='object_link'><a href="../Executable/Base.html#to_help-instance_method" title="Sprout::Executable::Base#to_help (method)">#to_help</a></span>, <span class='object_link'><a href="../Executable/Base.html#to_rake-instance_method" title="Sprout::Executable::Base#to_rake (method)">#to_rake</a></span>, <span class='object_link'><a href="../Executable/Base.html#to_shell-instance_method" title="Sprout::Executable::Base#to_shell (method)">#to_shell</a></span>, <span class='object_link'><a href="../Executable/Base.html#update_rake_task_name_from_args-instance_method" title="Sprout::Executable::Base#update_rake_task_name_from_args (method)">#update_rake_task_name_from_args</a></span></p>
|
760
|
-
|
761
|
-
|
762
|
-
|
763
|
-
|
764
|
-
|
765
|
-
|
766
|
-
|
767
|
-
|
768
|
-
|
769
|
-
|
770
|
-
|
771
|
-
|
772
|
-
|
773
|
-
|
774
|
-
|
775
|
-
|
776
|
-
|
777
|
-
|
778
|
-
<h3 class="inherited">Methods included from <span class='object_link'><a href="../Concern.html" title="Sprout::Concern (module)">Concern</a></span></h3>
|
779
|
-
<p class="inherited"><span class='object_link'><a href="../Concern.html#append_features-instance_method" title="Sprout::Concern#append_features (method)">#append_features</a></span>, <span class='object_link'><a href="../Concern.html#extended-class_method" title="Sprout::Concern.extended (method)">extended</a></span>, <span class='object_link'><a href="../Concern.html#included-instance_method" title="Sprout::Concern#included (method)">#included</a></span></p>
|
780
|
-
<div id="constructor_details" class="method_details_list">
|
781
|
-
<h2>Constructor Details</h2>
|
782
|
-
|
783
|
-
<p class="notice">This class inherits a constructor from <span class='object_link'><a href="../Executable/Base.html#initialize-instance_method" title="Sprout::Executable::Base#initialize (method)">Sprout::Executable::Base</a></span></p>
|
784
|
-
|
785
|
-
</div>
|
786
|
-
|
787
|
-
<div id="instance_attr_details" class="attr_details">
|
788
|
-
<h2>Instance Attribute Details</h2>
|
789
|
-
|
790
|
-
|
791
|
-
<span id="destroy=-instance_method"></span>
|
792
|
-
<span id="destroy-instance_method"></span>
|
793
|
-
<div class="method_details first">
|
794
|
-
<p class="signature first" id="destroy-instance_method">
|
795
|
-
|
796
|
-
- (<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>) <strong>destroy</strong>
|
797
|
-
|
798
|
-
|
799
|
-
|
800
|
-
</p><div class="docstring">
|
801
|
-
<div class="discussion">
|
802
|
-
|
803
|
-
<p>Insteast of creating, destroy the files.</p>
|
804
|
-
|
805
|
-
|
806
|
-
</div>
|
807
|
-
</div>
|
808
|
-
<div class="tags">
|
809
|
-
<h3>Returns:</h3>
|
810
|
-
<ul class="return">
|
811
|
-
|
812
|
-
<li>
|
813
|
-
|
814
|
-
<span class='type'>(<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>)</span>
|
815
|
-
|
816
|
-
|
817
|
-
|
818
|
-
|
819
|
-
—
|
820
|
-
<div class='inline'>
|
821
|
-
<p>An instance of Boolean</p>
|
822
|
-
</div>
|
823
|
-
|
824
|
-
</li>
|
825
|
-
|
826
|
-
</ul>
|
827
|
-
|
828
|
-
</div><table class="source_code">
|
829
|
-
<tr>
|
830
|
-
<td>
|
831
|
-
<pre class="lines">
|
832
|
-
|
833
|
-
|
834
|
-
</pre>
|
835
|
-
</td>
|
836
|
-
<td>
|
837
|
-
<pre class="code"><span class="info file"># File ''</span>
|
838
|
-
|
839
|
-
<span class='id add_param'>add_param</span> <span class='symbol'>:destroy</span><span class='comma'>,</span> <span class='const'>Boolean</span></pre>
|
840
|
-
</td>
|
841
|
-
</tr>
|
842
|
-
</table>
|
843
|
-
</div>
|
844
|
-
|
845
|
-
|
846
|
-
<span id="force=-instance_method"></span>
|
847
|
-
<span id="force-instance_method"></span>
|
848
|
-
<div class="method_details ">
|
849
|
-
<p class="signature " id="force-instance_method">
|
850
|
-
|
851
|
-
- (<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>) <strong>force</strong>
|
852
|
-
|
853
|
-
|
854
|
-
|
855
|
-
</p><div class="docstring">
|
856
|
-
<div class="discussion">
|
857
|
-
|
858
|
-
<p>Force the creation of files without prompting.</p>
|
859
|
-
|
860
|
-
|
861
|
-
</div>
|
862
|
-
</div>
|
863
|
-
<div class="tags">
|
864
|
-
<h3>Returns:</h3>
|
865
|
-
<ul class="return">
|
866
|
-
|
867
|
-
<li>
|
868
|
-
|
869
|
-
<span class='type'>(<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>)</span>
|
870
|
-
|
871
|
-
|
872
|
-
|
873
|
-
|
874
|
-
—
|
875
|
-
<div class='inline'>
|
876
|
-
<p>An instance of Boolean</p>
|
877
|
-
</div>
|
878
|
-
|
879
|
-
</li>
|
880
|
-
|
881
|
-
</ul>
|
882
|
-
|
883
|
-
</div><table class="source_code">
|
884
|
-
<tr>
|
885
|
-
<td>
|
886
|
-
<pre class="lines">
|
887
|
-
|
888
|
-
|
889
|
-
</pre>
|
890
|
-
</td>
|
891
|
-
<td>
|
892
|
-
<pre class="code"><span class="info file"># File ''</span>
|
893
|
-
|
894
|
-
<span class='id add_param'>add_param</span> <span class='symbol'>:force</span><span class='comma'>,</span> <span class='const'>Boolean</span></pre>
|
895
|
-
</td>
|
896
|
-
</tr>
|
897
|
-
</table>
|
898
|
-
</div>
|
899
|
-
|
900
|
-
|
901
|
-
<span id="input=-instance_method"></span>
|
902
|
-
<span id="input-instance_method"></span>
|
903
|
-
<div class="method_details ">
|
904
|
-
<p class="signature " id="input-instance_method">
|
905
|
-
|
906
|
-
- (<tt><span class='object_link'><a href="../../String.html" title="String (class)">String</a></span></tt>) <strong>input</strong>
|
907
|
-
|
908
|
-
|
909
|
-
|
910
|
-
</p><div class="docstring">
|
911
|
-
<div class="discussion">
|
912
|
-
|
913
|
-
<p>The primary input for the application or component.</p>
|
914
|
-
|
915
|
-
|
916
|
-
</div>
|
917
|
-
</div>
|
918
|
-
<div class="tags">
|
919
|
-
<h3>Returns:</h3>
|
920
|
-
<ul class="return">
|
921
|
-
|
922
|
-
<li>
|
923
|
-
|
924
|
-
<span class='type'>(<tt><span class='object_link'><a href="../../String.html" title="String (class)">String</a></span></tt>)</span>
|
925
|
-
|
926
|
-
|
927
|
-
|
928
|
-
|
929
|
-
—
|
930
|
-
<div class='inline'>
|
931
|
-
<p>An instance of String</p>
|
932
|
-
</div>
|
933
|
-
|
934
|
-
</li>
|
935
|
-
|
936
|
-
</ul>
|
937
|
-
|
938
|
-
</div><table class="source_code">
|
939
|
-
<tr>
|
940
|
-
<td>
|
941
|
-
<pre class="lines">
|
942
|
-
|
943
|
-
|
944
|
-
</pre>
|
945
|
-
</td>
|
946
|
-
<td>
|
947
|
-
<pre class="code"><span class="info file"># File ''</span>
|
948
|
-
|
949
|
-
<span class='id add_param'>add_param</span> <span class='symbol'>:input</span><span class='comma'>,</span> <span class='const'>String</span><span class='comma'>,</span> <span class='lbrace'>{</span> <span class='symbol'>:hidden_name</span> <span class='op'>=></span> <span class='kw'>true</span><span class='comma'>,</span> <span class='symbol'>:required</span> <span class='op'>=></span> <span class='kw'>true</span> <span class='rbrace'>}</span></pre>
|
950
|
-
</td>
|
951
|
-
</tr>
|
952
|
-
</table>
|
953
|
-
</div>
|
954
|
-
|
955
|
-
|
956
|
-
<span id="logger=-instance_method"></span>
|
957
|
-
<span id="logger-instance_method"></span>
|
958
|
-
<div class="method_details ">
|
959
|
-
<p class="signature " id="logger-instance_method">
|
960
|
-
|
961
|
-
- (<tt>Object</tt>) <strong>logger</strong>
|
962
|
-
|
963
|
-
|
964
|
-
|
965
|
-
</p><div class="docstring">
|
966
|
-
<div class="discussion">
|
967
|
-
|
968
|
-
<p>Returns the value of attribute logger</p>
|
969
|
-
|
970
|
-
|
971
|
-
</div>
|
972
|
-
</div>
|
973
|
-
<div class="tags">
|
974
|
-
|
975
|
-
</div><table class="source_code">
|
976
|
-
<tr>
|
977
|
-
<td>
|
978
|
-
<pre class="lines">
|
979
|
-
|
980
|
-
|
981
|
-
73
|
982
|
-
74
|
983
|
-
75</pre>
|
984
|
-
</td>
|
985
|
-
<td>
|
986
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 73</span>
|
987
|
-
|
988
|
-
<span class='kw'>def</span> <span class='id logger'>logger</span>
|
989
|
-
<span class='ivar'>@logger</span>
|
990
|
-
<span class='kw'>end</span></pre>
|
991
|
-
</td>
|
992
|
-
</tr>
|
993
|
-
</table>
|
994
|
-
</div>
|
995
|
-
|
996
|
-
|
997
|
-
<span id="name=-instance_method"></span>
|
998
|
-
<span id="name-instance_method"></span>
|
999
|
-
<div class="method_details ">
|
1000
|
-
<p class="signature " id="name-instance_method">
|
1001
|
-
|
1002
|
-
- (<tt>Object</tt>) <strong>name</strong>
|
1003
|
-
|
1004
|
-
|
1005
|
-
|
1006
|
-
</p><div class="docstring">
|
1007
|
-
<div class="discussion">
|
1008
|
-
|
1009
|
-
<p>The symbol name for which this generator is most appropriate.</p>
|
1010
|
-
|
1011
|
-
<p>This value defaults to :application so, if you're working on an application
|
1012
|
-
generator, you can leave it as the default.</p>
|
1013
|
-
|
1014
|
-
<p>For all other generator types, you'll want to select the most general
|
1015
|
-
project type that this generator may be useful in.</p>
|
1016
|
-
|
1017
|
-
<p>Following are some example values:</p>
|
1018
|
-
|
1019
|
-
<pre class="code">:as3, :flex3, :flex4, :air2</pre>
|
1020
|
-
|
1021
|
-
<p>or core libraries:</p>
|
1022
|
-
|
1023
|
-
<pre class="code">:asunit4, :flexunit4</pre>
|
1024
|
-
|
1025
|
-
<p>or even other libraries:</p>
|
1026
|
-
|
1027
|
-
<pre class="code">:puremvc, :robotlegs, :swizz</pre>
|
1028
|
-
|
1029
|
-
|
1030
|
-
</div>
|
1031
|
-
</div>
|
1032
|
-
<div class="tags">
|
1033
|
-
|
1034
|
-
</div><table class="source_code">
|
1035
|
-
<tr>
|
1036
|
-
<td>
|
1037
|
-
<pre class="lines">
|
1038
|
-
|
1039
|
-
|
1040
|
-
72
|
1041
|
-
73
|
1042
|
-
74</pre>
|
1043
|
-
</td>
|
1044
|
-
<td>
|
1045
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 72</span>
|
1046
|
-
|
1047
|
-
<span class='kw'>def</span> <span class='id name'>name</span>
|
1048
|
-
<span class='ivar'>@name</span>
|
1049
|
-
<span class='kw'>end</span></pre>
|
1050
|
-
</td>
|
1051
|
-
</tr>
|
1052
|
-
</table>
|
1053
|
-
</div>
|
1054
|
-
|
1055
|
-
|
1056
|
-
<span id="path=-instance_method"></span>
|
1057
|
-
<span id="path-instance_method"></span>
|
1058
|
-
<div class="method_details ">
|
1059
|
-
<p class="signature " id="path-instance_method">
|
1060
|
-
|
1061
|
-
- (<tt><span class='object_link'><a href="../Executable/Path.html" title="Sprout::Executable::Path (class)">Path</a></span></tt>) <strong>path</strong>
|
1062
|
-
|
1063
|
-
|
1064
|
-
|
1065
|
-
</p><div class="docstring">
|
1066
|
-
<div class="discussion">
|
1067
|
-
|
1068
|
-
<p>The directory where files will be created.</p>
|
1069
|
-
|
1070
|
-
|
1071
|
-
</div>
|
1072
|
-
</div>
|
1073
|
-
<div class="tags">
|
1074
|
-
<h3>Returns:</h3>
|
1075
|
-
<ul class="return">
|
1076
|
-
|
1077
|
-
<li>
|
1078
|
-
|
1079
|
-
<span class='type'>(<tt><span class='object_link'><a href="../Executable/Path.html" title="Sprout::Executable::Path (class)">Path</a></span></tt>)</span>
|
1080
|
-
|
1081
|
-
|
1082
|
-
|
1083
|
-
|
1084
|
-
—
|
1085
|
-
<div class='inline'>
|
1086
|
-
<p>An instance of Path</p>
|
1087
|
-
</div>
|
1088
|
-
|
1089
|
-
</li>
|
1090
|
-
|
1091
|
-
</ul>
|
1092
|
-
|
1093
|
-
</div><table class="source_code">
|
1094
|
-
<tr>
|
1095
|
-
<td>
|
1096
|
-
<pre class="lines">
|
1097
|
-
|
1098
|
-
|
1099
|
-
</pre>
|
1100
|
-
</td>
|
1101
|
-
<td>
|
1102
|
-
<pre class="code"><span class="info file"># File ''</span>
|
1103
|
-
|
1104
|
-
<span class='id add_param'>add_param</span> <span class='symbol'>:path</span><span class='comma'>,</span> <span class='const'>Path</span><span class='comma'>,</span> <span class='lbrace'>{</span> <span class='symbol'>:default</span> <span class='op'>=></span> <span class='const'>Dir</span><span class='period'>.</span><span class='id pwd'>pwd</span> <span class='rbrace'>}</span></pre>
|
1105
|
-
</td>
|
1106
|
-
</tr>
|
1107
|
-
</table>
|
1108
|
-
</div>
|
1109
|
-
|
1110
|
-
|
1111
|
-
<span id="pkg_name=-instance_method"></span>
|
1112
|
-
<span id="pkg_name-instance_method"></span>
|
1113
|
-
<div class="method_details ">
|
1114
|
-
<p class="signature " id="pkg_name-instance_method">
|
1115
|
-
|
1116
|
-
- (<tt>Object</tt>) <strong>pkg_name</strong>
|
1117
|
-
|
1118
|
-
|
1119
|
-
|
1120
|
-
</p><div class="docstring">
|
1121
|
-
<div class="discussion">
|
1122
|
-
|
1123
|
-
<p>Returns the value of attribute pkg_name</p>
|
1124
|
-
|
1125
|
-
|
1126
|
-
</div>
|
1127
|
-
</div>
|
1128
|
-
<div class="tags">
|
1129
|
-
|
1130
|
-
</div><table class="source_code">
|
1131
|
-
<tr>
|
1132
|
-
<td>
|
1133
|
-
<pre class="lines">
|
1134
|
-
|
1135
|
-
|
1136
|
-
74
|
1137
|
-
75
|
1138
|
-
76</pre>
|
1139
|
-
</td>
|
1140
|
-
<td>
|
1141
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 74</span>
|
1142
|
-
|
1143
|
-
<span class='kw'>def</span> <span class='id pkg_name'>pkg_name</span>
|
1144
|
-
<span class='ivar'>@pkg_name</span>
|
1145
|
-
<span class='kw'>end</span></pre>
|
1146
|
-
</td>
|
1147
|
-
</tr>
|
1148
|
-
</table>
|
1149
|
-
</div>
|
1150
|
-
|
1151
|
-
|
1152
|
-
<span id="pkg_version=-instance_method"></span>
|
1153
|
-
<span id="pkg_version-instance_method"></span>
|
1154
|
-
<div class="method_details ">
|
1155
|
-
<p class="signature " id="pkg_version-instance_method">
|
1156
|
-
|
1157
|
-
- (<tt>Object</tt>) <strong>pkg_version</strong>
|
1158
|
-
|
1159
|
-
|
1160
|
-
|
1161
|
-
</p><div class="docstring">
|
1162
|
-
<div class="discussion">
|
1163
|
-
|
1164
|
-
<p>Returns the value of attribute pkg_version</p>
|
1165
|
-
|
1166
|
-
|
1167
|
-
</div>
|
1168
|
-
</div>
|
1169
|
-
<div class="tags">
|
1170
|
-
|
1171
|
-
</div><table class="source_code">
|
1172
|
-
<tr>
|
1173
|
-
<td>
|
1174
|
-
<pre class="lines">
|
1175
|
-
|
1176
|
-
|
1177
|
-
75
|
1178
|
-
76
|
1179
|
-
77</pre>
|
1180
|
-
</td>
|
1181
|
-
<td>
|
1182
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 75</span>
|
1183
|
-
|
1184
|
-
<span class='kw'>def</span> <span class='id pkg_version'>pkg_version</span>
|
1185
|
-
<span class='ivar'>@pkg_version</span>
|
1186
|
-
<span class='kw'>end</span></pre>
|
1187
|
-
</td>
|
1188
|
-
</tr>
|
1189
|
-
</table>
|
1190
|
-
</div>
|
1191
|
-
|
1192
|
-
|
1193
|
-
<span id="quiet=-instance_method"></span>
|
1194
|
-
<span id="quiet-instance_method"></span>
|
1195
|
-
<div class="method_details ">
|
1196
|
-
<p class="signature " id="quiet-instance_method">
|
1197
|
-
|
1198
|
-
- (<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>) <strong>quiet</strong>
|
1199
|
-
|
1200
|
-
|
1201
|
-
|
1202
|
-
</p><div class="docstring">
|
1203
|
-
<div class="discussion">
|
1204
|
-
|
1205
|
-
<p>Run the generator in Quiet mode - do not write status to standard output.</p>
|
1206
|
-
|
1207
|
-
|
1208
|
-
</div>
|
1209
|
-
</div>
|
1210
|
-
<div class="tags">
|
1211
|
-
<h3>Returns:</h3>
|
1212
|
-
<ul class="return">
|
1213
|
-
|
1214
|
-
<li>
|
1215
|
-
|
1216
|
-
<span class='type'>(<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>)</span>
|
1217
|
-
|
1218
|
-
|
1219
|
-
|
1220
|
-
|
1221
|
-
—
|
1222
|
-
<div class='inline'>
|
1223
|
-
<p>An instance of Boolean</p>
|
1224
|
-
</div>
|
1225
|
-
|
1226
|
-
</li>
|
1227
|
-
|
1228
|
-
</ul>
|
1229
|
-
|
1230
|
-
</div><table class="source_code">
|
1231
|
-
<tr>
|
1232
|
-
<td>
|
1233
|
-
<pre class="lines">
|
1234
|
-
|
1235
|
-
|
1236
|
-
</pre>
|
1237
|
-
</td>
|
1238
|
-
<td>
|
1239
|
-
<pre class="code"><span class="info file"># File ''</span>
|
1240
|
-
|
1241
|
-
<span class='id add_param'>add_param</span> <span class='symbol'>:quiet</span><span class='comma'>,</span> <span class='const'>Boolean</span></pre>
|
1242
|
-
</td>
|
1243
|
-
</tr>
|
1244
|
-
</table>
|
1245
|
-
</div>
|
1246
|
-
|
1247
|
-
|
1248
|
-
<span id="show_template_paths=-instance_method"></span>
|
1249
|
-
<span id="show_template_paths-instance_method"></span>
|
1250
|
-
<div class="method_details ">
|
1251
|
-
<p class="signature " id="show_template_paths-instance_method">
|
1252
|
-
|
1253
|
-
- (<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>) <strong>show_template_paths</strong>
|
1254
|
-
|
1255
|
-
|
1256
|
-
|
1257
|
-
</p><div class="docstring">
|
1258
|
-
<div class="discussion">
|
1259
|
-
|
1260
|
-
<p>Display the paths this generator will use to look for templates on this
|
1261
|
-
system and exit.</p>
|
1262
|
-
|
1263
|
-
|
1264
|
-
</div>
|
1265
|
-
</div>
|
1266
|
-
<div class="tags">
|
1267
|
-
<h3>Returns:</h3>
|
1268
|
-
<ul class="return">
|
1269
|
-
|
1270
|
-
<li>
|
1271
|
-
|
1272
|
-
<span class='type'>(<tt><span class='object_link'><a href="../Executable/Boolean.html" title="Sprout::Executable::Boolean (class)">Boolean</a></span></tt>)</span>
|
1273
|
-
|
1274
|
-
|
1275
|
-
|
1276
|
-
|
1277
|
-
—
|
1278
|
-
<div class='inline'>
|
1279
|
-
<p>An instance of Boolean</p>
|
1280
|
-
</div>
|
1281
|
-
|
1282
|
-
</li>
|
1283
|
-
|
1284
|
-
</ul>
|
1285
|
-
|
1286
|
-
</div><table class="source_code">
|
1287
|
-
<tr>
|
1288
|
-
<td>
|
1289
|
-
<pre class="lines">
|
1290
|
-
|
1291
|
-
|
1292
|
-
</pre>
|
1293
|
-
</td>
|
1294
|
-
<td>
|
1295
|
-
<pre class="code"><span class="info file"># File ''</span>
|
1296
|
-
|
1297
|
-
<span class='id add_param'>add_param</span> <span class='symbol'>:show_template_paths</span><span class='comma'>,</span> <span class='const'>Boolean</span></pre>
|
1298
|
-
</td>
|
1299
|
-
</tr>
|
1300
|
-
</table>
|
1301
|
-
</div>
|
1302
|
-
|
1303
|
-
|
1304
|
-
<span id="templates=-instance_method"></span>
|
1305
|
-
<span id="templates-instance_method"></span>
|
1306
|
-
<div class="method_details ">
|
1307
|
-
<p class="signature " id="templates-instance_method">
|
1308
|
-
|
1309
|
-
- (<tt>Array<<span class='object_link'><a href="../../String.html" title="String (class)">String</a></span>> [<span class='object_link'><a href="../Executable/Paths.html" title="Sprout::Executable::Paths (class)">Paths</a></span>]</tt>) <strong>templates</strong>
|
1310
|
-
|
1311
|
-
|
1312
|
-
|
1313
|
-
</p><div class="docstring">
|
1314
|
-
<div class="discussion">
|
1315
|
-
|
1316
|
-
<p>A collection of paths to look in for named templates.</p>
|
1317
|
-
|
1318
|
-
|
1319
|
-
</div>
|
1320
|
-
</div>
|
1321
|
-
<div class="tags">
|
1322
|
-
<h3>Returns:</h3>
|
1323
|
-
<ul class="return">
|
1324
|
-
|
1325
|
-
<li>
|
1326
|
-
|
1327
|
-
<span class='type'>(<tt>Array<<span class='object_link'><a href="../../String.html" title="String (class)">String</a></span>> [<span class='object_link'><a href="../Executable/Paths.html" title="Sprout::Executable::Paths (class)">Paths</a></span>]</tt>)</span>
|
1328
|
-
|
1329
|
-
|
1330
|
-
|
1331
|
-
|
1332
|
-
—
|
1333
|
-
<div class='inline'>
|
1334
|
-
<p>An instance of Array<String> [Paths]</p>
|
1335
|
-
</div>
|
1336
|
-
|
1337
|
-
</li>
|
1338
|
-
|
1339
|
-
</ul>
|
1340
|
-
|
1341
|
-
</div><table class="source_code">
|
1342
|
-
<tr>
|
1343
|
-
<td>
|
1344
|
-
<pre class="lines">
|
1345
|
-
|
1346
|
-
|
1347
|
-
</pre>
|
1348
|
-
</td>
|
1349
|
-
<td>
|
1350
|
-
<pre class="code"><span class="info file"># File ''</span>
|
1351
|
-
|
1352
|
-
<span class='id add_param'>add_param</span> <span class='symbol'>:templates</span><span class='comma'>,</span> <span class='const'>Paths</span></pre>
|
1353
|
-
</td>
|
1354
|
-
</tr>
|
1355
|
-
</table>
|
1356
|
-
</div>
|
1357
|
-
|
1358
|
-
</div>
|
1359
|
-
|
1360
|
-
|
1361
|
-
<div id="class_method_details" class="method_details_list">
|
1362
|
-
<h2>Class Method Details</h2>
|
1363
|
-
|
1364
|
-
|
1365
|
-
<div class="method_details first">
|
1366
|
-
<p class="signature first" id="inherited-class_method">
|
1367
|
-
|
1368
|
-
+ (<tt>Object</tt>) <strong>inherited</strong>(base)
|
1369
|
-
|
1370
|
-
|
1371
|
-
|
1372
|
-
</p><table class="source_code">
|
1373
|
-
<tr>
|
1374
|
-
<td>
|
1375
|
-
<pre class="lines">
|
1376
|
-
|
1377
|
-
|
1378
|
-
6
|
1379
|
-
7
|
1380
|
-
8
|
1381
|
-
9
|
1382
|
-
10
|
1383
|
-
11
|
1384
|
-
12
|
1385
|
-
13
|
1386
|
-
14</pre>
|
1387
|
-
</td>
|
1388
|
-
<td>
|
1389
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 6</span>
|
1390
|
-
|
1391
|
-
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id inherited'>inherited</span> <span class='id base'>base</span>
|
1392
|
-
<span class='comment'># NOTE: We can NOT instantiate the class here,
|
1393
|
-
</span> <span class='comment'># because only it's first line has been interpreted, if we
|
1394
|
-
</span> <span class='comment'># instantiate here, none of the code declared in the class body will
|
1395
|
-
</span> <span class='comment'># be associated with this instance.
|
1396
|
-
</span> <span class='comment'>#
|
1397
|
-
</span> <span class='comment'># Go ahead and register the class and update instances later...
|
1398
|
-
</span> <span class='const'>Sprout</span><span class='op'>::</span><span class='const'>Generator</span><span class='period'>.</span><span class='id register'>register</span> <span class='id base'>base</span><span class='comma'>,</span> <span class='id template_from_caller'>template_from_caller</span><span class='lparen'>(</span><span class='id caller'>caller</span><span class='period'>.</span><span class='id first'>first</span><span class='rparen'>)</span>
|
1399
|
-
<span class='kw'>end</span></pre>
|
1400
|
-
</td>
|
1401
|
-
</tr>
|
1402
|
-
</table>
|
1403
|
-
</div>
|
1404
|
-
|
1405
|
-
</div>
|
1406
|
-
|
1407
|
-
<div id="instance_method_details" class="method_details_list">
|
1408
|
-
<h2>Instance Method Details</h2>
|
1409
|
-
|
1410
|
-
|
1411
|
-
<div class="method_details first">
|
1412
|
-
<p class="signature first" id="create_template_paths-instance_method">
|
1413
|
-
|
1414
|
-
- (<tt>Object</tt>) <strong>create_template_paths</strong>
|
1415
|
-
|
1416
|
-
|
1417
|
-
|
1418
|
-
</p><table class="source_code">
|
1419
|
-
<tr>
|
1420
|
-
<td>
|
1421
|
-
<pre class="lines">
|
1422
|
-
|
1423
|
-
|
1424
|
-
122
|
1425
|
-
123
|
1426
|
-
124
|
1427
|
-
125
|
1428
|
-
126</pre>
|
1429
|
-
</td>
|
1430
|
-
<td>
|
1431
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 122</span>
|
1432
|
-
|
1433
|
-
<span class='kw'>def</span> <span class='id create_template_paths'>create_template_paths</span>
|
1434
|
-
<span class='id paths'>paths</span> <span class='op'>=</span> <span class='id templates'>templates</span><span class='period'>.</span><span class='id dup'>dup</span>
|
1435
|
-
<span class='id paths'>paths</span> <span class='op'>=</span> <span class='id paths'>paths</span><span class='period'>.</span><span class='id concat'>concat</span> <span class='const'>Sprout</span><span class='op'>::</span><span class='const'>Generator</span><span class='period'>.</span><span class='id search_paths'>search_paths</span>
|
1436
|
-
<span class='id paths'>paths</span> <span class='op'><<</span> <span class='const'>Sprout</span><span class='op'>::</span><span class='const'>Generator</span><span class='op'>::</span><span class='id template_folder_for'>template_folder_for</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span>
|
1437
|
-
<span class='kw'>end</span></pre>
|
1438
|
-
</td>
|
1439
|
-
</tr>
|
1440
|
-
</table>
|
1441
|
-
</div>
|
1442
|
-
|
1443
|
-
<div class="method_details ">
|
1444
|
-
<p class="signature " id="default_search_paths-instance_method">
|
1445
|
-
|
1446
|
-
- (<tt>Object</tt>) <strong>default_search_paths</strong> <span class="extras">(protected)</span>
|
1447
|
-
|
1448
|
-
|
1449
|
-
|
1450
|
-
</p><table class="source_code">
|
1451
|
-
<tr>
|
1452
|
-
<td>
|
1453
|
-
<pre class="lines">
|
1454
|
-
|
1455
|
-
|
1456
|
-
145
|
1457
|
-
146
|
1458
|
-
147</pre>
|
1459
|
-
</td>
|
1460
|
-
<td>
|
1461
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 145</span>
|
1462
|
-
|
1463
|
-
<span class='kw'>def</span> <span class='id default_search_paths'>default_search_paths</span>
|
1464
|
-
<span class='const'>Sprout</span><span class='op'>::</span><span class='const'>Generator</span><span class='period'>.</span><span class='id search_paths'>search_paths</span><span class='period'>.</span><span class='id collect'>collect</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id path'>path</span><span class='op'>|</span> <span class='const'>File</span><span class='period'>.</span><span class='id join'>join</span><span class='lparen'>(</span><span class='id path'>path</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>templates</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='rbrace'>}</span>
|
1465
|
-
<span class='kw'>end</span></pre>
|
1466
|
-
</td>
|
1467
|
-
</tr>
|
1468
|
-
</table>
|
1469
|
-
</div>
|
1470
|
-
|
1471
|
-
<div class="method_details ">
|
1472
|
-
<p class="signature " id="directory-instance_method">
|
1473
|
-
|
1474
|
-
- (<tt>Object</tt>) <strong>directory</strong>(name, &block) <span class="extras">(protected)</span>
|
1475
|
-
|
1476
|
-
|
1477
|
-
|
1478
|
-
</p><table class="source_code">
|
1479
|
-
<tr>
|
1480
|
-
<td>
|
1481
|
-
<pre class="lines">
|
1482
|
-
|
1483
|
-
|
1484
|
-
157
|
1485
|
-
158
|
1486
|
-
159</pre>
|
1487
|
-
</td>
|
1488
|
-
<td>
|
1489
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 157</span>
|
1490
|
-
|
1491
|
-
<span class='kw'>def</span> <span class='id directory'>directory</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='op'>&</span><span class='id block'>block</span>
|
1492
|
-
<span class='ivar'>@command</span><span class='period'>.</span><span class='id directory'>directory</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='op'>&</span><span class='id block'>block</span>
|
1493
|
-
<span class='kw'>end</span></pre>
|
1494
|
-
</td>
|
1495
|
-
</tr>
|
1496
|
-
</table>
|
1497
|
-
</div>
|
1498
|
-
|
1499
|
-
<div class="method_details ">
|
1500
|
-
<p class="signature " id="do_show_template_paths-instance_method">
|
1501
|
-
|
1502
|
-
- (<tt>Object</tt>) <strong>do_show_template_paths</strong> <span class="extras">(protected)</span>
|
1503
|
-
|
1504
|
-
|
1505
|
-
|
1506
|
-
</p><table class="source_code">
|
1507
|
-
<tr>
|
1508
|
-
<td>
|
1509
|
-
<pre class="lines">
|
1510
|
-
|
1511
|
-
|
1512
|
-
130
|
1513
|
-
131
|
1514
|
-
132
|
1515
|
-
133
|
1516
|
-
134
|
1517
|
-
135
|
1518
|
-
136
|
1519
|
-
137
|
1520
|
-
138
|
1521
|
-
139
|
1522
|
-
140
|
1523
|
-
141
|
1524
|
-
142
|
1525
|
-
143</pre>
|
1526
|
-
</td>
|
1527
|
-
<td>
|
1528
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 130</span>
|
1529
|
-
|
1530
|
-
<span class='kw'>def</span> <span class='id do_show_template_paths'>do_show_template_paths</span>
|
1531
|
-
<span class='ivar'>@logger</span> <span class='op'>||=</span> <span class='gvar'>$stdout</span>
|
1532
|
-
<span class='id message'>message</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>The following paths will be checked for templates:\n</span><span class='tstring_end'>"</span></span>
|
1533
|
-
|
1534
|
-
<span class='id paths'>paths</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>--templates+=[value]</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span>
|
1535
|
-
<span class='id paths'>paths</span> <span class='op'>=</span> <span class='id paths'>paths</span><span class='period'>.</span><span class='id concat'>concat</span> <span class='const'>Sprout</span><span class='op'>::</span><span class='const'>Generator</span><span class='period'>.</span><span class='id create_search_paths'>create_search_paths</span>
|
1536
|
-
<span class='id paths'>paths</span> <span class='op'><<</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ENV['SPROUT_GENERATORS']</span><span class='tstring_end'>"</span></span>
|
1537
|
-
<span class='id paths'>paths</span> <span class='op'><<</span> <span class='const'>Sprout</span><span class='op'>::</span><span class='const'>Generator</span><span class='op'>::</span><span class='id template_folder_for'>template_folder_for</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span>
|
1538
|
-
|
1539
|
-
<span class='id message'>message</span> <span class='op'><<</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'> * </span><span class='tstring_end'>"</span></span>
|
1540
|
-
<span class='id message'>message</span> <span class='op'><<</span> <span class='id paths'>paths</span><span class='period'>.</span><span class='id join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>\n * </span><span class='tstring_end'>"</span></span><span class='rparen'>)</span>
|
1541
|
-
<span class='id say'>say</span> <span class='id message'>message</span>
|
1542
|
-
<span class='id message'>message</span>
|
1543
|
-
<span class='kw'>end</span></pre>
|
1544
|
-
</td>
|
1545
|
-
</tr>
|
1546
|
-
</table>
|
1547
|
-
</div>
|
1548
|
-
|
1549
|
-
<div class="method_details ">
|
1550
|
-
<p class="signature " id="execute-instance_method">
|
1551
|
-
|
1552
|
-
- (<tt>Object</tt>) <strong>execute</strong>
|
1553
|
-
|
1554
|
-
|
1555
|
-
|
1556
|
-
</p><div class="docstring">
|
1557
|
-
<div class="discussion">
|
1558
|
-
|
1559
|
-
<p>Record the actions and trigger them</p>
|
1560
|
-
|
1561
|
-
|
1562
|
-
</div>
|
1563
|
-
</div>
|
1564
|
-
<div class="tags">
|
1565
|
-
|
1566
|
-
</div><table class="source_code">
|
1567
|
-
<tr>
|
1568
|
-
<td>
|
1569
|
-
<pre class="lines">
|
1570
|
-
|
1571
|
-
|
1572
|
-
79
|
1573
|
-
80
|
1574
|
-
81
|
1575
|
-
82
|
1576
|
-
83</pre>
|
1577
|
-
</td>
|
1578
|
-
<td>
|
1579
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 79</span>
|
1580
|
-
|
1581
|
-
<span class='kw'>def</span> <span class='id execute'>execute</span>
|
1582
|
-
<span class='kw'>return</span> <span class='id do_show_template_paths'>do_show_template_paths</span> <span class='kw'>if</span> <span class='id show_template_paths'>show_template_paths</span>
|
1583
|
-
<span class='kw'>return</span> <span class='id prepare_command'>prepare_command</span><span class='period'>.</span><span class='id unexecute'>unexecute</span> <span class='kw'>if</span> <span class='id destroy'>destroy</span>
|
1584
|
-
<span class='id prepare_command'>prepare_command</span><span class='period'>.</span><span class='id execute'>execute</span>
|
1585
|
-
<span class='kw'>end</span></pre>
|
1586
|
-
</td>
|
1587
|
-
</tr>
|
1588
|
-
</table>
|
1589
|
-
</div>
|
1590
|
-
|
1591
|
-
<div class="method_details ">
|
1592
|
-
<p class="signature " id="file-instance_method">
|
1593
|
-
|
1594
|
-
- (<tt>Object</tt>) <strong>file</strong>(name, template = nil) <span class="extras">(protected)</span>
|
1595
|
-
|
1596
|
-
|
1597
|
-
|
1598
|
-
</p><table class="source_code">
|
1599
|
-
<tr>
|
1600
|
-
<td>
|
1601
|
-
<pre class="lines">
|
1602
|
-
|
1603
|
-
|
1604
|
-
161
|
1605
|
-
162
|
1606
|
-
163</pre>
|
1607
|
-
</td>
|
1608
|
-
<td>
|
1609
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 161</span>
|
1610
|
-
|
1611
|
-
<span class='kw'>def</span> <span class='id file'>file</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id template'>template</span><span class='op'>=</span><span class='kw'>nil</span>
|
1612
|
-
<span class='ivar'>@command</span><span class='period'>.</span><span class='id file'>file</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id template'>template</span>
|
1613
|
-
<span class='kw'>end</span></pre>
|
1614
|
-
</td>
|
1615
|
-
</tr>
|
1616
|
-
</table>
|
1617
|
-
</div>
|
1618
|
-
|
1619
|
-
<div class="method_details ">
|
1620
|
-
<p class="signature " id="generator-instance_method">
|
1621
|
-
|
1622
|
-
- (<tt>Object</tt>) <strong>generator</strong>(name, options = {}) <span class="extras">(protected)</span>
|
1623
|
-
|
1624
|
-
|
1625
|
-
|
1626
|
-
</p><table class="source_code">
|
1627
|
-
<tr>
|
1628
|
-
<td>
|
1629
|
-
<pre class="lines">
|
1630
|
-
|
1631
|
-
|
1632
|
-
169
|
1633
|
-
170
|
1634
|
-
171</pre>
|
1635
|
-
</td>
|
1636
|
-
<td>
|
1637
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 169</span>
|
1638
|
-
|
1639
|
-
<span class='kw'>def</span> <span class='id generator'>generator</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span>
|
1640
|
-
<span class='ivar'>@command</span><span class='period'>.</span><span class='id generator'>generator</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id to_hash'>to_hash</span><span class='period'>.</span><span class='id merge'>merge</span><span class='lparen'>(</span><span class='id options'>options</span><span class='rparen'>)</span>
|
1641
|
-
<span class='kw'>end</span></pre>
|
1642
|
-
</td>
|
1643
|
-
</tr>
|
1644
|
-
</table>
|
1645
|
-
</div>
|
1646
|
-
|
1647
|
-
<div class="method_details ">
|
1648
|
-
<p class="signature " id="prepare_command-instance_method">
|
1649
|
-
|
1650
|
-
- (<tt>Object</tt>) <strong>prepare_command</strong> <span class="extras">(protected)</span>
|
1651
|
-
|
1652
|
-
|
1653
|
-
|
1654
|
-
</p><table class="source_code">
|
1655
|
-
<tr>
|
1656
|
-
<td>
|
1657
|
-
<pre class="lines">
|
1658
|
-
|
1659
|
-
|
1660
|
-
149
|
1661
|
-
150
|
1662
|
-
151
|
1663
|
-
152
|
1664
|
-
153
|
1665
|
-
154
|
1666
|
-
155</pre>
|
1667
|
-
</td>
|
1668
|
-
<td>
|
1669
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 149</span>
|
1670
|
-
|
1671
|
-
<span class='kw'>def</span> <span class='id prepare_command'>prepare_command</span>
|
1672
|
-
<span class='ivar'>@logger</span> <span class='op'>||=</span> <span class='gvar'>$stdout</span>
|
1673
|
-
<span class='ivar'>@command</span> <span class='op'>=</span> <span class='const'>Command</span><span class='period'>.</span><span class='id new'>new</span> <span class='kw'>self</span>
|
1674
|
-
<span class='ivar'>@command</span><span class='period'>.</span><span class='id logger'>logger</span> <span class='op'>=</span> <span class='id logger'>logger</span>
|
1675
|
-
<span class='id manifest'>manifest</span>
|
1676
|
-
<span class='ivar'>@command</span>
|
1677
|
-
<span class='kw'>end</span></pre>
|
1678
|
-
</td>
|
1679
|
-
</tr>
|
1680
|
-
</table>
|
1681
|
-
</div>
|
1682
|
-
|
1683
|
-
<div class="method_details ">
|
1684
|
-
<p class="signature " id="resolve_template-instance_method">
|
1685
|
-
|
1686
|
-
- (<tt>Object</tt>) <strong>resolve_template</strong>(content)
|
1687
|
-
|
1688
|
-
|
1689
|
-
|
1690
|
-
</p><div class="docstring">
|
1691
|
-
<div class="discussion">
|
1692
|
-
|
1693
|
-
<p>TODO: Add support for arbitrary templating languages. For now, just support
|
1694
|
-
ERB...</p>
|
1695
|
-
|
1696
|
-
<p>TODO: This is also a possible spot where those of you that don't want to
|
1697
|
-
snuggle might put pretty-print code or some such modifiers...</p>
|
1698
|
-
|
1699
|
-
|
1700
|
-
</div>
|
1701
|
-
</div>
|
1702
|
-
<div class="tags">
|
1703
|
-
|
1704
|
-
</div><table class="source_code">
|
1705
|
-
<tr>
|
1706
|
-
<td>
|
1707
|
-
<pre class="lines">
|
1708
|
-
|
1709
|
-
|
1710
|
-
107
|
1711
|
-
108
|
1712
|
-
109
|
1713
|
-
110</pre>
|
1714
|
-
</td>
|
1715
|
-
<td>
|
1716
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 107</span>
|
1717
|
-
|
1718
|
-
<span class='kw'>def</span> <span class='id resolve_template'>resolve_template</span> <span class='id content'>content</span>
|
1719
|
-
<span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>erb</span><span class='tstring_end'>'</span></span>
|
1720
|
-
<span class='const'>ERB</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id content'>content</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>></span><span class='tstring_end'>'</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id result'>result</span><span class='lparen'>(</span><span class='id binding'>binding</span><span class='rparen'>)</span>
|
1721
|
-
<span class='kw'>end</span></pre>
|
1722
|
-
</td>
|
1723
|
-
</tr>
|
1724
|
-
</table>
|
1725
|
-
</div>
|
1726
|
-
|
1727
|
-
<div class="method_details ">
|
1728
|
-
<p class="signature " id="say-instance_method">
|
1729
|
-
|
1730
|
-
- (<tt>Object</tt>) <strong>say</strong>(message)
|
1731
|
-
|
1732
|
-
|
1733
|
-
|
1734
|
-
</p><table class="source_code">
|
1735
|
-
<tr>
|
1736
|
-
<td>
|
1737
|
-
<pre class="lines">
|
1738
|
-
|
1739
|
-
|
1740
|
-
96
|
1741
|
-
97
|
1742
|
-
98</pre>
|
1743
|
-
</td>
|
1744
|
-
<td>
|
1745
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 96</span>
|
1746
|
-
|
1747
|
-
<span class='kw'>def</span> <span class='id say'>say</span> <span class='id message'>message</span>
|
1748
|
-
<span class='id logger'>logger</span><span class='period'>.</span><span class='id puts'>puts</span> <span class='id message'>message</span><span class='period'>.</span><span class='id gsub'>gsub</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id path'>path</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>.</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id quiet'>quiet</span>
|
1749
|
-
<span class='kw'>end</span></pre>
|
1750
|
-
</td>
|
1751
|
-
</tr>
|
1752
|
-
</table>
|
1753
|
-
</div>
|
1754
|
-
|
1755
|
-
<div class="method_details ">
|
1756
|
-
<p class="signature " id="template-instance_method">
|
1757
|
-
|
1758
|
-
- (<tt>Object</tt>) <strong>template</strong>(name, template = nil) <span class="extras">(protected)</span>
|
1759
|
-
|
1760
|
-
|
1761
|
-
|
1762
|
-
</p><table class="source_code">
|
1763
|
-
<tr>
|
1764
|
-
<td>
|
1765
|
-
<pre class="lines">
|
1766
|
-
|
1767
|
-
|
1768
|
-
165
|
1769
|
-
166
|
1770
|
-
167</pre>
|
1771
|
-
</td>
|
1772
|
-
<td>
|
1773
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 165</span>
|
1774
|
-
|
1775
|
-
<span class='kw'>def</span> <span class='id template'>template</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id template'>template</span><span class='op'>=</span><span class='kw'>nil</span>
|
1776
|
-
<span class='ivar'>@command</span><span class='period'>.</span><span class='id template'>template</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id template'>template</span>
|
1777
|
-
<span class='kw'>end</span></pre>
|
1778
|
-
</td>
|
1779
|
-
</tr>
|
1780
|
-
</table>
|
1781
|
-
</div>
|
1782
|
-
|
1783
|
-
<div class="method_details ">
|
1784
|
-
<p class="signature " id="template_paths-instance_method">
|
1785
|
-
|
1786
|
-
- (<tt>Object</tt>) <strong>template_paths</strong>
|
1787
|
-
|
1788
|
-
|
1789
|
-
|
1790
|
-
</p><div class="docstring">
|
1791
|
-
<div class="discussion">
|
1792
|
-
|
1793
|
-
<p>Returns a collection of templates that were provided on the command line,
|
1794
|
-
followed by templates that are created by a concrete generator, followed
|
1795
|
-
by the Sprout::Generator.search_paths + 'templates' folders.</p>
|
1796
|
-
|
1797
|
-
|
1798
|
-
</div>
|
1799
|
-
</div>
|
1800
|
-
<div class="tags">
|
1801
|
-
|
1802
|
-
</div><table class="source_code">
|
1803
|
-
<tr>
|
1804
|
-
<td>
|
1805
|
-
<pre class="lines">
|
1806
|
-
|
1807
|
-
|
1808
|
-
118
|
1809
|
-
119
|
1810
|
-
120</pre>
|
1811
|
-
</td>
|
1812
|
-
<td>
|
1813
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 118</span>
|
1814
|
-
|
1815
|
-
<span class='kw'>def</span> <span class='id template_paths'>template_paths</span>
|
1816
|
-
<span class='id create_template_paths'>create_template_paths</span>
|
1817
|
-
<span class='kw'>end</span></pre>
|
1818
|
-
</td>
|
1819
|
-
</tr>
|
1820
|
-
</table>
|
1821
|
-
</div>
|
1822
|
-
|
1823
|
-
<div class="method_details ">
|
1824
|
-
<p class="signature " id="unexecute-instance_method">
|
1825
|
-
|
1826
|
-
- (<tt>Object</tt>) <strong>unexecute</strong>
|
1827
|
-
|
1828
|
-
|
1829
|
-
|
1830
|
-
</p><div class="docstring">
|
1831
|
-
<div class="discussion">
|
1832
|
-
|
1833
|
-
<p>Rollback the generator</p>
|
1834
|
-
|
1835
|
-
|
1836
|
-
</div>
|
1837
|
-
</div>
|
1838
|
-
<div class="tags">
|
1839
|
-
|
1840
|
-
</div><table class="source_code">
|
1841
|
-
<tr>
|
1842
|
-
<td>
|
1843
|
-
<pre class="lines">
|
1844
|
-
|
1845
|
-
|
1846
|
-
92
|
1847
|
-
93
|
1848
|
-
94</pre>
|
1849
|
-
</td>
|
1850
|
-
<td>
|
1851
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 92</span>
|
1852
|
-
|
1853
|
-
<span class='kw'>def</span> <span class='id unexecute'>unexecute</span>
|
1854
|
-
<span class='id prepare_command'>prepare_command</span><span class='period'>.</span><span class='id unexecute'>unexecute</span>
|
1855
|
-
<span class='kw'>end</span></pre>
|
1856
|
-
</td>
|
1857
|
-
</tr>
|
1858
|
-
</table>
|
1859
|
-
</div>
|
1860
|
-
|
1861
|
-
<div class="method_details ">
|
1862
|
-
<p class="signature " id="validate-instance_method">
|
1863
|
-
|
1864
|
-
- (<tt>Object</tt>) <strong>validate</strong>
|
1865
|
-
|
1866
|
-
|
1867
|
-
|
1868
|
-
</p><table class="source_code">
|
1869
|
-
<tr>
|
1870
|
-
<td>
|
1871
|
-
<pre class="lines">
|
1872
|
-
|
1873
|
-
|
1874
|
-
85
|
1875
|
-
86
|
1876
|
-
87
|
1877
|
-
88</pre>
|
1878
|
-
</td>
|
1879
|
-
<td>
|
1880
|
-
<pre class="code"><span class="info file"># File 'lib/sprout/generator/base.rb', line 85</span>
|
1881
|
-
|
1882
|
-
<span class='kw'>def</span> <span class='id validate'>validate</span>
|
1883
|
-
<span class='kw'>return</span> <span class='kw'>true</span> <span class='kw'>if</span> <span class='id show_template_paths'>show_template_paths</span>
|
1884
|
-
<span class='kw'>super</span>
|
1885
|
-
<span class='kw'>end</span></pre>
|
1886
|
-
</td>
|
1887
|
-
</tr>
|
1888
|
-
</table>
|
1889
|
-
</div>
|
1890
|
-
|
1891
|
-
</div>
|
1892
|
-
|
1893
|
-
</div>
|
1894
|
-
|
1895
|
-
<div id="footer">
|
1896
|
-
Generated on Fri Apr 29 18:33:06 2011 by
|
1897
|
-
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
1898
|
-
0.6.3 (ruby-1.9.2).
|
1899
|
-
</div>
|
1900
|
-
|
1901
|
-
</body>
|
1902
|
-
</html>
|