doing 2.0.23 → 2.1.1pre

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.
Files changed (89) hide show
  1. checksums.yaml +4 -4
  2. data/.yardoc/checksums +19 -15
  3. data/.yardoc/object_types +0 -0
  4. data/.yardoc/objects/root.dat +0 -0
  5. data/CHANGELOG.md +40 -1
  6. data/Gemfile.lock +8 -1
  7. data/README.md +7 -1
  8. data/Rakefile +23 -4
  9. data/bin/doing +431 -256
  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 +517 -890
  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 +833 -53
  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 +460 -180
  50. data/doc/top-level-namespace.html +1 -1
  51. data/doing.gemspec +3 -0
  52. data/doing.rdoc +163 -44
  53. data/example_plugin.rb +5 -5
  54. data/lib/completion/_doing.zsh +42 -42
  55. data/lib/completion/doing.bash +21 -21
  56. data/lib/completion/doing.fish +1 -280
  57. data/lib/doing/array.rb +36 -0
  58. data/lib/doing/colors.rb +70 -66
  59. data/lib/doing/completion/bash_completion.rb +1 -2
  60. data/lib/doing/completion/fish_completion.rb +1 -1
  61. data/lib/doing/completion/zsh_completion.rb +1 -1
  62. data/lib/doing/completion.rb +6 -0
  63. data/lib/doing/configuration.rb +134 -23
  64. data/lib/doing/hash.rb +37 -0
  65. data/lib/doing/item.rb +77 -12
  66. data/lib/doing/items.rb +125 -0
  67. data/lib/doing/log_adapter.rb +58 -4
  68. data/lib/doing/note.rb +53 -1
  69. data/lib/doing/pager.rb +49 -38
  70. data/lib/doing/plugins/export/markdown_export.rb +4 -4
  71. data/lib/doing/plugins/export/template_export.rb +2 -2
  72. data/lib/doing/plugins/import/calendar_import.rb +4 -4
  73. data/lib/doing/plugins/import/doing_import.rb +5 -7
  74. data/lib/doing/plugins/import/timing_import.rb +3 -3
  75. data/lib/doing/prompt.rb +206 -0
  76. data/lib/doing/section.rb +30 -0
  77. data/lib/doing/string.rb +123 -35
  78. data/lib/doing/string_chronify.rb +81 -0
  79. data/lib/doing/util.rb +14 -6
  80. data/lib/doing/version.rb +1 -1
  81. data/lib/doing/wwid.rb +387 -685
  82. data/lib/doing.rb +7 -2
  83. data/lib/examples/plugins/capture_thing_import.rb +162 -0
  84. data/rdoc_to_mmd.rb +14 -8
  85. data/scripts/generate_bash_completions.rb +1 -1
  86. data/scripts/generate_fish_completions.rb +1 -1
  87. data/scripts/generate_zsh_completions.rb +1 -1
  88. metadata +74 -5
  89. data/lib/doing/wwidfile.rb +0 -117
data/doc/String.html CHANGED
@@ -99,14 +99,16 @@
99
99
 
100
100
  <dl>
101
101
  <dt>Defined in:</dt>
102
- <dd>lib/doing/string.rb</dd>
102
+ <dd>lib/doing/string.rb<span class="defines">,<br />
103
+ lib/doing/string_chronify.rb</span>
104
+ </dd>
103
105
  </dl>
104
106
 
105
107
  </div>
106
108
 
107
109
  <h2>Overview</h2><div class="docstring">
108
110
  <div class="discussion">
109
- <p>String helpers</p>
111
+ <p>Chronify methods for strings</p>
110
112
 
111
113
 
112
114
  </div>
@@ -199,6 +201,120 @@
199
201
  <span class="summary_desc"><div class='inline'><p>Capitalize on the first character on string.</p>
200
202
  </div></span>
201
203
 
204
+ </li>
205
+
206
+
207
+ <li class="public ">
208
+ <span class="summary_signature">
209
+
210
+ <a href="#chronify-instance_method" title="#chronify (instance method)">#<strong>chronify</strong>(**options) &#x21d2; DateTime </a>
211
+
212
+
213
+
214
+ </span>
215
+
216
+
217
+
218
+
219
+
220
+
221
+
222
+
223
+
224
+ <span class="summary_desc"><div class='inline'><p>Converts input string into a Time object when input takes on the following formats: - interval format e.g.</p>
225
+ </div></span>
226
+
227
+ </li>
228
+
229
+
230
+ <li class="public ">
231
+ <span class="summary_signature">
232
+
233
+ <a href="#chronify_qty-instance_method" title="#chronify_qty (instance method)">#<strong>chronify_qty</strong> &#x21d2; Integer </a>
234
+
235
+
236
+
237
+ </span>
238
+
239
+
240
+
241
+
242
+
243
+
244
+
245
+
246
+
247
+ <span class="summary_desc"><div class='inline'><p>Converts simple strings into seconds that can be added to a Time object.</p>
248
+ </div></span>
249
+
250
+ </li>
251
+
252
+
253
+ <li class="public ">
254
+ <span class="summary_signature">
255
+
256
+ <a href="#clean_unlinked_urls-instance_method" title="#clean_unlinked_urls (instance method)">#<strong>clean_unlinked_urls</strong> &#x21d2; Object </a>
257
+
258
+
259
+
260
+ </span>
261
+
262
+
263
+
264
+
265
+
266
+
267
+
268
+
269
+
270
+ <span class="summary_desc"><div class='inline'><p>Clean up unlinked <urls>.</p>
271
+ </div></span>
272
+
273
+ </li>
274
+
275
+
276
+ <li class="public ">
277
+ <span class="summary_signature">
278
+
279
+ <a href="#compress-instance_method" title="#compress (instance method)">#<strong>compress</strong> &#x21d2; Object </a>
280
+
281
+
282
+
283
+ </span>
284
+
285
+
286
+
287
+
288
+
289
+
290
+
291
+
292
+
293
+ <span class="summary_desc"><div class='inline'><p>Compress multiple spaces to single space.</p>
294
+ </div></span>
295
+
296
+ </li>
297
+
298
+
299
+ <li class="public ">
300
+ <span class="summary_signature">
301
+
302
+ <a href="#compress!-instance_method" title="#compress! (instance method)">#<strong>compress!</strong> &#x21d2; Object </a>
303
+
304
+
305
+
306
+ </span>
307
+
308
+
309
+
310
+
311
+
312
+
313
+
314
+
315
+
316
+ <span class="summary_desc"><div class='inline'></div></span>
317
+
202
318
  </li>
203
319
 
204
320
 
@@ -318,7 +434,53 @@
318
434
  <li class="public ">
319
435
  <span class="summary_signature">
320
436
 
321
- <a href="#link_urls-instance_method" title="#link_urls (instance method)">#<strong>link_urls</strong>(opt = {}) &#x21d2; Object </a>
437
+ <a href="#is_rx%3F-instance_method" title="#is_rx? (instance method)">#<strong>is_rx?</strong> &#x21d2; Boolean </a>
438
+
439
+
440
+
441
+ </span>
442
+
443
+
444
+
445
+
446
+
447
+
448
+
449
+
450
+
451
+ <span class="summary_desc"><div class='inline'><p>Determines if receiver is surrounded by slashes or starts with single quote.</p>
452
+ </div></span>
453
+
454
+ </li>
455
+
456
+
457
+ <li class="public ">
458
+ <span class="summary_signature">
459
+
460
+ <a href="#last_color-instance_method" title="#last_color (instance method)">#<strong>last_color</strong> &#x21d2; String </a>
461
+
462
+
463
+
464
+ </span>
465
+
466
+
467
+
468
+
469
+
470
+
471
+
472
+
473
+
474
+ <span class="summary_desc"><div class='inline'><p>Returns the last escape sequence from a string.</p>
475
+ </div></span>
476
+
477
+ </li>
478
+
479
+
480
+ <li class="public ">
481
+ <span class="summary_signature">
482
+
483
+ <a href="#link_urls-instance_method" title="#link_urls (instance method)">#<strong>link_urls</strong>(**opt) &#x21d2; Object </a>
322
484
 
323
485
 
324
486
 
@@ -340,7 +502,7 @@
340
502
  <li class="public ">
341
503
  <span class="summary_signature">
342
504
 
343
- <a href="#link_urls!-instance_method" title="#link_urls! (instance method)">#<strong>link_urls!</strong>(opt = {}) &#x21d2; Object </a>
505
+ <a href="#link_urls!-instance_method" title="#link_urls! (instance method)">#<strong>link_urls!</strong>(**opt) &#x21d2; Object </a>
344
506
 
345
507
 
346
508
 
@@ -542,7 +704,7 @@
542
704
  <li class="public ">
543
705
  <span class="summary_signature">
544
706
 
545
- <a href="#tag-instance_method" title="#tag (instance method)">#<strong>tag</strong>(tag, value: nil, remove: false, rename_to: nil, regex: false, single: false) &#x21d2; Object </a>
707
+ <a href="#remove_self_links-instance_method" title="#remove_self_links (instance method)">#<strong>remove_self_links</strong> &#x21d2; Object </a>
546
708
 
547
709
 
548
710
 
@@ -556,7 +718,31 @@
556
718
 
557
719
 
558
720
 
559
- <span class="summary_desc"><div class='inline'></div></span>
721
+ <span class="summary_desc"><div class='inline'><p>Remove <self-linked> formatting.</p>
722
+ </div></span>
723
+
724
+ </li>
725
+
726
+
727
+ <li class="public ">
728
+ <span class="summary_signature">
729
+
730
+ <a href="#replace_qualified_urls-instance_method" title="#replace_qualified_urls (instance method)">#<strong>replace_qualified_urls</strong>(**options) &#x21d2; Object </a>
731
+
732
+
733
+
734
+ </span>
735
+
736
+
737
+
738
+
739
+
740
+
741
+
742
+
743
+
744
+ <span class="summary_desc"><div class='inline'><p>Replace qualified urls.</p>
745
+ </div></span>
560
746
 
561
747
  </li>
562
748
 
@@ -564,7 +750,7 @@
564
750
  <li class="public ">
565
751
  <span class="summary_signature">
566
752
 
567
- <a href="#tag!-instance_method" title="#tag! (instance method)">#<strong>tag!</strong>(tag, value: nil, remove: false, rename_to: nil, regex: false, single: false) &#x21d2; Object </a>
753
+ <a href="#set_type-instance_method" title="#set_type (instance method)">#<strong>set_type</strong>(kind = nil) &#x21d2; Object </a>
568
754
 
569
755
 
570
756
 
@@ -586,7 +772,53 @@
586
772
  <li class="public ">
587
773
  <span class="summary_signature">
588
774
 
589
- <a href="#to_rx-instance_method" title="#to_rx (instance method)">#<strong>to_rx</strong>(distance) &#x21d2; String </a>
775
+ <a href="#tag-instance_method" title="#tag (instance method)">#<strong>tag</strong>(tag, value: nil, remove: false, rename_to: nil, regex: false, single: false, force: false) &#x21d2; String </a>
776
+
777
+
778
+
779
+ </span>
780
+
781
+
782
+
783
+
784
+
785
+
786
+
787
+
788
+
789
+ <span class="summary_desc"><div class='inline'><p>Add, rename, or remove a tag.</p>
790
+ </div></span>
791
+
792
+ </li>
793
+
794
+
795
+ <li class="public ">
796
+ <span class="summary_signature">
797
+
798
+ <a href="#tag!-instance_method" title="#tag! (instance method)">#<strong>tag!</strong>(tag, **options) &#x21d2; Object </a>
799
+
800
+
801
+
802
+ </span>
803
+
804
+
805
+
806
+
807
+
808
+
809
+
810
+
811
+
812
+ <span class="summary_desc"><div class='inline'><p>Add, rename, or remove a tag in place.</p>
813
+ </div></span>
814
+
815
+ </li>
816
+
817
+
818
+ <li class="public ">
819
+ <span class="summary_signature">
820
+
821
+ <a href="#to_rx-instance_method" title="#to_rx (instance method)">#<strong>to_rx</strong>(distance: 3, case_type: :smart) &#x21d2; Regexp </a>
590
822
 
591
823
 
592
824
 
@@ -789,7 +1021,7 @@
789
1021
  <li class="public ">
790
1022
  <span class="summary_signature">
791
1023
 
792
- <a href="#wrap-instance_method" title="#wrap (instance method)">#<strong>wrap</strong>(len, pad: 0, indent: &#39; &#39;, offset: 0, prefix: &#39;&#39;, after: &#39;&#39;, reset: &#39;&#39;) &#x21d2; Object </a>
1024
+ <a href="#wrap-instance_method" title="#wrap (instance method)">#<strong>wrap</strong>(len, pad: 0, indent: &#39; &#39;, offset: 0, prefix: &#39;&#39;, color: &#39;&#39;, after: &#39;&#39;, reset: &#39;&#39;) &#x21d2; Object </a>
793
1025
 
794
1026
 
795
1027
 
@@ -822,7 +1054,7 @@
822
1054
 
823
1055
 
824
1056
  <h3 class="inherited">Methods included from <span class='object_link'><a href="Doing/Color.html" title="Doing::Color (module)">Doing::Color</a></span></h3>
825
- <p class="inherited"><span class='object_link'><a href="Doing/Color.html#attributes-class_method" title="Doing::Color.attributes (method)">attributes</a></span>, <span class='object_link'><a href="Doing/Color.html#coloring=-class_method" title="Doing::Color.coloring= (method)">coloring=</a></span>, <span class='object_link'><a href="Doing/Color.html#coloring%3F-class_method" title="Doing::Color.coloring? (method)">coloring?</a></span>, <span class='object_link'><a href="Doing/Color.html#support%3F-instance_method" title="Doing::Color#support? (method)">#support?</a></span></p>
1057
+ <p class="inherited"><span class='object_link'><a href="Doing/Color.html#attributes-class_method" title="Doing::Color.attributes (method)">attributes</a></span>, <span class='object_link'><a href="Doing/Color.html#coloring%3F-class_method" title="Doing::Color.coloring? (method)">coloring?</a></span>, <span class='object_link'><a href="Doing/Color.html#support%3F-instance_method" title="Doing::Color#support? (method)">#support?</a></span></p>
826
1058
 
827
1059
 
828
1060
  <div id="instance_method_details" class="method_details_list">
@@ -893,21 +1125,9 @@
893
1125
  </div>
894
1126
 
895
1127
  <div class="method_details ">
896
- <h3 class="signature " id="dedup_tags-instance_method">
897
-
898
- #<strong>dedup_tags</strong> &#x21d2; <tt>Object</tt>
899
-
900
-
901
-
902
-
903
-
904
- </h3>
905
- </div>
906
-
907
- <div class="method_details ">
908
- <h3 class="signature " id="dedup_tags!-instance_method">
1128
+ <h3 class="signature " id="chronify-instance_method">
909
1129
 
910
- #<strong>dedup_tags!</strong> &#x21d2; <tt>Object</tt>
1130
+ #<strong>chronify</strong>(**options) &#x21d2; <tt>DateTime</tt>
911
1131
 
912
1132
 
913
1133
 
@@ -915,44 +1135,268 @@
915
1135
 
916
1136
  </h3><div class="docstring">
917
1137
  <div class="discussion">
918
- <p>Remove duplicate tags, leaving only first occurrence</p>
1138
+ <p>Converts input string into a Time object when input
1139
+ takes on the following formats:
1140
+ - interval format e.g. &#39;1d2h30m&#39;, &#39;45m&#39;
1141
+ etc.
1142
+ - a semantic phrase e.g. &#39;yesterday
1143
+ 5:30pm&#39;
1144
+ - a strftime e.g. &#39;2016-03-15 15:32:04
1145
+ PDT&#39;</p>
919
1146
 
920
1147
 
921
1148
  </div>
922
1149
  </div>
923
1150
  <div class="tags">
924
-
925
- <p class="tag_title">Returns:</p>
926
- <ul class="return">
1151
+ <p class="tag_title">Parameters:</p>
1152
+ <ul class="param">
927
1153
 
928
1154
  <li>
929
1155
 
1156
+ <span class='name'>options</span>
1157
+
930
1158
 
931
1159
  <span class='type'></span>
932
1160
 
933
1161
 
934
1162
 
935
-
936
- <div class='inline'><p>Deduplicated string</p>
1163
+ &mdash;
1164
+ <div class='inline'><p>Additional options</p>
937
1165
  </div>
938
1166
 
939
1167
  </li>
940
1168
 
941
1169
  </ul>
942
1170
 
1171
+
1172
+
1173
+
1174
+ <p class="tag_title">Options Hash (<tt>**options</tt>):</p>
1175
+ <ul class="option">
1176
+
1177
+ <li>
1178
+ <span class="name">:future</span>
1179
+ <span class="type">(<tt>Boolean</tt>)</span>
1180
+ <span class="default">
1181
+
1182
+ </span>
1183
+
1184
+ &mdash; <div class='inline'><p>assume future date
1185
+ (default: false)</p>
943
1186
  </div>
1187
+
1188
+ </li>
1189
+
1190
+ <li>
1191
+ <span class="name">:guess</span>
1192
+ <span class="type">(<tt><span class='object_link'><a href="Symbol.html" title="Symbol (class)">Symbol</a></span></tt>)</span>
1193
+ <span class="default">
1194
+
1195
+ </span>
1196
+
1197
+ &mdash; <div class='inline'><p>:begin or :end to
1198
+ assume beginning or end of
1199
+ arbitrary time range</p>
944
1200
  </div>
945
-
946
- <div class="method_details ">
947
- <h3 class="signature " id="highlight_tags-instance_method">
948
-
949
- #<strong>highlight_tags</strong>(color = &#39;yellow&#39;) &#x21d2; <tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>
950
-
951
-
1201
+
1202
+ </li>
1203
+
1204
+ </ul>
952
1205
 
953
1206
 
1207
+ <p class="tag_title">Returns:</p>
1208
+ <ul class="return">
954
1209
 
955
- </h3><div class="docstring">
1210
+ <li>
1211
+
1212
+
1213
+ <span class='type'>(<tt>DateTime</tt>)</span>
1214
+
1215
+
1216
+
1217
+ &mdash;
1218
+ <div class='inline'><p>result</p>
1219
+ </div>
1220
+
1221
+ </li>
1222
+
1223
+ </ul>
1224
+ <p class="tag_title">Raises:</p>
1225
+ <ul class="raise">
1226
+
1227
+ <li>
1228
+
1229
+
1230
+ <span class='type'>(<tt>InvalidTimeExpression</tt>)</span>
1231
+
1232
+
1233
+
1234
+ </li>
1235
+
1236
+ </ul>
1237
+
1238
+ </div>
1239
+ </div>
1240
+
1241
+ <div class="method_details ">
1242
+ <h3 class="signature " id="chronify_qty-instance_method">
1243
+
1244
+ #<strong>chronify_qty</strong> &#x21d2; <tt>Integer</tt>
1245
+
1246
+
1247
+
1248
+
1249
+
1250
+ </h3><div class="docstring">
1251
+ <div class="discussion">
1252
+ <p>Converts simple strings into seconds that can be
1253
+ added to a Time object</p>
1254
+
1255
+ <p>Input string can be HH:MM or XX[dhm]<a href="1d2h30m,%2045m,%201.5d,%201h20m,%20etc.">[XXhm][XXm]</a></p>
1256
+
1257
+
1258
+ </div>
1259
+ </div>
1260
+ <div class="tags">
1261
+
1262
+ <p class="tag_title">Returns:</p>
1263
+ <ul class="return">
1264
+
1265
+ <li>
1266
+
1267
+
1268
+ <span class='type'>(<tt>Integer</tt>)</span>
1269
+
1270
+
1271
+
1272
+ &mdash;
1273
+ <div class='inline'><p>seconds</p>
1274
+ </div>
1275
+
1276
+ </li>
1277
+
1278
+ </ul>
1279
+
1280
+ </div>
1281
+ </div>
1282
+
1283
+ <div class="method_details ">
1284
+ <h3 class="signature " id="clean_unlinked_urls-instance_method">
1285
+
1286
+ #<strong>clean_unlinked_urls</strong> &#x21d2; <tt>Object</tt>
1287
+
1288
+
1289
+
1290
+
1291
+
1292
+ </h3><div class="docstring">
1293
+ <div class="discussion">
1294
+ <p>Clean up unlinked <urls></p>
1295
+
1296
+
1297
+ </div>
1298
+ </div>
1299
+ <div class="tags">
1300
+
1301
+
1302
+ </div>
1303
+ </div>
1304
+
1305
+ <div class="method_details ">
1306
+ <h3 class="signature " id="compress-instance_method">
1307
+
1308
+ #<strong>compress</strong> &#x21d2; <tt>Object</tt>
1309
+
1310
+
1311
+
1312
+
1313
+
1314
+ </h3><div class="docstring">
1315
+ <div class="discussion">
1316
+ <p>Compress multiple spaces to single space</p>
1317
+
1318
+
1319
+ </div>
1320
+ </div>
1321
+ <div class="tags">
1322
+
1323
+
1324
+ </div>
1325
+ </div>
1326
+
1327
+ <div class="method_details ">
1328
+ <h3 class="signature " id="compress!-instance_method">
1329
+
1330
+ #<strong>compress!</strong> &#x21d2; <tt>Object</tt>
1331
+
1332
+
1333
+
1334
+
1335
+
1336
+ </h3>
1337
+ </div>
1338
+
1339
+ <div class="method_details ">
1340
+ <h3 class="signature " id="dedup_tags-instance_method">
1341
+
1342
+ #<strong>dedup_tags</strong> &#x21d2; <tt>Object</tt>
1343
+
1344
+
1345
+
1346
+
1347
+
1348
+ </h3>
1349
+ </div>
1350
+
1351
+ <div class="method_details ">
1352
+ <h3 class="signature " id="dedup_tags!-instance_method">
1353
+
1354
+ #<strong>dedup_tags!</strong> &#x21d2; <tt>Object</tt>
1355
+
1356
+
1357
+
1358
+
1359
+
1360
+ </h3><div class="docstring">
1361
+ <div class="discussion">
1362
+ <p>Remove duplicate tags, leaving only first occurrence</p>
1363
+
1364
+
1365
+ </div>
1366
+ </div>
1367
+ <div class="tags">
1368
+
1369
+ <p class="tag_title">Returns:</p>
1370
+ <ul class="return">
1371
+
1372
+ <li>
1373
+
1374
+
1375
+ <span class='type'></span>
1376
+
1377
+
1378
+
1379
+
1380
+ <div class='inline'><p>Deduplicated string</p>
1381
+ </div>
1382
+
1383
+ </li>
1384
+
1385
+ </ul>
1386
+
1387
+ </div>
1388
+ </div>
1389
+
1390
+ <div class="method_details ">
1391
+ <h3 class="signature " id="highlight_tags-instance_method">
1392
+
1393
+ #<strong>highlight_tags</strong>(color = &#39;yellow&#39;) &#x21d2; <tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>
1394
+
1395
+
1396
+
1397
+
1398
+
1399
+ </h3><div class="docstring">
956
1400
  <div class="discussion">
957
1401
  <p>Colorize @tags with ANSI escapes</p>
958
1402
 
@@ -1081,13 +1525,98 @@
1081
1525
 
1082
1526
  </ul>
1083
1527
 
1528
+ </div>
1529
+ </div>
1530
+
1531
+ <div class="method_details ">
1532
+ <h3 class="signature " id="is_rx?-instance_method">
1533
+
1534
+ #<strong>is_rx?</strong> &#x21d2; <tt>Boolean</tt>
1535
+
1536
+
1537
+
1538
+
1539
+
1540
+ </h3><div class="docstring">
1541
+ <div class="discussion">
1542
+ <p>Determines if receiver is surrounded by slashes or starts with single quote</p>
1543
+
1544
+
1545
+ </div>
1546
+ </div>
1547
+ <div class="tags">
1548
+
1549
+ <p class="tag_title">Returns:</p>
1550
+ <ul class="return">
1551
+
1552
+ <li>
1553
+
1554
+
1555
+ <span class='type'>(<tt>Boolean</tt>)</span>
1556
+
1557
+
1558
+
1559
+ &mdash;
1560
+ <div class='inline'><p>True if regex, False otherwise.</p>
1561
+ </div>
1562
+
1563
+ </li>
1564
+
1565
+ </ul>
1566
+
1567
+ </div>
1568
+ </div>
1569
+
1570
+ <div class="method_details ">
1571
+ <h3 class="signature " id="last_color-instance_method">
1572
+
1573
+ #<strong>last_color</strong> &#x21d2; <tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>
1574
+
1575
+
1576
+
1577
+
1578
+
1579
+ </h3><div class="docstring">
1580
+ <div class="discussion">
1581
+ <p>Returns the last escape sequence from a string.</p>
1582
+
1583
+ <p>Actually returns all escape codes, with the assumption
1584
+ that the result of inserting them will generate the
1585
+ same color as was set at the end of the string.
1586
+ Because you can send modifiers like dark and bold
1587
+ separate from color codes, only using the last code
1588
+ may not render the same style.</p>
1589
+
1590
+
1591
+ </div>
1592
+ </div>
1593
+ <div class="tags">
1594
+
1595
+ <p class="tag_title">Returns:</p>
1596
+ <ul class="return">
1597
+
1598
+ <li>
1599
+
1600
+
1601
+ <span class='type'>(<tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>)</span>
1602
+
1603
+
1604
+
1605
+ &mdash;
1606
+ <div class='inline'><p>All escape codes in string</p>
1607
+ </div>
1608
+
1609
+ </li>
1610
+
1611
+ </ul>
1612
+
1084
1613
  </div>
1085
1614
  </div>
1086
1615
 
1087
1616
  <div class="method_details ">
1088
1617
  <h3 class="signature " id="link_urls-instance_method">
1089
1618
 
1090
- #<strong>link_urls</strong>(opt = {}) &#x21d2; <tt>Object</tt>
1619
+ #<strong>link_urls</strong>(**opt) &#x21d2; <tt>Object</tt>
1091
1620
 
1092
1621
 
1093
1622
 
@@ -1099,7 +1628,7 @@
1099
1628
  <div class="method_details ">
1100
1629
  <h3 class="signature " id="link_urls!-instance_method">
1101
1630
 
1102
- #<strong>link_urls!</strong>(opt = {}) &#x21d2; <tt>Object</tt>
1631
+ #<strong>link_urls!</strong>(**opt) &#x21d2; <tt>Object</tt>
1103
1632
 
1104
1633
 
1105
1634
 
@@ -1124,8 +1653,6 @@
1124
1653
  <span class='type'>(<tt><span class='object_link'><a href="Hash.html" title="Hash (class)">Hash</a></span></tt>)</span>
1125
1654
 
1126
1655
 
1127
- <em class="default">(defaults to: <tt>{}</tt>)</em>
1128
-
1129
1656
 
1130
1657
  &mdash;
1131
1658
  <div class='inline'><p>Additional Options</p>
@@ -1231,7 +1758,7 @@
1231
1758
 
1232
1759
 
1233
1760
 
1234
- <div class='inline'><p>Symbol :smart, :sensitive, :insensitive</p>
1761
+ <div class='inline'><p>Symbol :smart, :sensitive, :ignore</p>
1235
1762
  </div>
1236
1763
 
1237
1764
  </li>
@@ -1317,33 +1844,254 @@
1317
1844
  </div>
1318
1845
 
1319
1846
  <div class="method_details ">
1320
- <h3 class="signature " id="tag-instance_method">
1847
+ <h3 class="signature " id="remove_self_links-instance_method">
1321
1848
 
1322
- #<strong>tag</strong>(tag, value: nil, remove: false, rename_to: nil, regex: false, single: false) &#x21d2; <tt>Object</tt>
1849
+ #<strong>remove_self_links</strong> &#x21d2; <tt>Object</tt>
1850
+
1851
+
1852
+
1853
+
1854
+
1855
+ </h3><div class="docstring">
1856
+ <div class="discussion">
1857
+ <p>Remove <self-linked> formatting</p>
1858
+
1859
+
1860
+ </div>
1861
+ </div>
1862
+ <div class="tags">
1863
+
1864
+
1865
+ </div>
1866
+ </div>
1867
+
1868
+ <div class="method_details ">
1869
+ <h3 class="signature " id="replace_qualified_urls-instance_method">
1870
+
1871
+ #<strong>replace_qualified_urls</strong>(**options) &#x21d2; <tt>Object</tt>
1872
+
1873
+
1874
+
1875
+
1876
+
1877
+ </h3><div class="docstring">
1878
+ <div class="discussion">
1879
+ <p>Replace qualified urls</p>
1880
+
1881
+
1882
+ </div>
1883
+ </div>
1884
+ <div class="tags">
1885
+
1886
+
1887
+ </div>
1888
+ </div>
1889
+
1890
+ <div class="method_details ">
1891
+ <h3 class="signature " id="set_type-instance_method">
1892
+
1893
+ #<strong>set_type</strong>(kind = nil) &#x21d2; <tt>Object</tt>
1323
1894
 
1324
1895
 
1325
1896
 
1326
1897
 
1327
1898
 
1328
1899
  </h3>
1900
+ </div>
1901
+
1902
+ <div class="method_details ">
1903
+ <h3 class="signature " id="tag-instance_method">
1904
+
1905
+ #<strong>tag</strong>(tag, value: nil, remove: false, rename_to: nil, regex: false, single: false, force: false) &#x21d2; <tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>
1906
+
1907
+
1908
+
1909
+
1910
+
1911
+ </h3><div class="docstring">
1912
+ <div class="discussion">
1913
+ <p>Add, rename, or remove a tag</p>
1914
+
1915
+
1916
+ </div>
1917
+ </div>
1918
+ <div class="tags">
1919
+ <p class="tag_title">Parameters:</p>
1920
+ <ul class="param">
1921
+
1922
+ <li>
1923
+
1924
+ <span class='name'>tag</span>
1925
+
1926
+
1927
+ <span class='type'></span>
1928
+
1929
+
1930
+
1931
+ &mdash;
1932
+ <div class='inline'><p>The tag</p>
1933
+ </div>
1934
+
1935
+ </li>
1936
+
1937
+ <li>
1938
+
1939
+ <span class='name'>value</span>
1940
+
1941
+
1942
+ <span class='type'>(<tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>)</span>
1943
+
1944
+
1945
+ <em class="default">(defaults to: <tt>nil</tt>)</em>
1946
+
1947
+
1948
+ &mdash;
1949
+ <div class='inline'><p>Value for tag (@tag(value))</p>
1950
+ </div>
1951
+
1952
+ </li>
1953
+
1954
+ <li>
1955
+
1956
+ <span class='name'>remove</span>
1957
+
1958
+
1959
+ <span class='type'>(<tt>Boolean</tt>)</span>
1960
+
1961
+
1962
+ <em class="default">(defaults to: <tt>false</tt>)</em>
1963
+
1964
+
1965
+ &mdash;
1966
+ <div class='inline'><p>Remove the tag instead of adding</p>
1967
+ </div>
1968
+
1969
+ </li>
1970
+
1971
+ <li>
1972
+
1973
+ <span class='name'>rename_to</span>
1974
+
1975
+
1976
+ <span class='type'>(<tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>)</span>
1977
+
1978
+
1979
+ <em class="default">(defaults to: <tt>nil</tt>)</em>
1980
+
1981
+
1982
+ &mdash;
1983
+ <div class='inline'><p>Replace tag with this tag</p>
1984
+ </div>
1985
+
1986
+ </li>
1987
+
1988
+ <li>
1989
+
1990
+ <span class='name'>regex</span>
1991
+
1992
+
1993
+ <span class='type'>(<tt>Boolean</tt>)</span>
1994
+
1995
+
1996
+ <em class="default">(defaults to: <tt>false</tt>)</em>
1997
+
1998
+
1999
+ &mdash;
2000
+ <div class='inline'><p>Tag is regular expression</p>
2001
+ </div>
2002
+
2003
+ </li>
2004
+
2005
+ <li>
2006
+
2007
+ <span class='name'>single</span>
2008
+
2009
+
2010
+ <span class='type'>(<tt>Boolean</tt>)</span>
2011
+
2012
+
2013
+ <em class="default">(defaults to: <tt>false</tt>)</em>
2014
+
2015
+
2016
+ &mdash;
2017
+ <div class='inline'><p>Operating on a single item (for logging)</p>
2018
+ </div>
2019
+
2020
+ </li>
2021
+
2022
+ <li>
2023
+
2024
+ <span class='name'>force</span>
2025
+
2026
+
2027
+ <span class='type'>(<tt>Boolean</tt>)</span>
2028
+
2029
+
2030
+ <em class="default">(defaults to: <tt>false</tt>)</em>
2031
+
2032
+
2033
+ &mdash;
2034
+ <div class='inline'><p>With rename_to, add tag if it doesn&#39;t exist</p>
2035
+ </div>
2036
+
2037
+ </li>
2038
+
2039
+ </ul>
2040
+
2041
+ <p class="tag_title">Returns:</p>
2042
+ <ul class="return">
2043
+
2044
+ <li>
2045
+
2046
+
2047
+ <span class='type'>(<tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>)</span>
2048
+
2049
+
2050
+
2051
+ &mdash;
2052
+ <div class='inline'><p>The string with modified tags</p>
2053
+ </div>
2054
+
2055
+ </li>
2056
+
2057
+ </ul>
2058
+
2059
+ </div>
1329
2060
  </div>
1330
2061
 
1331
2062
  <div class="method_details ">
1332
2063
  <h3 class="signature " id="tag!-instance_method">
1333
2064
 
1334
- #<strong>tag!</strong>(tag, value: nil, remove: false, rename_to: nil, regex: false, single: false) &#x21d2; <tt>Object</tt>
2065
+ #<strong>tag!</strong>(tag, **options) &#x21d2; <tt>Object</tt>
1335
2066
 
1336
2067
 
1337
2068
 
1338
2069
 
1339
2070
 
1340
- </h3>
2071
+ </h3><div class="docstring">
2072
+ <div class="discussion">
2073
+ <p>Add, rename, or remove a tag in place</p>
2074
+
2075
+
2076
+ </div>
2077
+ </div>
2078
+ <div class="tags">
2079
+
2080
+
2081
+ <p class="tag_title">See Also:</p>
2082
+ <ul class="see">
2083
+
2084
+ <li><span class='object_link'><a href="#tag-instance_method" title="String#tag (method)">#tag</a></span></li>
2085
+
2086
+ </ul>
2087
+
2088
+ </div>
1341
2089
  </div>
1342
2090
 
1343
2091
  <div class="method_details ">
1344
2092
  <h3 class="signature " id="to_rx-instance_method">
1345
2093
 
1346
- #<strong>to_rx</strong>(distance) &#x21d2; <tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>
2094
+ #<strong>to_rx</strong>(distance: 3, case_type: :smart) &#x21d2; <tt>Regexp</tt>
1347
2095
 
1348
2096
 
1349
2097
 
@@ -1351,13 +2099,26 @@
1351
2099
 
1352
2100
  </h3><div class="docstring">
1353
2101
  <div class="discussion">
1354
- <p>Convert string to fuzzy regex</p>
2102
+ <p>Convert string to fuzzy regex. Characters in words
2103
+ can be separated by up to <em>distance</em> characters in
2104
+ haystack, spaces indicate unlimited distance.</p>
1355
2105
 
1356
2106
 
1357
2107
  </div>
1358
2108
  </div>
1359
2109
  <div class="tags">
1360
- <p class="tag_title">Parameters:</p>
2110
+
2111
+ <div class="examples">
2112
+ <p class="tag_title">Examples:</p>
2113
+
2114
+
2115
+ <p class="example_title"><div class='inline'><p><code>&quot;this word&quot;.to_rx(2) =&gt; /t.{0,3}h.{0,3}i.{0,3}s.{0,3}.*?w.{0,3}o.{0,3}r.{0,3}d/</code></p>
2116
+ </div></p>
2117
+
2118
+ <pre class="example code"><code></code></pre>
2119
+
2120
+ </div>
2121
+ <p class="tag_title">Parameters:</p>
1361
2122
  <ul class="param">
1362
2123
 
1363
2124
  <li>
@@ -1368,6 +2129,8 @@
1368
2129
  <span class='type'>(<tt>Integer</tt>)</span>
1369
2130
 
1370
2131
 
2132
+ <em class="default">(defaults to: <tt>3</tt>)</em>
2133
+
1371
2134
 
1372
2135
  &mdash;
1373
2136
  <div class='inline'><p>Allowed distance
@@ -1376,6 +2139,23 @@ between characters</p>
1376
2139
 
1377
2140
  </li>
1378
2141
 
2142
+ <li>
2143
+
2144
+ <span class='name'>case_type</span>
2145
+
2146
+
2147
+ <span class='type'></span>
2148
+
2149
+
2150
+ <em class="default">(defaults to: <tt>:smart</tt>)</em>
2151
+
2152
+
2153
+ &mdash;
2154
+ <div class='inline'><p>The case type</p>
2155
+ </div>
2156
+
2157
+ </li>
2158
+
1379
2159
  </ul>
1380
2160
 
1381
2161
  <p class="tag_title">Returns:</p>
@@ -1384,7 +2164,7 @@ between characters</p>
1384
2164
  <li>
1385
2165
 
1386
2166
 
1387
- <span class='type'>(<tt><span class='object_link'><a href="" title="String (class)">String</a></span></tt>)</span>
2167
+ <span class='type'>(<tt>Regexp</tt>)</span>
1388
2168
 
1389
2169
 
1390
2170
 
@@ -1627,7 +2407,7 @@ between characters</p>
1627
2407
  <div class="method_details ">
1628
2408
  <h3 class="signature " id="wrap-instance_method">
1629
2409
 
1630
- #<strong>wrap</strong>(len, pad: 0, indent: &#39; &#39;, offset: 0, prefix: &#39;&#39;, after: &#39;&#39;, reset: &#39;&#39;) &#x21d2; <tt>Object</tt>
2410
+ #<strong>wrap</strong>(len, pad: 0, indent: &#39; &#39;, offset: 0, prefix: &#39;&#39;, color: &#39;&#39;, after: &#39;&#39;, reset: &#39;&#39;) &#x21d2; <tt>Object</tt>
1631
2411
 
1632
2412
 
1633
2413
 
@@ -1704,7 +2484,7 @@ between characters</p>
1704
2484
  </div>
1705
2485
 
1706
2486
  <div id="footer">
1707
- Generated on Thu Nov 18 16:39:12 2021 by
2487
+ Generated on Sat Nov 27 13:57:12 2021 by
1708
2488
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1709
2489
  0.9.26 (ruby-3.0.1).
1710
2490
  </div>