doing 2.1.29 → 2.1.33
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.
- checksums.yaml +4 -4
- data/.irbrc +1 -0
- data/CHANGELOG.md +4962 -0
- data/Dockerfile-2.6 +3 -1
- data/Dockerfile-2.7 +4 -2
- data/Dockerfile-3.0 +3 -1
- data/Gemfile.lock +2 -67
- data/README.md +1 -1
- data/bash_profile +13 -0
- data/bin/commands/again.rb +1 -1
- data/bin/commands/archive.rb +3 -3
- data/bin/commands/cancel.rb +1 -1
- data/bin/commands/changes.rb +2 -2
- data/bin/commands/commands.rb +8 -8
- data/bin/commands/completion.rb +61 -19
- data/bin/commands/config.rb +20 -17
- data/bin/commands/done.rb +1 -1
- data/bin/commands/flag.rb +1 -1
- data/bin/commands/grep.rb +5 -5
- data/bin/commands/last.rb +1 -1
- data/bin/commands/meanwhile.rb +1 -1
- data/bin/commands/now.rb +1 -1
- data/bin/commands/on.rb +1 -1
- data/bin/commands/open.rb +4 -4
- data/bin/commands/recent.rb +4 -4
- data/bin/commands/show.rb +8 -8
- data/bin/commands/since.rb +1 -1
- data/bin/commands/tag_dir.rb +27 -3
- data/bin/commands/today.rb +1 -1
- data/bin/commands/view.rb +3 -3
- data/bin/commands/yesterday.rb +2 -2
- data/bin/doing +26 -135
- data/docs/doc/Array.html +1 -1
- data/docs/doc/BooleanTermParser/Clause.html +1 -1
- data/docs/doc/BooleanTermParser/Operator.html +1 -1
- data/docs/doc/BooleanTermParser/Query.html +1 -1
- data/docs/doc/BooleanTermParser/QueryParser.html +1 -1
- data/docs/doc/BooleanTermParser/QueryTransformer.html +1 -1
- data/docs/doc/BooleanTermParser.html +1 -1
- data/docs/doc/Doing/Color.html +1 -1
- data/docs/doc/Doing/Completion.html +324 -4
- data/docs/doc/Doing/Configuration.html +3 -3
- data/docs/doc/Doing/Errors/DoingNoTraceError.html +1 -1
- data/docs/doc/Doing/Errors/DoingRuntimeError.html +1 -1
- data/docs/doc/Doing/Errors/DoingStandardError.html +1 -1
- data/docs/doc/Doing/Errors/EmptyInput.html +1 -1
- data/docs/doc/Doing/Errors/NoResults.html +1 -1
- data/docs/doc/Doing/Errors/PluginException.html +1 -1
- data/docs/doc/Doing/Errors/UserCancelled.html +1 -1
- data/docs/doc/Doing/Errors/WrongCommand.html +1 -1
- data/docs/doc/Doing/Errors.html +1 -1
- data/docs/doc/Doing/Hooks.html +1 -1
- data/docs/doc/Doing/Item.html +125 -1
- data/docs/doc/Doing/Items.html +1 -1
- data/docs/doc/Doing/LogAdapter.html +1 -1
- data/docs/doc/Doing/Note.html +109 -3
- data/docs/doc/Doing/Pager.html +1 -1
- data/docs/doc/Doing/Plugins.html +1 -1
- data/docs/doc/Doing/Prompt.html +1 -1
- data/docs/doc/Doing/Section.html +1 -1
- data/docs/doc/Doing/TemplateString.html +1 -1
- data/docs/doc/Doing/Types.html +2 -2
- data/docs/doc/Doing/Util/Backup.html +1 -1
- data/docs/doc/Doing/Util.html +1 -1
- data/docs/doc/Doing/WWID.html +6 -6
- data/docs/doc/Doing.html +2 -2
- data/docs/doc/FalseClass.html +1 -1
- data/docs/doc/GLI/Commands/Help.html +1 -1
- data/docs/doc/GLI/Commands/MarkdownDocumentListener.html +1 -1
- data/docs/doc/GLI/Commands.html +1 -1
- data/docs/doc/GLI.html +1 -1
- data/docs/doc/Hash.html +1 -1
- data/docs/doc/Object.html +1 -1
- data/docs/doc/PhraseParser/Operator.html +1 -1
- data/docs/doc/PhraseParser/PhraseClause.html +1 -1
- data/docs/doc/PhraseParser/Query.html +1 -1
- data/docs/doc/PhraseParser/QueryParser.html +1 -1
- data/docs/doc/PhraseParser/QueryTransformer.html +1 -1
- data/docs/doc/PhraseParser/TermClause.html +1 -1
- data/docs/doc/PhraseParser.html +1 -1
- data/docs/doc/Status.html +1 -1
- data/docs/doc/String.html +1 -1
- data/docs/doc/Symbol.html +1 -1
- data/docs/doc/Time.html +1 -1
- data/docs/doc/TrueClass.html +1 -1
- data/docs/doc/_index.html +3 -1
- data/docs/doc/file.README.html +2 -2
- data/docs/doc/index.html +2 -2
- data/docs/doc/method_list.html +337 -241
- data/docs/doc/top-level-namespace.html +105 -1
- data/docs/index.md +1 -1
- data/doing.gemspec +24 -23
- data/doing.rdoc +34 -13
- data/example_plugin.rb +7 -5
- data/inputrc +57 -0
- data/lib/completion/_doing.zsh +46 -46
- data/lib/completion/doing.bash +2 -2
- data/lib/completion/doing.fish +4 -4
- data/lib/doing/add_options.rb +117 -0
- data/lib/doing/array/array.rb +16 -0
- data/lib/doing/changelog/changes.rb +8 -6
- data/lib/doing/changelog/version.rb +11 -3
- data/lib/doing/completion/bash_completion.rb +12 -51
- data/lib/doing/completion/fish_completion.rb +17 -53
- data/lib/doing/completion/zsh_completion.rb +21 -54
- data/lib/doing/completion.rb +203 -17
- data/lib/doing/configuration.rb +12 -6
- data/lib/doing/item.rb +21 -3
- data/lib/doing/items.rb +5 -5
- data/lib/doing/note.rb +24 -8
- data/lib/doing/plugins/export/dayone_export.rb +8 -6
- data/lib/doing/plugins/export/html_export.rb +4 -4
- data/lib/doing/plugins/export/json_export.rb +19 -20
- data/lib/doing/plugins/export/markdown_export.rb +2 -2
- data/lib/doing/plugins/export/template_export.rb +4 -4
- data/lib/doing/plugins/import/calendar_import.rb +1 -1
- data/lib/doing/plugins/import/doing_import.rb +1 -1
- data/lib/doing/plugins/import/timing_import.rb +1 -1
- data/lib/doing/section.rb +1 -1
- data/lib/doing/string/highlight.rb +3 -4
- data/lib/doing/string/string.rb +8 -0
- data/lib/doing/types.rb +1 -1
- data/lib/doing/util.rb +1 -1
- data/lib/doing/util_backup.rb +12 -12
- data/lib/doing/version.rb +1 -1
- data/lib/doing/wwid.rb +75 -76
- data/lib/doing.rb +58 -0
- data/lib/examples/commands/wiki.rb +27 -19
- data/lib/helpers/threaded_tests.rb +2 -0
- data/scripts/setting_replace.rb +11 -0
- metadata +107 -102
- data/.yardoc/checksums +0 -29
- data/.yardoc/complete +0 -0
- data/.yardoc/object_types +0 -0
- data/.yardoc/objects/root.dat +0 -0
- data/.yardoc/proxy_types +0 -0
|
@@ -97,12 +97,116 @@
|
|
|
97
97
|
|
|
98
98
|
|
|
99
99
|
|
|
100
|
+
|
|
101
|
+
<h2>
|
|
102
|
+
Instance Method Summary
|
|
103
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
|
104
|
+
</h2>
|
|
105
|
+
|
|
106
|
+
<ul class="summary">
|
|
107
|
+
|
|
108
|
+
<li class="public ">
|
|
109
|
+
<span class="summary_signature">
|
|
110
|
+
|
|
111
|
+
<a href="top-level-namespace.html#add_options-instance_method" title="#add_options (instance method)">#<strong>add_options</strong>(type, cmd) ⇒ Object </a>
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
</span>
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
<span class="summary_desc"><div class='inline'><p>Add presets of flags and switches to a command.</p>
|
|
126
|
+
</div></span>
|
|
127
|
+
|
|
128
|
+
</li>
|
|
100
129
|
|
|
130
|
+
|
|
131
|
+
</ul>
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
<div id="instance_method_details" class="method_details_list">
|
|
137
|
+
<h2>Instance Method Details</h2>
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
<div class="method_details first">
|
|
141
|
+
<h3 class="signature first" id="add_options-instance_method">
|
|
142
|
+
|
|
143
|
+
#<strong>add_options</strong>(type, cmd) ⇒ <tt><span class='object_link'><a href="Object.html" title="Object (class)">Object</a></span></tt>
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
</h3><div class="docstring">
|
|
150
|
+
<div class="discussion">
|
|
151
|
+
<p>Add presets of flags and switches to a command.</p>
|
|
152
|
+
|
|
153
|
+
<p>:add_entry => --noauto, --note, --ask, --editor, --back</p>
|
|
154
|
+
|
|
155
|
+
<p>:search => --search, --case, --exact</p>
|
|
156
|
+
|
|
157
|
+
<p>:tag_filter => --tag, --bool, --not, --val</p>
|
|
158
|
+
|
|
159
|
+
<p>:date_filter => --before, --after, --from</p>
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
</div>
|
|
163
|
+
</div>
|
|
164
|
+
<div class="tags">
|
|
165
|
+
<p class="tag_title">Parameters:</p>
|
|
166
|
+
<ul class="param">
|
|
167
|
+
|
|
168
|
+
<li>
|
|
169
|
+
|
|
170
|
+
<span class='name'>type</span>
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
<span class='type'>(<tt><span class='object_link'><a href="Symbol.html" title="Symbol (class)">Symbol</a></span></tt>)</span>
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
—
|
|
178
|
+
<div class='inline'><p>The type</p>
|
|
179
|
+
</div>
|
|
180
|
+
|
|
181
|
+
</li>
|
|
182
|
+
|
|
183
|
+
<li>
|
|
184
|
+
|
|
185
|
+
<span class='name'>cmd</span>
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
<span class='type'></span>
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
—
|
|
193
|
+
<div class='inline'><p>The GLI command to which the options will be added</p>
|
|
194
|
+
</div>
|
|
195
|
+
|
|
196
|
+
</li>
|
|
197
|
+
|
|
198
|
+
</ul>
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
</div>
|
|
202
|
+
</div>
|
|
203
|
+
|
|
204
|
+
</div>
|
|
101
205
|
|
|
102
206
|
</div>
|
|
103
207
|
|
|
104
208
|
<div id="footer">
|
|
105
|
-
Generated on
|
|
209
|
+
Generated on Fri Feb 18 12:22:34 2022 by
|
|
106
210
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
107
211
|
0.9.27 (ruby-3.0.1).
|
|
108
212
|
</div>
|
data/docs/index.md
CHANGED
data/doing.gemspec
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# Ensure we require the local version and not one we might have installed already
|
|
2
|
-
require File.join([File.dirname(__FILE__),'lib','doing','version.rb'])
|
|
2
|
+
require File.join([File.dirname(__FILE__), 'lib', 'doing', 'version.rb'])
|
|
3
3
|
spec = Gem::Specification.new do |s|
|
|
4
4
|
s.name = 'doing'
|
|
5
5
|
s.version = Doing::VERSION
|
|
@@ -8,13 +8,14 @@ spec = Gem::Specification.new do |s|
|
|
|
8
8
|
s.homepage = 'http://brettterpstra.com/project/doing/'
|
|
9
9
|
s.platform = Gem::Platform::RUBY
|
|
10
10
|
s.summary = 'A command line tool for managing What Was I Doing reminders'
|
|
11
|
-
s.description =
|
|
11
|
+
s.description = [
|
|
12
|
+
'A tool for managing a TaskPaper-like file of recent activites.',
|
|
13
|
+
'Perfect for the late-night hacker on too much caffeine to remember',
|
|
14
|
+
'what they accomplished at 2 in the morning.'
|
|
15
|
+
].join(' ')
|
|
12
16
|
s.license = 'MIT'
|
|
13
|
-
# Add your other files here if you make them
|
|
14
17
|
s.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
|
15
|
-
|
|
16
|
-
f.strip =~ /^((test|spec|features)\/|\.git|buildnotes)/
|
|
17
|
-
}
|
|
18
|
+
`git ls-files -z`.split("\x0").reject { |f| f.strip =~ %r{^((test|spec|features)/|\.git|buildnotes)} }
|
|
18
19
|
end
|
|
19
20
|
s.require_paths << 'lib'
|
|
20
21
|
|
|
@@ -22,27 +23,27 @@ spec = Gem::Specification.new do |s|
|
|
|
22
23
|
s.rdoc_options << '--title' << 'doing' << '--main' << 'README.md' << '--markup' << 'markdown'
|
|
23
24
|
s.bindir = 'bin'
|
|
24
25
|
s.executables << 'doing'
|
|
25
|
-
s.
|
|
26
|
-
s.add_development_dependency
|
|
27
|
-
s.add_development_dependency
|
|
28
|
-
s.add_development_dependency
|
|
29
|
-
s.add_development_dependency
|
|
30
|
-
s.add_development_dependency
|
|
31
|
-
s.add_development_dependency
|
|
32
|
-
s.add_development_dependency
|
|
33
|
-
s.
|
|
34
|
-
s.add_development_dependency 'tty-spinner', '~> 0.9', '>= 0.9.3'
|
|
35
|
-
s.add_runtime_dependency('tty-progressbar', '~> 0.18', '>= 0.18.2')
|
|
36
|
-
s.add_runtime_dependency('gli', '~> 2.20', '>= 2.20.1')
|
|
37
|
-
s.add_runtime_dependency('haml','~>5.0.0', '>= 5.0.0')
|
|
38
|
-
s.add_runtime_dependency('chronic','~> 0.10', '>= 0.10.2')
|
|
26
|
+
s.add_development_dependency('github-markup', '~> 4.0', '>= 4.0.0')
|
|
27
|
+
s.add_development_dependency('parallel_tests', '~> 3.7', '>= 3.7.3')
|
|
28
|
+
s.add_development_dependency('rake', '~> 13.0', '>= 13.0.1')
|
|
29
|
+
s.add_development_dependency('rdoc', '~> 6.3.1')
|
|
30
|
+
s.add_development_dependency('redcarpet', '~> 3.5', '>= 3.5.1')
|
|
31
|
+
s.add_development_dependency('test-unit', '~> 3.4.4')
|
|
32
|
+
s.add_development_dependency('tty-spinner', '~> 0.9', '>= 0.9.3')
|
|
33
|
+
s.add_development_dependency('yard', '~> 0.9', '>= 0.9.26')
|
|
34
|
+
s.add_runtime_dependency('chronic', '~> 0.10', '>= 0.10.2')
|
|
39
35
|
s.add_runtime_dependency('deep_merge', '~> 1.2', '>= 1.2.1')
|
|
36
|
+
s.add_runtime_dependency('gli', '~> 2.20', '>= 2.20.1')
|
|
37
|
+
s.add_runtime_dependency('haml', '~>5.0.0', '>= 5.0.0')
|
|
38
|
+
s.add_runtime_dependency('parslet', '~> 2.0', '>= 2.0.0')
|
|
39
|
+
s.add_runtime_dependency('plist', '~> 3.6', '>= 3.6.0')
|
|
40
|
+
s.add_runtime_dependency('safe_yaml', '~> 1.0')
|
|
41
|
+
s.add_runtime_dependency('sys-uname', '~> 1.2', '>= 1.2.2')
|
|
40
42
|
s.add_runtime_dependency('tty-link', '~> 0.1', '>= 0.1.1')
|
|
41
|
-
s.add_runtime_dependency('tty-which', '~> 0.5', '>= 0.5.0')
|
|
42
43
|
s.add_runtime_dependency('tty-markdown', '~> 0.7', '>= 0.7.0')
|
|
44
|
+
s.add_runtime_dependency('tty-progressbar', '~> 0.18', '>= 0.18.2')
|
|
43
45
|
s.add_runtime_dependency('tty-reader', '~> 0.9', '>= 0.9.0')
|
|
44
46
|
s.add_runtime_dependency('tty-screen', '~> 0.8', '>= 0.8.1')
|
|
45
|
-
s.add_runtime_dependency('
|
|
46
|
-
s.add_runtime_dependency('plist', '~> 3.6', '>= 3.6.0')
|
|
47
|
+
s.add_runtime_dependency('tty-which', '~> 0.5', '>= 0.5.0')
|
|
47
48
|
# s.add_runtime_dependency('amatch', '~> 0.4', '>= 0.4.0')
|
|
48
49
|
end
|
data/doing.rdoc
CHANGED
|
@@ -5,7 +5,7 @@ record of what you've been doing, complete with tag-based time tracking. The
|
|
|
5
5
|
command line tool allows you to add entries, annotate with tags and notes, and
|
|
6
6
|
view your entries with myriad options, with a focus on a "natural" language syntax.
|
|
7
7
|
|
|
8
|
-
v2.1.
|
|
8
|
+
v2.1.33
|
|
9
9
|
|
|
10
10
|
=== Global Options
|
|
11
11
|
=== --config_file arg
|
|
@@ -440,10 +440,10 @@ Display a formatted list of changes in recent versions.
|
|
|
440
440
|
|
|
441
441
|
Look up a specific version. Specify versions as "MAJ.MIN.PATCH", MIN
|
|
442
442
|
and PATCH are optional. Use > or < to see all changes since or prior
|
|
443
|
-
to a version.
|
|
443
|
+
to a version. Wildcards (*?) accepted unless using < or >.
|
|
444
444
|
|
|
445
445
|
[Default Value] None
|
|
446
|
-
[Must Match] (?-mix:^(?:(?:(?:[<>=]
|
|
446
|
+
[Must Match] (?-mix:^(?:(?:(?:[<>=]+|p(?:rior)|b(?:efore)|o(?:lder)|s(?:ince)|a(?:fter)|n(?:ewer))? *[0-9.*?]+ *)+|(?:[\d.]+ *(?:-|to)+ *[0-9.]+))$)
|
|
447
447
|
|
|
448
448
|
|
|
449
449
|
===== -s|--search arg
|
|
@@ -506,26 +506,42 @@ Disable Doing commands
|
|
|
506
506
|
|
|
507
507
|
[Default Command] add
|
|
508
508
|
==== Command: <tt>completion </tt>
|
|
509
|
-
Generate shell completion scripts
|
|
509
|
+
Generate shell completion scripts for doing
|
|
510
510
|
|
|
511
511
|
Generates the necessary scripts to add command line completion to various shells,
|
|
512
512
|
so typing 'doing' and hitting tab will offer completions of subcommands and their options.
|
|
513
513
|
===== Options
|
|
514
|
-
===== -
|
|
514
|
+
===== -t|--type arg
|
|
515
515
|
|
|
516
|
-
|
|
516
|
+
Deprecated, specify shell as argument to subcommand
|
|
517
517
|
|
|
518
|
-
[Default Value]
|
|
518
|
+
[Default Value] None
|
|
519
|
+
[Must Match] (?i-mx:^(?:[bzf](?:[ai]?sh)?|all)$)
|
|
519
520
|
|
|
520
521
|
|
|
521
|
-
=====
|
|
522
|
+
===== Commands
|
|
523
|
+
====== Command: <tt>generate [zsh|bash|fish|all]</tt>
|
|
524
|
+
Generate completion scripts, including custom plugins and command options
|
|
525
|
+
|
|
526
|
+
Argument specifies which shell to install for: zsh, bash, fish, all
|
|
527
|
+
======= Options
|
|
528
|
+
======= -f|--file PATH
|
|
529
|
+
|
|
530
|
+
Alternative file to write output to
|
|
531
|
+
|
|
532
|
+
[Default Value] None
|
|
533
|
+
Argument specifies which shell to install for: zsh, bash, fish, all
|
|
534
|
+
|
|
535
|
+
======= --stdout
|
|
536
|
+
Output result to STDOUT only
|
|
522
537
|
|
|
523
|
-
Shell to generate for (bash, zsh, fish)
|
|
524
538
|
|
|
525
|
-
[Default Value] zsh
|
|
526
|
-
[Must Match] (?i-mx:^(?:[bzf](?:[ai]?sh)?|all)$)
|
|
527
539
|
|
|
540
|
+
====== Command: <tt>install [zsh|bash|fish]</tt>
|
|
541
|
+
Install default completion scripts
|
|
528
542
|
|
|
543
|
+
Argument specifies which shell to install for: zsh, bash, fish, or all
|
|
544
|
+
[Default Command] generate
|
|
529
545
|
==== Command: <tt>config </tt>
|
|
530
546
|
Edit the configuration file or output a value from it
|
|
531
547
|
|
|
@@ -604,6 +620,11 @@ Set a key's value in the config file
|
|
|
604
620
|
|
|
605
621
|
|
|
606
622
|
======= Options
|
|
623
|
+
======= --local
|
|
624
|
+
Force update to .doingrc in the current directory
|
|
625
|
+
|
|
626
|
+
|
|
627
|
+
|
|
607
628
|
======= -r|--remove
|
|
608
629
|
Delete specified key
|
|
609
630
|
|
|
@@ -646,7 +667,7 @@ Start and end times as a date/time range `doing done --from "1am to 8am"`.
|
|
|
646
667
|
Overrides other date flags.
|
|
647
668
|
|
|
648
669
|
[Default Value] None
|
|
649
|
-
[Must Match] (?i-mx:^\S
|
|
670
|
+
[Must Match] (?i-mx:^\S+.*? +(?:to|through|thru|(?:un)?til|-+) +\S+.*?$)
|
|
650
671
|
|
|
651
672
|
|
|
652
673
|
===== -n|--note TEXT
|
|
@@ -1530,7 +1551,7 @@ Show time totals at the end of output
|
|
|
1530
1551
|
==== Command: <tt>open </tt>
|
|
1531
1552
|
Open the "doing" file in an editor
|
|
1532
1553
|
|
|
1533
|
-
`doing open` defaults to using the editors
|
|
1554
|
+
`doing open` defaults to using the editors.doing_file setting
|
|
1534
1555
|
in /Users/ttscoff/.config/doing/config.yml (TaskPaper).
|
|
1535
1556
|
===== Options
|
|
1536
1557
|
===== -a|--app APP_NAME
|
data/example_plugin.rb
CHANGED
|
@@ -54,7 +54,7 @@ module Doing
|
|
|
54
54
|
## automatically be added for the user to override
|
|
55
55
|
## The config key will be available at:
|
|
56
56
|
##
|
|
57
|
-
##
|
|
57
|
+
## Doing.config.settings['export_templates'][PLUGIN_NAME]
|
|
58
58
|
##
|
|
59
59
|
## config: (optional) A Hash which will be
|
|
60
60
|
## added to the main configuration in the plugins section.
|
|
@@ -65,7 +65,7 @@ module Doing
|
|
|
65
65
|
##
|
|
66
66
|
## The configuration keys will be available at:
|
|
67
67
|
##
|
|
68
|
-
##
|
|
68
|
+
## Doing.config.settings['plugins'][PLUGIN_NAME][KEY]
|
|
69
69
|
##
|
|
70
70
|
## Method to return plugin settings (required)
|
|
71
71
|
##
|
|
@@ -125,6 +125,8 @@ module Doing
|
|
|
125
125
|
def self.render(wwid, items, variables: {})
|
|
126
126
|
return unless items.good?
|
|
127
127
|
|
|
128
|
+
config = Doing.config.settings
|
|
129
|
+
|
|
128
130
|
# the :options key includes the flags passed to the
|
|
129
131
|
# command that called the plugin use `puts
|
|
130
132
|
# variables.inspect` to see properties and methods
|
|
@@ -162,8 +164,8 @@ module Doing
|
|
|
162
164
|
title = i.title.gsub(/@/, 'hashtag ')
|
|
163
165
|
tpl = template('say')
|
|
164
166
|
|
|
165
|
-
if
|
|
166
|
-
cfg_tpl =
|
|
167
|
+
if config['export_templates'].key?('say')
|
|
168
|
+
cfg_tpl = config['export_templates']['say']
|
|
167
169
|
tpl = cfg_tpl if cfg_tpl.good?
|
|
168
170
|
end
|
|
169
171
|
output = tpl.dup
|
|
@@ -188,7 +190,7 @@ module Doing
|
|
|
188
190
|
Doing.logger.info('Spoke the last entry. Did you hear it?')
|
|
189
191
|
|
|
190
192
|
# This export runs a command for fun, most plugins won't
|
|
191
|
-
voice =
|
|
193
|
+
voice = config['plugins']['say']['say_voice'] || 'Alex'
|
|
192
194
|
`say -v "#{voice}" "#{output}"`
|
|
193
195
|
|
|
194
196
|
# Return the result (don't output to terminal with puts or print)
|
data/inputrc
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"\e[3~": delete-char
|
|
2
|
+
"\ex": 'cd !$ \015ls\015'
|
|
3
|
+
"\ez": 'cd -\015'
|
|
4
|
+
"\e\C-m": '\C-a "$(\C-e|fzf)"\C-a'
|
|
5
|
+
"\e/": '"$(!!|fzf)"\C-a \C-m\C-m'
|
|
6
|
+
# these allow you to use alt+left/right arrow keys
|
|
7
|
+
# to jump the cursor over words
|
|
8
|
+
"\e[1;5C": forward-word
|
|
9
|
+
"\e[1;5D": backward-word
|
|
10
|
+
# "\e[D": backward-word
|
|
11
|
+
# "\e[C": forward-word
|
|
12
|
+
"\ea": menu-complete
|
|
13
|
+
# TAB: menu-complete
|
|
14
|
+
# "\e[Z": "\e-1\C-i"
|
|
15
|
+
|
|
16
|
+
"\e\C-l": history-and-alias-expand-line
|
|
17
|
+
|
|
18
|
+
# these allow you to start typing a command and
|
|
19
|
+
# use the up/down arrow to auto complete from
|
|
20
|
+
# commands in your history
|
|
21
|
+
"\e[B": history-search-forward
|
|
22
|
+
"\e[A": history-search-backward
|
|
23
|
+
"\ew": history-search-backward
|
|
24
|
+
"\es": history-search-forward
|
|
25
|
+
# this lets you hit tab to auto-complete a file or
|
|
26
|
+
# directory name ignoring case
|
|
27
|
+
set completion-ignore-case On
|
|
28
|
+
set mark-symlinked-directories On
|
|
29
|
+
set completion-prefix-display-length 2
|
|
30
|
+
set bell-style none
|
|
31
|
+
# set bell-style visible
|
|
32
|
+
set meta-flag on
|
|
33
|
+
set convert-meta off
|
|
34
|
+
set input-meta on
|
|
35
|
+
set output-meta on
|
|
36
|
+
set show-all-if-ambiguous on
|
|
37
|
+
set show-all-if-unmodified on
|
|
38
|
+
set completion-map-case on
|
|
39
|
+
set visible-stats on
|
|
40
|
+
|
|
41
|
+
# Do history expansion when space entered?
|
|
42
|
+
$if bash
|
|
43
|
+
Space: magic-space
|
|
44
|
+
$endif
|
|
45
|
+
|
|
46
|
+
# Show extra file information when completing, like `ls -F` does
|
|
47
|
+
set visible-stats on
|
|
48
|
+
|
|
49
|
+
# Be more intelligent when autocompleting by also looking at the text after
|
|
50
|
+
# the cursor. For example, when the current line is "cd ~/src/mozil", and
|
|
51
|
+
# the cursor is on the "z", pressing Tab will not autocomplete it to "cd
|
|
52
|
+
# ~/src/mozillail", but to "cd ~/src/mozilla". (This is supported by the
|
|
53
|
+
# Readline used by Bash 4.)
|
|
54
|
+
set skip-completed-text on
|
|
55
|
+
|
|
56
|
+
# Use Alt/Meta + Delete to delete the preceding word
|
|
57
|
+
"\e[3;3~": kill-word
|