doing 2.0.25 → 2.1.0pre

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. checksums.yaml +4 -4
  2. data/.yardoc/checksums +18 -15
  3. data/.yardoc/object_types +0 -0
  4. data/.yardoc/objects/root.dat +0 -0
  5. data/CHANGELOG.md +28 -0
  6. data/Gemfile.lock +8 -1
  7. data/README.md +1 -1
  8. data/Rakefile +23 -4
  9. data/bin/doing +205 -127
  10. data/doc/Array.html +354 -1
  11. data/doc/Doing/Color.html +104 -92
  12. data/doc/Doing/Completion.html +216 -0
  13. data/doc/Doing/Configuration.html +340 -5
  14. data/doc/Doing/Content.html +229 -0
  15. data/doc/Doing/Errors/DoingNoTraceError.html +1 -1
  16. data/doc/Doing/Errors/DoingRuntimeError.html +1 -1
  17. data/doc/Doing/Errors/DoingStandardError.html +1 -1
  18. data/doc/Doing/Errors/EmptyInput.html +1 -1
  19. data/doc/Doing/Errors/NoResults.html +1 -1
  20. data/doc/Doing/Errors/PluginException.html +1 -1
  21. data/doc/Doing/Errors/UserCancelled.html +1 -1
  22. data/doc/Doing/Errors/WrongCommand.html +1 -1
  23. data/doc/Doing/Errors.html +1 -1
  24. data/doc/Doing/Hooks.html +1 -1
  25. data/doc/Doing/Item.html +337 -49
  26. data/doc/Doing/Items.html +444 -35
  27. data/doc/Doing/LogAdapter.html +139 -51
  28. data/doc/Doing/Note.html +253 -22
  29. data/doc/Doing/Pager.html +74 -36
  30. data/doc/Doing/Plugins.html +1 -1
  31. data/doc/Doing/Prompt.html +674 -0
  32. data/doc/Doing/Section.html +354 -0
  33. data/doc/Doing/Util.html +57 -1
  34. data/doc/Doing/WWID.html +477 -670
  35. data/doc/Doing/WWIDFile.html +398 -0
  36. data/doc/Doing.html +5 -5
  37. data/doc/GLI/Commands/MarkdownDocumentListener.html +1 -1
  38. data/doc/GLI/Commands.html +1 -1
  39. data/doc/GLI.html +1 -1
  40. data/doc/Hash.html +97 -1
  41. data/doc/Status.html +37 -3
  42. data/doc/String.html +599 -23
  43. data/doc/Symbol.html +3 -3
  44. data/doc/Time.html +1 -1
  45. data/doc/_index.html +22 -1
  46. data/doc/class_list.html +1 -1
  47. data/doc/file.README.html +8 -2
  48. data/doc/index.html +8 -2
  49. data/doc/method_list.html +453 -173
  50. data/doc/top-level-namespace.html +1 -1
  51. data/doing.gemspec +3 -0
  52. data/doing.rdoc +40 -12
  53. data/example_plugin.rb +3 -3
  54. data/lib/completion/_doing.zsh +1 -1
  55. data/lib/completion/doing.bash +8 -8
  56. data/lib/completion/doing.fish +1 -1
  57. data/lib/doing/array.rb +36 -0
  58. data/lib/doing/colors.rb +70 -66
  59. data/lib/doing/completion.rb +6 -0
  60. data/lib/doing/configuration.rb +69 -28
  61. data/lib/doing/hash.rb +37 -0
  62. data/lib/doing/item.rb +77 -12
  63. data/lib/doing/items.rb +125 -0
  64. data/lib/doing/log_adapter.rb +55 -3
  65. data/lib/doing/note.rb +53 -1
  66. data/lib/doing/pager.rb +49 -38
  67. data/lib/doing/plugins/export/markdown_export.rb +4 -4
  68. data/lib/doing/plugins/export/template_export.rb +2 -2
  69. data/lib/doing/plugins/import/calendar_import.rb +4 -4
  70. data/lib/doing/plugins/import/doing_import.rb +5 -7
  71. data/lib/doing/plugins/import/timing_import.rb +3 -3
  72. data/lib/doing/prompt.rb +206 -0
  73. data/lib/doing/section.rb +30 -0
  74. data/lib/doing/string.rb +103 -27
  75. data/lib/doing/util.rb +14 -6
  76. data/lib/doing/version.rb +1 -1
  77. data/lib/doing/wwid.rb +306 -621
  78. data/lib/doing.rb +6 -2
  79. data/lib/examples/plugins/capture_thing_import.rb +162 -0
  80. metadata +73 -5
  81. data/lib/doing/wwidfile.rb +0 -117
@@ -0,0 +1,674 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>
7
+ Module: Doing::Prompt
8
+
9
+ &mdash; Documentation by YARD 0.9.26
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../css/style.css" type="text/css" />
14
+
15
+ <link rel="stylesheet" href="../css/common.css" type="text/css" />
16
+
17
+ <script type="text/javascript">
18
+ pathId = "Doing::Prompt";
19
+ relpath = '../';
20
+ </script>
21
+
22
+
23
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
24
+
25
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
26
+
27
+
28
+ </head>
29
+ <body>
30
+ <div class="nav_wrap">
31
+ <iframe id="nav" src="../class_list.html?1"></iframe>
32
+ <div id="resizer"></div>
33
+ </div>
34
+
35
+ <div id="main" tabindex="-1">
36
+ <div id="header">
37
+ <div id="menu">
38
+
39
+ <a href="../_index.html">Index (P)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../Doing.html" title="Doing (module)">Doing</a></span></span>
41
+ &raquo;
42
+ <span class="title">Prompt</span>
43
+
44
+ </div>
45
+
46
+ <div id="search">
47
+
48
+ <a class="full_list_link" id="class_list_link"
49
+ href="../class_list.html">
50
+
51
+ <svg width="24" height="24">
52
+ <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
+ <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
+ <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
+ </svg>
56
+ </a>
57
+
58
+ </div>
59
+ <div class="clear"></div>
60
+ </div>
61
+
62
+ <div id="content"><h1>Module: Doing::Prompt
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+
70
+
71
+
72
+ <dl>
73
+ <dt>Extended by:</dt>
74
+ <dd><span class='object_link'><a href="Color.html" title="Doing::Color (module)">Color</a></span></dd>
75
+ </dl>
76
+
77
+
78
+
79
+
80
+
81
+
82
+
83
+
84
+ <dl>
85
+ <dt>Defined in:</dt>
86
+ <dd>lib/doing/prompt.rb</dd>
87
+ </dl>
88
+
89
+ </div>
90
+
91
+ <h2>Overview</h2><div class="docstring">
92
+ <div class="discussion">
93
+ <p>Terminal Prompt methods</p>
94
+
95
+
96
+ </div>
97
+ </div>
98
+ <div class="tags">
99
+
100
+
101
+ </div>
102
+
103
+
104
+ <h2>Constant Summary</h2>
105
+
106
+ <h3 class="inherited">Constants included
107
+ from <span class='object_link'><a href="Color.html" title="Doing::Color (module)">Color</a></span></h3>
108
+ <p class="inherited"><span class='object_link'><a href="Color.html#ATTRIBUTES-constant" title="Doing::Color::ATTRIBUTES (constant)">Color::ATTRIBUTES</a></span>, <span class='object_link'><a href="Color.html#ATTRIBUTE_NAMES-constant" title="Doing::Color::ATTRIBUTE_NAMES (constant)">Color::ATTRIBUTE_NAMES</a></span>, <span class='object_link'><a href="Color.html#COLORED_REGEXP-constant" title="Doing::Color::COLORED_REGEXP (constant)">Color::COLORED_REGEXP</a></span></p>
109
+
110
+
111
+ <h2>Class Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
112
+ <ul class="summary">
113
+
114
+ <li class="public ">
115
+ <span class="summary_signature">
116
+
117
+ <a href="#default_answer-class_method" title="default_answer (class method)">.<strong>default_answer</strong> &#x21d2; Object </a>
118
+
119
+
120
+
121
+ </span>
122
+
123
+
124
+
125
+
126
+
127
+
128
+
129
+
130
+
131
+
132
+
133
+
134
+ <span class="summary_desc"><div class='inline'></div></span>
135
+
136
+ </li>
137
+
138
+
139
+ <li class="public ">
140
+ <span class="summary_signature">
141
+
142
+ <a href="#force_answer-class_method" title="force_answer (class method)">.<strong>force_answer</strong> &#x21d2; Object </a>
143
+
144
+
145
+
146
+ </span>
147
+
148
+
149
+
150
+
151
+
152
+
153
+
154
+
155
+
156
+
157
+
158
+
159
+ <span class="summary_desc"><div class='inline'></div></span>
160
+
161
+ </li>
162
+
163
+
164
+ </ul>
165
+
166
+
167
+
168
+
169
+
170
+ <h2>
171
+ Class Method Summary
172
+ <small><a href="#" class="summary_toggle">collapse</a></small>
173
+ </h2>
174
+
175
+ <ul class="summary">
176
+
177
+ <li class="public ">
178
+ <span class="summary_signature">
179
+
180
+ <a href="#choose_from-class_method" title="choose_from (class method)">.<strong>choose_from</strong>(options, prompt: &#39;Make a selection: &#39;, multiple: false, sorted: true, fzf_args: []) &#x21d2; String </a>
181
+
182
+
183
+
184
+ </span>
185
+
186
+
187
+
188
+
189
+
190
+
191
+
192
+
193
+
194
+ <span class="summary_desc"><div class='inline'><p>Generate a menu of options and allow user selection.</p>
195
+ </div></span>
196
+
197
+ </li>
198
+
199
+
200
+ <li class="public ">
201
+ <span class="summary_signature">
202
+
203
+ <a href="#choose_from_items-class_method" title="choose_from_items (class method)">.<strong>choose_from_items</strong>(items, **opt) &#x21d2; Object </a>
204
+
205
+
206
+
207
+ </span>
208
+
209
+
210
+
211
+
212
+
213
+
214
+
215
+
216
+
217
+ <span class="summary_desc"><div class='inline'><p>Create an interactive menu to select from a set of Items.</p>
218
+ </div></span>
219
+
220
+ </li>
221
+
222
+
223
+ <li class="public ">
224
+ <span class="summary_signature">
225
+
226
+ <a href="#fzf-class_method" title="fzf (class method)">.<strong>fzf</strong> &#x21d2; Object </a>
227
+
228
+
229
+
230
+ </span>
231
+
232
+
233
+
234
+
235
+
236
+
237
+
238
+
239
+
240
+ <span class="summary_desc"><div class='inline'></div></span>
241
+
242
+ </li>
243
+
244
+
245
+ <li class="public ">
246
+ <span class="summary_signature">
247
+
248
+ <a href="#install_fzf-class_method" title="install_fzf (class method)">.<strong>install_fzf</strong> &#x21d2; Object </a>
249
+
250
+
251
+
252
+ </span>
253
+
254
+
255
+
256
+
257
+
258
+
259
+
260
+
261
+
262
+ <span class="summary_desc"><div class='inline'></div></span>
263
+
264
+ </li>
265
+
266
+
267
+ <li class="public ">
268
+ <span class="summary_signature">
269
+
270
+ <a href="#yn-class_method" title="yn (class method)">.<strong>yn</strong>(question, default_response: false) &#x21d2; Bool </a>
271
+
272
+
273
+
274
+ </span>
275
+
276
+
277
+
278
+
279
+
280
+
281
+
282
+
283
+
284
+ <span class="summary_desc"><div class='inline'><p>Ask a yes or no question in the terminal.</p>
285
+ </div></span>
286
+
287
+ </li>
288
+
289
+
290
+ </ul>
291
+
292
+
293
+
294
+
295
+
296
+
297
+
298
+
299
+
300
+
301
+
302
+ <h3 class="inherited">Methods included from <span class='object_link'><a href="Color.html" title="Doing::Color (module)">Color</a></span></h3>
303
+ <p class="inherited"><span class='object_link'><a href="Color.html#attributes-class_method" title="Doing::Color.attributes (method)">attributes</a></span>, <span class='object_link'><a href="Color.html#coloring%3F-class_method" title="Doing::Color.coloring? (method)">coloring?</a></span>, <span class='object_link'><a href="Color.html#support%3F-instance_method" title="Doing::Color#support? (method)">support?</a></span>, <span class='object_link'><a href="Color.html#uncolor-instance_method" title="Doing::Color#uncolor (method)">uncolor</a></span></p>
304
+
305
+ <div id="class_attr_details" class="attr_details">
306
+ <h2>Class Attribute Details</h2>
307
+
308
+
309
+ <span id="default_answer=-class_method"></span>
310
+ <div class="method_details first">
311
+ <h3 class="signature first" id="default_answer-class_method">
312
+
313
+ .<strong>default_answer</strong> &#x21d2; <tt>Object</tt>
314
+
315
+
316
+
317
+
318
+
319
+ </h3>
320
+ </div>
321
+
322
+
323
+ <span id="force_answer=-class_method"></span>
324
+ <div class="method_details ">
325
+ <h3 class="signature " id="force_answer-class_method">
326
+
327
+ .<strong>force_answer</strong> &#x21d2; <tt>Object</tt>
328
+
329
+
330
+
331
+
332
+
333
+ </h3>
334
+ </div>
335
+
336
+ </div>
337
+
338
+
339
+ <div id="class_method_details" class="method_details_list">
340
+ <h2>Class Method Details</h2>
341
+
342
+
343
+ <div class="method_details first">
344
+ <h3 class="signature first" id="choose_from-class_method">
345
+
346
+ .<strong>choose_from</strong>(options, prompt: &#39;Make a selection: &#39;, multiple: false, sorted: true, fzf_args: []) &#x21d2; <tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>
347
+
348
+
349
+
350
+
351
+
352
+ </h3><div class="docstring">
353
+ <div class="discussion">
354
+ <p>Generate a menu of options and allow user selection</p>
355
+
356
+
357
+ </div>
358
+ </div>
359
+ <div class="tags">
360
+
361
+ <p class="tag_title">Returns:</p>
362
+ <ul class="return">
363
+
364
+ <li>
365
+
366
+
367
+ <span class='type'>(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
368
+
369
+
370
+
371
+ &mdash;
372
+ <div class='inline'><p>The selected option</p>
373
+ </div>
374
+
375
+ </li>
376
+
377
+ </ul>
378
+
379
+ </div>
380
+ </div>
381
+
382
+ <div class="method_details ">
383
+ <h3 class="signature " id="choose_from_items-class_method">
384
+
385
+ .<strong>choose_from_items</strong>(items, **opt) &#x21d2; <tt>Object</tt>
386
+
387
+
388
+
389
+
390
+
391
+ </h3><div class="docstring">
392
+ <div class="discussion">
393
+ <p>Create an interactive menu to select from a set of Items</p>
394
+
395
+
396
+ </div>
397
+ </div>
398
+ <div class="tags">
399
+ <p class="tag_title">Parameters:</p>
400
+ <ul class="param">
401
+
402
+ <li>
403
+
404
+ <span class='name'>items</span>
405
+
406
+
407
+ <span class='type'>(<tt><span class='object_link'><a href="../Array.html" title="Array (class)">Array</a></span></tt>)</span>
408
+
409
+
410
+
411
+ &mdash;
412
+ <div class='inline'><p>list of items</p>
413
+ </div>
414
+
415
+ </li>
416
+
417
+ <li>
418
+
419
+ <span class='name'>opt</span>
420
+
421
+
422
+ <span class='type'>(<tt><span class='object_link'><a href="../Hash.html" title="Hash (class)">Hash</a></span></tt>)</span>
423
+
424
+
425
+
426
+ &mdash;
427
+ <div class='inline'><p>options</p>
428
+ </div>
429
+
430
+ </li>
431
+
432
+ <li>
433
+
434
+ <span class='name'>include_section</span>
435
+
436
+
437
+ <span class='type'>(<tt>Boolean</tt>)</span>
438
+
439
+
440
+
441
+ &mdash;
442
+ <div class='inline'><p>include section</p>
443
+ </div>
444
+
445
+ </li>
446
+
447
+ </ul>
448
+
449
+
450
+
451
+
452
+
453
+
454
+ <p class="tag_title">Options Hash (<tt>**opt</tt>):</p>
455
+ <ul class="option">
456
+
457
+ <li>
458
+ <span class="name">:header</span>
459
+ <span class="type">(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
460
+ <span class="default">
461
+
462
+ </span>
463
+
464
+ </li>
465
+
466
+ <li>
467
+ <span class="name">:prompt</span>
468
+ <span class="type">(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
469
+ <span class="default">
470
+
471
+ </span>
472
+
473
+ </li>
474
+
475
+ <li>
476
+ <span class="name">:query</span>
477
+ <span class="type">(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
478
+ <span class="default">
479
+
480
+ </span>
481
+
482
+ </li>
483
+
484
+ <li>
485
+ <span class="name">:show_if_single</span>
486
+ <span class="type">(<tt>Boolean</tt>)</span>
487
+ <span class="default">
488
+
489
+ </span>
490
+
491
+ </li>
492
+
493
+ <li>
494
+ <span class="name">:menu</span>
495
+ <span class="type">(<tt>Boolean</tt>)</span>
496
+ <span class="default">
497
+
498
+ </span>
499
+
500
+ </li>
501
+
502
+ <li>
503
+ <span class="name">:sort</span>
504
+ <span class="type">(<tt>Boolean</tt>)</span>
505
+ <span class="default">
506
+
507
+ </span>
508
+
509
+ </li>
510
+
511
+ <li>
512
+ <span class="name">:multiple</span>
513
+ <span class="type">(<tt>Boolean</tt>)</span>
514
+ <span class="default">
515
+
516
+ </span>
517
+
518
+ </li>
519
+
520
+ <li>
521
+ <span class="name">:case</span>
522
+ <span class="type">(<tt><span class='object_link'><a href="../Symbol.html" title="Symbol (class)">Symbol</a></span></tt>)</span>
523
+ <span class="default">
524
+
525
+ &mdash; default:
526
+ <tt>:sensitive</tt>, <tt>:ignore</tt>, <tt>:smart</tt>
527
+
528
+ </span>
529
+
530
+ </li>
531
+
532
+ </ul>
533
+
534
+
535
+
536
+ </div>
537
+ </div>
538
+
539
+ <div class="method_details ">
540
+ <h3 class="signature " id="fzf-class_method">
541
+
542
+ .<strong>fzf</strong> &#x21d2; <tt>Object</tt>
543
+
544
+
545
+
546
+
547
+
548
+ </h3>
549
+ </div>
550
+
551
+ <div class="method_details ">
552
+ <h3 class="signature " id="install_fzf-class_method">
553
+
554
+ .<strong>install_fzf</strong> &#x21d2; <tt>Object</tt>
555
+
556
+
557
+
558
+
559
+
560
+ </h3><div class="docstring">
561
+ <div class="discussion">
562
+
563
+
564
+ </div>
565
+ </div>
566
+ <div class="tags">
567
+
568
+ <p class="tag_title">Raises:</p>
569
+ <ul class="raise">
570
+
571
+ <li>
572
+
573
+
574
+ <span class='type'>(<tt>RuntimeError</tt>)</span>
575
+
576
+
577
+
578
+ </li>
579
+
580
+ </ul>
581
+
582
+ </div>
583
+ </div>
584
+
585
+ <div class="method_details ">
586
+ <h3 class="signature " id="yn-class_method">
587
+
588
+ .<strong>yn</strong>(question, default_response: false) &#x21d2; <tt>Bool</tt>
589
+
590
+
591
+
592
+
593
+
594
+ </h3><div class="docstring">
595
+ <div class="discussion">
596
+ <p>Ask a yes or no question in the terminal</p>
597
+
598
+
599
+ </div>
600
+ </div>
601
+ <div class="tags">
602
+ <p class="tag_title">Parameters:</p>
603
+ <ul class="param">
604
+
605
+ <li>
606
+
607
+ <span class='name'>question</span>
608
+
609
+
610
+ <span class='type'>(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
611
+
612
+
613
+
614
+ &mdash;
615
+ <div class='inline'><p>The question
616
+ to ask</p>
617
+ </div>
618
+
619
+ </li>
620
+
621
+ <li>
622
+
623
+ <span class='name'>default_response</span>
624
+
625
+
626
+ <span class='type'>(<tt>Bool</tt>)</span>
627
+
628
+
629
+ <em class="default">(defaults to: <tt>false</tt>)</em>
630
+
631
+
632
+ &mdash;
633
+ <div class='inline'><p>default
634
+ response if no input</p>
635
+ </div>
636
+
637
+ </li>
638
+
639
+ </ul>
640
+
641
+ <p class="tag_title">Returns:</p>
642
+ <ul class="return">
643
+
644
+ <li>
645
+
646
+
647
+ <span class='type'>(<tt>Bool</tt>)</span>
648
+
649
+
650
+
651
+ &mdash;
652
+ <div class='inline'><p>yes or no</p>
653
+ </div>
654
+
655
+ </li>
656
+
657
+ </ul>
658
+
659
+ </div>
660
+ </div>
661
+
662
+ </div>
663
+
664
+ </div>
665
+
666
+ <div id="footer">
667
+ Generated on Sat Nov 27 10:06:03 2021 by
668
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
669
+ 0.9.26 (ruby-3.0.1).
670
+ </div>
671
+
672
+ </div>
673
+ </body>
674
+ </html>