rprompt 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.gitignore +0 -1
- data/doc/Rprompt.html +129 -0
- data/doc/Rprompt/GitBranch.html +335 -0
- data/doc/Rprompt/GitNumbers.html +335 -0
- data/doc/Rprompt/GitSha.html +335 -0
- data/doc/Rprompt/GitTrack.html +455 -0
- data/doc/Rprompt/PromptItem.html +516 -0
- data/doc/Rprompt/RvmGemset.html +353 -0
- data/doc/Rprompt/RvmRuby.html +345 -0
- data/doc/String.html +136 -0
- data/doc/_index.html +188 -0
- data/doc/class_list.html +54 -0
- data/doc/css/common.css +1 -0
- data/doc/css/full_list.css +57 -0
- data/doc/css/style.css +338 -0
- data/doc/file.README.html +168 -0
- data/doc/file_list.html +56 -0
- data/doc/frames.html +28 -0
- data/doc/index.html +168 -0
- data/doc/js/app.js +214 -0
- data/doc/js/full_list.js +178 -0
- data/doc/js/jquery.js +4 -0
- data/doc/method_list.html +155 -0
- data/doc/top-level-namespace.html +114 -0
- data/lib/rprompt/version.rb +1 -1
- metadata +24 -1
@@ -0,0 +1,516 @@
|
|
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 http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
|
+
<title>
|
7
|
+
Class: Rprompt::PromptItem
|
8
|
+
|
9
|
+
— Documentation by YARD 0.8.6.2
|
10
|
+
|
11
|
+
</title>
|
12
|
+
|
13
|
+
<link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
|
14
|
+
|
15
|
+
<link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
|
16
|
+
|
17
|
+
<script type="text/javascript" charset="utf-8">
|
18
|
+
hasFrames = window.top.frames.main ? true : false;
|
19
|
+
relpath = '../';
|
20
|
+
framesUrl = "../frames.html#!" + escape(window.location.href);
|
21
|
+
</script>
|
22
|
+
|
23
|
+
|
24
|
+
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
25
|
+
|
26
|
+
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
27
|
+
|
28
|
+
|
29
|
+
</head>
|
30
|
+
<body>
|
31
|
+
<div id="header">
|
32
|
+
<div id="menu">
|
33
|
+
|
34
|
+
<a href="../_index.html">Index (P)</a> »
|
35
|
+
<span class='title'><span class='object_link'><a href="../Rprompt.html" title="Rprompt (module)">Rprompt</a></span></span>
|
36
|
+
»
|
37
|
+
<span class="title">PromptItem</span>
|
38
|
+
|
39
|
+
|
40
|
+
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
41
|
+
</div>
|
42
|
+
|
43
|
+
<div id="search">
|
44
|
+
|
45
|
+
<a class="full_list_link" id="class_list_link"
|
46
|
+
href="../class_list.html">
|
47
|
+
Class List
|
48
|
+
</a>
|
49
|
+
|
50
|
+
<a class="full_list_link" id="method_list_link"
|
51
|
+
href="../method_list.html">
|
52
|
+
Method List
|
53
|
+
</a>
|
54
|
+
|
55
|
+
<a class="full_list_link" id="file_list_link"
|
56
|
+
href="../file_list.html">
|
57
|
+
File List
|
58
|
+
</a>
|
59
|
+
|
60
|
+
</div>
|
61
|
+
<div class="clear"></div>
|
62
|
+
</div>
|
63
|
+
|
64
|
+
<iframe id="search_frame"></iframe>
|
65
|
+
|
66
|
+
<div id="content"><h1>Class: Rprompt::PromptItem
|
67
|
+
|
68
|
+
|
69
|
+
|
70
|
+
</h1>
|
71
|
+
|
72
|
+
<dl class="box">
|
73
|
+
|
74
|
+
<dt class="r1">Inherits:</dt>
|
75
|
+
<dd class="r1">
|
76
|
+
<span class="inheritName">Object</span>
|
77
|
+
|
78
|
+
<ul class="fullTree">
|
79
|
+
<li>Object</li>
|
80
|
+
|
81
|
+
<li class="next">Rprompt::PromptItem</li>
|
82
|
+
|
83
|
+
</ul>
|
84
|
+
<a href="#" class="inheritanceTree">show all</a>
|
85
|
+
|
86
|
+
</dd>
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
|
96
|
+
<dt class="r2 last">Defined in:</dt>
|
97
|
+
<dd class="r2 last">lib/rprompt.rb</dd>
|
98
|
+
|
99
|
+
</dl>
|
100
|
+
<div class="clear"></div>
|
101
|
+
|
102
|
+
<div id="subclasses">
|
103
|
+
<h2>Direct Known Subclasses</h2>
|
104
|
+
<p class="children"><span class='object_link'><a href="GitBranch.html" title="Rprompt::GitBranch (class)">GitBranch</a></span>, <span class='object_link'><a href="GitNumbers.html" title="Rprompt::GitNumbers (class)">GitNumbers</a></span>, <span class='object_link'><a href="GitSha.html" title="Rprompt::GitSha (class)">GitSha</a></span>, <span class='object_link'><a href="GitTrack.html" title="Rprompt::GitTrack (class)">GitTrack</a></span>, <span class='object_link'><a href="RvmGemset.html" title="Rprompt::RvmGemset (class)">RvmGemset</a></span>, <span class='object_link'><a href="RvmRuby.html" title="Rprompt::RvmRuby (class)">RvmRuby</a></span></p>
|
105
|
+
</div>
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
|
110
|
+
<h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2>
|
111
|
+
<ul class="summary">
|
112
|
+
|
113
|
+
<li class="public ">
|
114
|
+
<span class="summary_signature">
|
115
|
+
|
116
|
+
<a href="#color-instance_method" title="#color (instance method)">- (String) <strong>color</strong> </a>
|
117
|
+
|
118
|
+
|
119
|
+
|
120
|
+
</span>
|
121
|
+
|
122
|
+
|
123
|
+
|
124
|
+
|
125
|
+
<span class="note title readonly">readonly</span>
|
126
|
+
|
127
|
+
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
<span class="summary_desc"><div class='inline'>
|
136
|
+
<p>Symbol character to identify prompt item.</p>
|
137
|
+
</div></span>
|
138
|
+
|
139
|
+
</li>
|
140
|
+
|
141
|
+
|
142
|
+
<li class="public ">
|
143
|
+
<span class="summary_signature">
|
144
|
+
|
145
|
+
<a href="#symbol-instance_method" title="#symbol (instance method)">- (String) <strong>symbol</strong> </a>
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
</span>
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
<span class="note title readonly">readonly</span>
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
|
164
|
+
<span class="summary_desc"><div class='inline'>
|
165
|
+
<p>Symbol character to identify prompt item.</p>
|
166
|
+
</div></span>
|
167
|
+
|
168
|
+
</li>
|
169
|
+
|
170
|
+
|
171
|
+
</ul>
|
172
|
+
|
173
|
+
|
174
|
+
|
175
|
+
|
176
|
+
|
177
|
+
<h2>
|
178
|
+
Instance Method Summary
|
179
|
+
<small>(<a href="#" class="summary_toggle">collapse</a>)</small>
|
180
|
+
</h2>
|
181
|
+
|
182
|
+
<ul class="summary">
|
183
|
+
|
184
|
+
<li class="public ">
|
185
|
+
<span class="summary_signature">
|
186
|
+
|
187
|
+
<a href="#commandResult-instance_method" title="#commandResult (instance method)">- (String) <strong>commandResult</strong> </a>
|
188
|
+
|
189
|
+
|
190
|
+
|
191
|
+
</span>
|
192
|
+
|
193
|
+
|
194
|
+
|
195
|
+
|
196
|
+
|
197
|
+
|
198
|
+
|
199
|
+
|
200
|
+
|
201
|
+
<span class="summary_desc"><div class='inline'>
|
202
|
+
<p>executes prompt item command.</p>
|
203
|
+
</div></span>
|
204
|
+
|
205
|
+
</li>
|
206
|
+
|
207
|
+
|
208
|
+
<li class="public ">
|
209
|
+
<span class="summary_signature">
|
210
|
+
|
211
|
+
<a href="#initialize-instance_method" title="#initialize (instance method)">- (PromptItem) <strong>initialize</strong>(config) </a>
|
212
|
+
|
213
|
+
|
214
|
+
|
215
|
+
</span>
|
216
|
+
|
217
|
+
|
218
|
+
<span class="note title constructor">constructor</span>
|
219
|
+
|
220
|
+
|
221
|
+
|
222
|
+
|
223
|
+
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
<span class="summary_desc"><div class='inline'>
|
228
|
+
<p>A new instance of PromptItem.</p>
|
229
|
+
</div></span>
|
230
|
+
|
231
|
+
</li>
|
232
|
+
|
233
|
+
|
234
|
+
</ul>
|
235
|
+
|
236
|
+
|
237
|
+
<div id="constructor_details" class="method_details_list">
|
238
|
+
<h2>Constructor Details</h2>
|
239
|
+
|
240
|
+
<div class="method_details first">
|
241
|
+
<h3 class="signature first" id="initialize-instance_method">
|
242
|
+
|
243
|
+
- (<tt><span class='object_link'><a href="" title="Rprompt::PromptItem (class)">PromptItem</a></span></tt>) <strong>initialize</strong>(config)
|
244
|
+
|
245
|
+
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
</h3><div class="docstring">
|
250
|
+
<div class="discussion">
|
251
|
+
|
252
|
+
<p>A new instance of PromptItem</p>
|
253
|
+
|
254
|
+
|
255
|
+
</div>
|
256
|
+
</div>
|
257
|
+
<div class="tags">
|
258
|
+
<p class="tag_title">Parameters:</p>
|
259
|
+
<ul class="param">
|
260
|
+
|
261
|
+
<li>
|
262
|
+
|
263
|
+
<span class='name'>config</span>
|
264
|
+
|
265
|
+
|
266
|
+
<span class='type'>(<tt>Hash</tt>)</span>
|
267
|
+
|
268
|
+
|
269
|
+
|
270
|
+
—
|
271
|
+
<div class='inline'>
|
272
|
+
<p>Prompt item configuration:</p>
|
273
|
+
<ul><li>
|
274
|
+
<p>:cmd => shell command</p>
|
275
|
+
</li><li>
|
276
|
+
<p>:symbol => character</p>
|
277
|
+
</li><li>
|
278
|
+
<p>:color => color name</p>
|
279
|
+
</li></ul>
|
280
|
+
</div>
|
281
|
+
|
282
|
+
</li>
|
283
|
+
|
284
|
+
</ul>
|
285
|
+
|
286
|
+
|
287
|
+
</div><table class="source_code">
|
288
|
+
<tr>
|
289
|
+
<td>
|
290
|
+
<pre class="lines">
|
291
|
+
|
292
|
+
|
293
|
+
19
|
294
|
+
20
|
295
|
+
21
|
296
|
+
22
|
297
|
+
23</pre>
|
298
|
+
</td>
|
299
|
+
<td>
|
300
|
+
<pre class="code"><span class="info file"># File 'lib/rprompt.rb', line 19</span>
|
301
|
+
|
302
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_config'>config</span><span class='rparen'>)</span>
|
303
|
+
<span class='ivar'>@cmd</span> <span class='op'>=</span> <span class='id identifier rubyid_config'>config</span><span class='lbracket'>[</span><span class='symbol'>:cmd</span><span class='rbracket'>]</span>
|
304
|
+
<span class='ivar'>@symbol</span> <span class='op'>=</span> <span class='id identifier rubyid_config'>config</span><span class='lbracket'>[</span><span class='symbol'>:symbol</span><span class='rbracket'>]</span>
|
305
|
+
<span class='ivar'>@color</span> <span class='op'>=</span> <span class='id identifier rubyid_config'>config</span><span class='lbracket'>[</span><span class='symbol'>:color</span><span class='rbracket'>]</span>
|
306
|
+
<span class='kw'>end</span></pre>
|
307
|
+
</td>
|
308
|
+
</tr>
|
309
|
+
</table>
|
310
|
+
</div>
|
311
|
+
|
312
|
+
</div>
|
313
|
+
|
314
|
+
<div id="instance_attr_details" class="attr_details">
|
315
|
+
<h2>Instance Attribute Details</h2>
|
316
|
+
|
317
|
+
|
318
|
+
<span id=""></span>
|
319
|
+
<div class="method_details first">
|
320
|
+
<h3 class="signature first" id="color-instance_method">
|
321
|
+
|
322
|
+
- (<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>) <strong>color</strong> <span class="extras">(readonly)</span>
|
323
|
+
|
324
|
+
|
325
|
+
|
326
|
+
|
327
|
+
|
328
|
+
</h3><div class="docstring">
|
329
|
+
<div class="discussion">
|
330
|
+
|
331
|
+
<p>Symbol character to identify prompt item</p>
|
332
|
+
|
333
|
+
|
334
|
+
</div>
|
335
|
+
</div>
|
336
|
+
<div class="tags">
|
337
|
+
|
338
|
+
<p class="tag_title">Returns:</p>
|
339
|
+
<ul class="return">
|
340
|
+
|
341
|
+
<li>
|
342
|
+
|
343
|
+
|
344
|
+
<span class='type'>(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
|
345
|
+
|
346
|
+
|
347
|
+
|
348
|
+
—
|
349
|
+
<div class='inline'>
|
350
|
+
<p>symbol character to identify prompt item</p>
|
351
|
+
</div>
|
352
|
+
|
353
|
+
</li>
|
354
|
+
|
355
|
+
</ul>
|
356
|
+
|
357
|
+
</div><table class="source_code">
|
358
|
+
<tr>
|
359
|
+
<td>
|
360
|
+
<pre class="lines">
|
361
|
+
|
362
|
+
|
363
|
+
13
|
364
|
+
14
|
365
|
+
15</pre>
|
366
|
+
</td>
|
367
|
+
<td>
|
368
|
+
<pre class="code"><span class="info file"># File 'lib/rprompt.rb', line 13</span>
|
369
|
+
|
370
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_color'>color</span>
|
371
|
+
<span class='ivar'>@color</span>
|
372
|
+
<span class='kw'>end</span></pre>
|
373
|
+
</td>
|
374
|
+
</tr>
|
375
|
+
</table>
|
376
|
+
</div>
|
377
|
+
|
378
|
+
|
379
|
+
<span id=""></span>
|
380
|
+
<div class="method_details ">
|
381
|
+
<h3 class="signature " id="symbol-instance_method">
|
382
|
+
|
383
|
+
- (<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>) <strong>symbol</strong> <span class="extras">(readonly)</span>
|
384
|
+
|
385
|
+
|
386
|
+
|
387
|
+
|
388
|
+
|
389
|
+
</h3><div class="docstring">
|
390
|
+
<div class="discussion">
|
391
|
+
|
392
|
+
<p>Symbol character to identify prompt item</p>
|
393
|
+
|
394
|
+
|
395
|
+
</div>
|
396
|
+
</div>
|
397
|
+
<div class="tags">
|
398
|
+
|
399
|
+
<p class="tag_title">Returns:</p>
|
400
|
+
<ul class="return">
|
401
|
+
|
402
|
+
<li>
|
403
|
+
|
404
|
+
|
405
|
+
<span class='type'>(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
|
406
|
+
|
407
|
+
|
408
|
+
|
409
|
+
—
|
410
|
+
<div class='inline'>
|
411
|
+
<p>symbol character to identify prompt item</p>
|
412
|
+
</div>
|
413
|
+
|
414
|
+
</li>
|
415
|
+
|
416
|
+
</ul>
|
417
|
+
|
418
|
+
</div><table class="source_code">
|
419
|
+
<tr>
|
420
|
+
<td>
|
421
|
+
<pre class="lines">
|
422
|
+
|
423
|
+
|
424
|
+
13
|
425
|
+
14
|
426
|
+
15</pre>
|
427
|
+
</td>
|
428
|
+
<td>
|
429
|
+
<pre class="code"><span class="info file"># File 'lib/rprompt.rb', line 13</span>
|
430
|
+
|
431
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_symbol'>symbol</span>
|
432
|
+
<span class='ivar'>@symbol</span>
|
433
|
+
<span class='kw'>end</span></pre>
|
434
|
+
</td>
|
435
|
+
</tr>
|
436
|
+
</table>
|
437
|
+
</div>
|
438
|
+
|
439
|
+
</div>
|
440
|
+
|
441
|
+
|
442
|
+
<div id="instance_method_details" class="method_details_list">
|
443
|
+
<h2>Instance Method Details</h2>
|
444
|
+
|
445
|
+
|
446
|
+
<div class="method_details first">
|
447
|
+
<h3 class="signature first" id="commandResult-instance_method">
|
448
|
+
|
449
|
+
- (<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>) <strong>commandResult</strong>
|
450
|
+
|
451
|
+
|
452
|
+
|
453
|
+
|
454
|
+
|
455
|
+
</h3><div class="docstring">
|
456
|
+
<div class="discussion">
|
457
|
+
|
458
|
+
<p>executes prompt item command</p>
|
459
|
+
|
460
|
+
|
461
|
+
</div>
|
462
|
+
</div>
|
463
|
+
<div class="tags">
|
464
|
+
|
465
|
+
<p class="tag_title">Returns:</p>
|
466
|
+
<ul class="return">
|
467
|
+
|
468
|
+
<li>
|
469
|
+
|
470
|
+
|
471
|
+
<span class='type'>(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
|
472
|
+
|
473
|
+
|
474
|
+
|
475
|
+
—
|
476
|
+
<div class='inline'>
|
477
|
+
<p>command result</p>
|
478
|
+
</div>
|
479
|
+
|
480
|
+
</li>
|
481
|
+
|
482
|
+
</ul>
|
483
|
+
|
484
|
+
</div><table class="source_code">
|
485
|
+
<tr>
|
486
|
+
<td>
|
487
|
+
<pre class="lines">
|
488
|
+
|
489
|
+
|
490
|
+
27
|
491
|
+
28
|
492
|
+
29</pre>
|
493
|
+
</td>
|
494
|
+
<td>
|
495
|
+
<pre class="code"><span class="info file"># File 'lib/rprompt.rb', line 27</span>
|
496
|
+
|
497
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_commandResult'>commandResult</span>
|
498
|
+
<span class='backtick'>%x(</span><span class='embexpr_beg'>#{</span><span class='ivar'>@cmd</span><span class='rbrace'>}</span><span class='tstring_content'> 2> /dev/null</span><span class='tstring_end'>)</span></span>
|
499
|
+
<span class='kw'>end</span></pre>
|
500
|
+
</td>
|
501
|
+
</tr>
|
502
|
+
</table>
|
503
|
+
</div>
|
504
|
+
|
505
|
+
</div>
|
506
|
+
|
507
|
+
</div>
|
508
|
+
|
509
|
+
<div id="footer">
|
510
|
+
Generated on Sat Jul 20 10:38:07 2013 by
|
511
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
512
|
+
0.8.6.2 (ruby-1.9.3).
|
513
|
+
</div>
|
514
|
+
|
515
|
+
</body>
|
516
|
+
</html>
|