doing 2.1.14 → 2.1.18
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.irbrc +1 -0
- data/.yardoc/checksums +14 -12
- data/.yardoc/object_types +0 -0
- data/.yardoc/objects/root.dat +0 -0
- data/CHANGELOG.md +66 -0
- data/Gemfile.lock +3 -2
- data/README.md +56 -19
- data/bin/doing +134 -47
- data/docs/doc/Array.html +117 -3
- 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 +6 -2
- data/docs/doc/Doing/Completion.html +1 -1
- data/docs/doc/Doing/Configuration.html +8 -4
- 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 +224 -2
- data/docs/doc/Doing/Items.html +2 -2
- data/docs/doc/Doing/LogAdapter.html +1 -1
- data/docs/doc/Doing/Note.html +2 -2
- data/docs/doc/Doing/Pager.html +1 -1
- data/docs/doc/Doing/Plugins.html +1 -1
- data/docs/doc/Doing/Prompt.html +69 -1
- data/docs/doc/Doing/Section.html +1 -1
- data/docs/doc/Doing/TemplateString.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 +71 -67
- data/docs/doc/Doing.html +3 -3
- 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/Numeric.html +279 -0
- 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 +997 -118
- data/docs/doc/Symbol.html +1 -1
- data/docs/doc/Time.html +1 -1
- data/docs/doc/_index.html +14 -9
- data/docs/doc/class_list.html +1 -1
- data/docs/doc/file.README.html +41 -15
- data/docs/doc/index.html +41 -15
- data/docs/doc/method_list.html +448 -312
- data/docs/doc/top-level-namespace.html +2 -2
- data/docs/index.md +56 -19
- data/doing.gemspec +1 -0
- data/doing.rdoc +36 -6
- data/example_plugin.rb +2 -4
- data/lib/completion/_doing.zsh +8 -8
- data/lib/completion/doing.bash +12 -12
- data/lib/completion/doing.fish +8 -3
- data/lib/doing/array_chronify.rb +57 -0
- data/lib/doing/colors.rb +4 -0
- data/lib/doing/configuration.rb +6 -2
- data/lib/doing/item.rb +83 -0
- data/lib/doing/log_adapter.rb +3 -3
- data/lib/doing/numeric_chronify.rb +40 -0
- data/lib/doing/plugins/export/dayone_export.rb +1 -1
- data/lib/doing/plugins/export/json_export.rb +2 -2
- data/lib/doing/plugins/export/template_export.rb +49 -90
- data/lib/doing/prompt.rb +52 -0
- data/lib/doing/string.rb +137 -33
- data/lib/doing/string_chronify.rb +112 -14
- data/lib/doing/template_string.rb +1 -1
- data/lib/doing/time.rb +4 -4
- data/lib/doing/util_backup.rb +1 -1
- data/lib/doing/version.rb +1 -1
- data/lib/doing/wwid.rb +107 -101
- data/lib/doing.rb +35 -31
- data/lib/examples/plugins/say_export.rb +1 -4
- metadata +26 -2
@@ -86,7 +86,7 @@
|
|
86
86
|
|
87
87
|
|
88
88
|
|
89
|
-
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Array.html" title="Array (class)">Array</a></span>, <span class='object_link'><a href="Hash.html" title="Hash (class)">Hash</a></span>, <span class='object_link'><a href="String.html" title="String (class)">String</a></span>, <span class='object_link'><a href="Symbol.html" title="Symbol (class)">Symbol</a></span>, <span class='object_link'><a href="Time.html" title="Time (class)">Time</a></span>
|
89
|
+
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Array.html" title="Array (class)">Array</a></span>, <span class='object_link'><a href="Hash.html" title="Hash (class)">Hash</a></span>, <span class='object_link'><a href="Numeric.html" title="Numeric (class)">Numeric</a></span>, <span class='object_link'><a href="String.html" title="String (class)">String</a></span>, <span class='object_link'><a href="Symbol.html" title="Symbol (class)">Symbol</a></span>, <span class='object_link'><a href="Time.html" title="Time (class)">Time</a></span>
|
90
90
|
|
91
91
|
|
92
92
|
</p>
|
@@ -102,7 +102,7 @@
|
|
102
102
|
</div>
|
103
103
|
|
104
104
|
<div id="footer">
|
105
|
-
Generated on
|
105
|
+
Generated on Tue Jan 18 07:44:43 2022 by
|
106
106
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
107
107
|
0.9.26 (ruby-3.0.1).
|
108
108
|
</div>
|
data/docs/index.md
CHANGED
@@ -1,53 +1,90 @@
|
|
1
1
|
# doing
|
2
2
|
|
3
|
-
**A command line tool for remembering what you were doing and tracking what
|
3
|
+
**A command line tool for remembering what you were doing and tracking what
|
4
|
+
you've done.**
|
4
5
|
|
5
|
-
_If you're one of the rare people like me who find this useful, feel free to
|
6
|
+
_If you're one of the rare people like me who find this useful, feel free to
|
7
|
+
[buy me some coffee][donate]._
|
6
8
|
|
7
9
|
|
8
10
|
|
9
|
-
The current version of `doing` is 2.1.
|
11
|
+
The current version of `doing` is 2.1.13.
|
10
12
|
|
11
|
-
Find all of the documentation in the [doing wiki]
|
13
|
+
Find all of the documentation in the [doing wiki][wiki].
|
12
14
|
|
13
|
-
See [what's new in Doing 2.0]
|
15
|
+
See [what's new in Doing 2.0][doing 2].
|
14
16
|
|
15
|
-
Check out some craziness with Doing in the [iTerm status bar]
|
17
|
+
Check out some craziness with Doing in the [iTerm status bar][status bar] and
|
18
|
+
the [Mac Touch Bar/menu bar][touch bar].
|
16
19
|
|
17
20
|
## What and why
|
18
21
|
|
19
|
-
`doing` is a basic CLI for adding and listing "what was I doing" reminders in a
|
22
|
+
`doing` is a basic CLI for adding and listing "what was I doing" reminders in a
|
23
|
+
[TaskPaper-formatted](https://www.taskpaper.com) text file. It allows for
|
24
|
+
multiple sections/categories and flexible output formatting.
|
20
25
|
|
21
|
-
While I'm working, I have hourly reminders to record what I'm working on, and I
|
26
|
+
While I'm working, I have hourly reminders to record what I'm working on, and I
|
27
|
+
try to remember to punch in quick notes if I'm unexpectedly called away from a
|
28
|
+
project. I can do this just by typing `doing now tracking down the CG bug`.
|
22
29
|
|
23
|
-
If there's something I want to look at later but doesn't need to be added to a
|
30
|
+
If there's something I want to look at later but doesn't need to be added to a
|
31
|
+
task list or tracker, I can type `doing later check out the pinboard bookmarks
|
32
|
+
from macdrifter`. When I get back to my computer --- or just need a refresher
|
33
|
+
after a distraction --- I can type `doing last` to see what the last thing on
|
34
|
+
my plate was. I can also type `doing recent` (or just `doing`) to get a list of
|
35
|
+
the last few entries. `doing today` gives me everything since midnight for the
|
36
|
+
current day, making it easy to see what I've accomplished over a sleepless
|
37
|
+
night.
|
24
38
|
|
25
|
-
Doing has over 30 commands for tracking your status, recording your time, and
|
39
|
+
Doing has over 30 commands for tracking your status, recording your time, and
|
40
|
+
analyzing the results.
|
26
41
|
|
27
|
-
See [the wiki]
|
42
|
+
See [the wiki][wiki] for installation and usage instructions.
|
28
43
|
|
29
44
|
## Launchbar/Alfred
|
30
45
|
|
31
|
-
The LaunchBar action requires that `doing` be available in
|
46
|
+
The LaunchBar action requires that `doing` be available in
|
47
|
+
`/usr/local/bin/doing`. If it's not (because you're using RVM or similar),
|
48
|
+
you'll need to symlink it there. Running the action with Return will show the
|
49
|
+
latest 9 items from Currently, along with any time intervals recorded, and
|
50
|
+
includes a submenu of Timers for each tag.
|
32
51
|
|
33
|
-
Pressing Spacebar and typing allows you to add a new entry to currently. You an
|
52
|
+
Pressing Spacebar and typing allows you to add a new entry to currently. You an
|
53
|
+
also trigger a custom show command by typing "show [section/tag]" and hitting
|
54
|
+
return. Include any command line flags at the end of the string, and if you add
|
55
|
+
text in parenthesis, it will be processed as a note on the entry.
|
34
56
|
|
35
|
-
Point of interest, the LaunchBar Action makes use of the `-o json` flag for
|
57
|
+
Point of interest, the LaunchBar Action makes use of the `-o json` flag for
|
58
|
+
outputting JSON to the action's script for parsing.
|
36
59
|
|
37
60
|
|
38
61
|
|
39
|
-
See the [doing project on BrettTerpstra.com]
|
62
|
+
See the [doing project on BrettTerpstra.com][bt doing] for the download.
|
40
63
|
|
41
64
|
|
42
65
|
|
43
66
|
|
44
|
-
Evan Lovely has
|
67
|
+
Evan Lovely has created an [Alfred workflow][] as well.
|
45
68
|
|
46
69
|
## Contributing
|
47
70
|
|
48
|
-
If you [create a plugin]
|
49
|
-
|
50
|
-
|
71
|
+
If you [create a plugin][], custom command, or hook you can share, please
|
72
|
+
[let me know][contact]. If I get a few plugin contributions, I'll set up a
|
73
|
+
second repository for them.
|
74
|
+
|
75
|
+
Feel free to fork [the repository][github] on GitHub and make pull requests
|
76
|
+
with changes. Please target the `develop` branch with pull requests.
|
77
|
+
|
78
|
+
[bt doing]: https://brettterpstra.com/projects/doing/
|
79
|
+
[donate]: http://brettterpstra.com/donate/
|
80
|
+
[github]: https://github.com/ttscoff/doing/
|
81
|
+
[wiki]: https://github.com/ttscoff/doing/wiki
|
82
|
+
[doing 2]: https://brettterpstra.com/2021/11/20/doing-2-dot-0/
|
83
|
+
[status bar]: https://brettterpstra.com/2021/10/15/see-what-youre-doing-in-the-iterm-status-bar/
|
84
|
+
[touch bar]: https://brettterpstra.com/2021/07/21/crazy-bettertouchtool-touch-bar-simulator/
|
85
|
+
[create a plugin]: https://github.com/ttscoff/doing/wiki/Creating-Plugins
|
86
|
+
[contact]: https://brettterpstra.com/contact/
|
87
|
+
[alfred workflow]: http://www.evanlovely.com/blog/technology/alfred-for-terpstras-doing/
|
51
88
|
|
52
89
|
|
53
90
|
|
data/doing.gemspec
CHANGED
@@ -41,6 +41,7 @@ spec = Gem::Specification.new do |s|
|
|
41
41
|
s.add_runtime_dependency('tty-which', '~> 0.5', '>= 0.5.0')
|
42
42
|
s.add_runtime_dependency('tty-markdown', '~> 0.7', '>= 0.7.0')
|
43
43
|
s.add_runtime_dependency('tty-reader', '~> 0.9', '>= 0.9.0')
|
44
|
+
s.add_runtime_dependency('tty-screen', '~> 0.8', '>= 0.8.1')
|
44
45
|
s.add_runtime_dependency('parslet', '~> 2.0', '>= 2.0.0')
|
45
46
|
s.add_runtime_dependency('plist', '~> 3.6', '>= 3.6.0')
|
46
47
|
# s.add_runtime_dependency('amatch', '~> 0.4', '>= 0.4.0')
|
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.18
|
9
9
|
|
10
10
|
=== Global Options
|
11
11
|
=== --config_file arg
|
@@ -528,10 +528,10 @@ Use this command to add an entry after you've already finished it. It will be im
|
|
528
528
|
You can modify the start and end times of the entry using the --back, --took, and --at flags, making it an easy
|
529
529
|
way to add entries in post and maintain accurate (albeit manual) time tracking.
|
530
530
|
===== Options
|
531
|
-
===== --at DATE_STRING
|
531
|
+
===== --at|--finished DATE_STRING
|
532
532
|
|
533
533
|
Set finish date to specific date/time (natural langauge parsed, e.g. --at=1:30pm).
|
534
|
-
|
534
|
+
Used with --took, backdates start date
|
535
535
|
|
536
536
|
[Default Value] None
|
537
537
|
|
@@ -543,6 +543,14 @@ Backdate start date by interval or set to time [4pm|20m|2h|"yesterday noon"]
|
|
543
543
|
[Default Value] None
|
544
544
|
|
545
545
|
|
546
|
+
===== --from TIME_RANGE
|
547
|
+
|
548
|
+
Start and end times as a date/time range `doing done --from "1am to 8am"`.
|
549
|
+
Overrides other date flags.
|
550
|
+
|
551
|
+
[Default Value] None
|
552
|
+
|
553
|
+
|
546
554
|
===== -n|--note TEXT
|
547
555
|
|
548
556
|
Include a note
|
@@ -557,7 +565,7 @@ Section
|
|
557
565
|
[Default Value] None
|
558
566
|
|
559
567
|
|
560
|
-
===== -t|--took INTERVAL
|
568
|
+
===== -t|--took|--for INTERVAL
|
561
569
|
|
562
570
|
Set completion date to start date plus interval (XX[mhd] or HH:MM).
|
563
571
|
If used without the --back option, the start date will be moved back to allow
|
@@ -645,7 +653,7 @@ Finish the last X entries matching search filter, surround with slashes for rege
|
|
645
653
|
[Default Value] None
|
646
654
|
|
647
655
|
|
648
|
-
===== -t|--took INTERVAL
|
656
|
+
===== -t|--took|--for INTERVAL
|
649
657
|
|
650
658
|
Set the completed date to the start date plus XX[hmd]
|
651
659
|
|
@@ -804,6 +812,11 @@ Edit matching entries with vim
|
|
804
812
|
|
805
813
|
|
806
814
|
|
815
|
+
===== -h|--[no-]hilite
|
816
|
+
Highlight search matches in output. Only affects command line output
|
817
|
+
|
818
|
+
|
819
|
+
|
807
820
|
===== -i|--interactive
|
808
821
|
Display an interactive menu of results to perform further operations
|
809
822
|
|
@@ -1006,6 +1019,11 @@ Edit entry with vim
|
|
1006
1019
|
|
1007
1020
|
|
1008
1021
|
|
1022
|
+
===== -h|--[no-]hilite
|
1023
|
+
Highlight search matches in output. Only affects command line output
|
1024
|
+
|
1025
|
+
|
1026
|
+
|
1009
1027
|
===== --not
|
1010
1028
|
Show items that *don't* match search string or tag filter
|
1011
1029
|
|
@@ -1274,7 +1292,9 @@ Record what you're starting now, or backdate the start time using natural langua
|
|
1274
1292
|
|
1275
1293
|
A parenthetical at the end of the entry will be converted to a note.
|
1276
1294
|
|
1277
|
-
Run
|
1295
|
+
Run without arguments to create a new entry interactively.
|
1296
|
+
|
1297
|
+
Run with --editor to create a new entry using vim.
|
1278
1298
|
===== Options
|
1279
1299
|
===== -b|--back|--started DATE_STRING
|
1280
1300
|
|
@@ -1898,6 +1918,11 @@ Show elapsed time on entries without @done tag
|
|
1898
1918
|
|
1899
1919
|
|
1900
1920
|
|
1921
|
+
===== -h|--[no-]hilite
|
1922
|
+
Highlight search matches in output. Only affects command line output
|
1923
|
+
|
1924
|
+
|
1925
|
+
|
1901
1926
|
===== -i|--interactive
|
1902
1927
|
Select from a menu of matching entries to perform additional operations
|
1903
1928
|
|
@@ -2458,6 +2483,11 @@ Show elapsed time on entries without @done tag
|
|
2458
2483
|
|
2459
2484
|
|
2460
2485
|
|
2486
|
+
===== -h|--[no-]hilite
|
2487
|
+
Highlight search matches in output. Only affects command line output
|
2488
|
+
|
2489
|
+
|
2490
|
+
|
2461
2491
|
===== -i|--interactive
|
2462
2492
|
Select from a menu of matching entries to perform additional operations
|
2463
2493
|
|
data/example_plugin.rb
CHANGED
@@ -152,11 +152,9 @@ module Doing
|
|
152
152
|
finished_at = i.end_date
|
153
153
|
took += finished_at.strftime('%A %B %e at %I:%M%p')
|
154
154
|
|
155
|
-
|
155
|
+
|
156
156
|
took += ' and it took'
|
157
|
-
took +=
|
158
|
-
took += " #{h.to_i} hours" if h.to_i.positive?
|
159
|
-
took += " #{m.to_i} minutes" if m.to_i.positive?
|
157
|
+
took += interval.time_string(format: :natural)
|
160
158
|
end
|
161
159
|
end
|
162
160
|
|
data/lib/completion/_doing.zsh
CHANGED
@@ -106,19 +106,19 @@ function _doing() {
|
|
106
106
|
args=( {-d,--dump}"[DEPRECATED]" {-u,--update}"[DEPRECATED]" )
|
107
107
|
;;
|
108
108
|
done)
|
109
|
-
args=( {-a,--archive}"[Immediately archive the entry]" "(--ask)--ask}[Prompt for note via multi-line input]" "(--
|
109
|
+
args=( {-a,--archive}"[Immediately archive the entry]" "(--ask)--ask}[Prompt for note via multi-line input]" "(--finished=)--finished=}[Set finish date to specific date/time]" "(--started=)--started=}[Backdate start date by interval or set to time [4pm|20m|2h|"yesterday noon"]]" "(--date)--date}[Include date]" {-e,--editor}"[Edit entry with vim]" "(--from=)--from=}[Start and end times as a date/time range `doing done --from "1am to 8am"`]" {-n,--note=}"[Include a note]" {-r,--remove}"[Remove @done tag]" {-s,--section=}"[Section]" "(--for=)--for=}[Set completion date to start date plus interval]" {-u,--unfinished}"[Finish last entry not already marked @done]" )
|
110
110
|
;;
|
111
111
|
did)
|
112
|
-
args=( {-a,--archive}"[Immediately archive the entry]" "(--ask)--ask}[Prompt for note via multi-line input]" "(--
|
112
|
+
args=( {-a,--archive}"[Immediately archive the entry]" "(--ask)--ask}[Prompt for note via multi-line input]" "(--finished=)--finished=}[Set finish date to specific date/time]" "(--started=)--started=}[Backdate start date by interval or set to time [4pm|20m|2h|"yesterday noon"]]" "(--date)--date}[Include date]" {-e,--editor}"[Edit entry with vim]" "(--from=)--from=}[Start and end times as a date/time range `doing done --from "1am to 8am"`]" {-n,--note=}"[Include a note]" {-r,--remove}"[Remove @done tag]" {-s,--section=}"[Section]" "(--for=)--for=}[Set completion date to start date plus interval]" {-u,--unfinished}"[Finish last entry not already marked @done]" )
|
113
113
|
;;
|
114
114
|
finish)
|
115
|
-
args=( {-a,--archive}"[Archive entries]" "(--at=)--at=}[Set finish date to specific date/time]" "(--auto)--auto}[Auto-generate finish dates from next entrys start times start time]" {-b,--back=}"[Backdate completed date to date string [4pm|20m|2h|yesterday noon]]" "(--bool=)--bool=}[Boolean]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" "(--date)--date}[Include date]" {-i,--interactive}"[Select item(s) to finish from a menu of matching entries]" "(--not)--not}[Finish items that *dont* match search/tag filterst* match search/tag filters]" {-r,--remove}"[Remove done tag]" {-s,--section=}"[Section]" "(--search=)--search=}[Finish the last X entries matching search filter]"
|
115
|
+
args=( {-a,--archive}"[Archive entries]" "(--at=)--at=}[Set finish date to specific date/time]" "(--auto)--auto}[Auto-generate finish dates from next entrys start times start time]" {-b,--back=}"[Backdate completed date to date string [4pm|20m|2h|yesterday noon]]" "(--bool=)--bool=}[Boolean]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" "(--date)--date}[Include date]" {-i,--interactive}"[Select item(s) to finish from a menu of matching entries]" "(--not)--not}[Finish items that *dont* match search/tag filterst* match search/tag filters]" {-r,--remove}"[Remove done tag]" {-s,--section=}"[Section]" "(--search=)--search=}[Finish the last X entries matching search filter]" "(--for=)--for=}[Set the completed date to the start date plus XX[hmd]]" "(--tag=)--tag=}[Finish the last X entries containing TAG]" {-u,--unfinished}"[Finish last entry]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
116
116
|
;;
|
117
117
|
grep)
|
118
|
-
args=( "(--after=)--after=}[Search entries newer than date]" "(--before=)--before=}[Search entries older than date]" "(--bool=)--bool=}[Combine multiple tags or value queries using AND]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-d,--delete}"[Delete matching entries]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" {-e,--editor}"[Edit matching entries with vim]" "(--from=)--from=}[Date range to show]" {-i,--interactive}"[Display an interactive menu of results to perform further operations]" "(--not)--not}[Show items that *dont* match search stringt* match search string]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--section=}"[Section]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact string matching]" )
|
118
|
+
args=( "(--after=)--after=}[Search entries newer than date]" "(--before=)--before=}[Search entries older than date]" "(--bool=)--bool=}[Combine multiple tags or value queries using AND]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-d,--delete}"[Delete matching entries]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" {-e,--editor}"[Edit matching entries with vim]" "(--from=)--from=}[Date range to show]" {-h,--hilite}"[Highlight search matches in output]" {-i,--interactive}"[Display an interactive menu of results to perform further operations]" "(--not)--not}[Show items that *dont* match search stringt* match search string]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--section=}"[Section]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact string matching]" )
|
119
119
|
;;
|
120
120
|
search)
|
121
|
-
args=( "(--after=)--after=}[Search entries newer than date]" "(--before=)--before=}[Search entries older than date]" "(--bool=)--bool=}[Combine multiple tags or value queries using AND]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-d,--delete}"[Delete matching entries]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" {-e,--editor}"[Edit matching entries with vim]" "(--from=)--from=}[Date range to show]" {-i,--interactive}"[Display an interactive menu of results to perform further operations]" "(--not)--not}[Show items that *dont* match search stringt* match search string]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--section=}"[Section]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact string matching]" )
|
121
|
+
args=( "(--after=)--after=}[Search entries newer than date]" "(--before=)--before=}[Search entries older than date]" "(--bool=)--bool=}[Combine multiple tags or value queries using AND]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-d,--delete}"[Delete matching entries]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" {-e,--editor}"[Edit matching entries with vim]" "(--from=)--from=}[Date range to show]" {-h,--hilite}"[Highlight search matches in output]" {-i,--interactive}"[Display an interactive menu of results to perform further operations]" "(--not)--not}[Show items that *dont* match search stringt* match search string]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--section=}"[Section]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact string matching]" )
|
122
122
|
;;
|
123
123
|
help)
|
124
124
|
args=( )
|
@@ -127,7 +127,7 @@ function _doing() {
|
|
127
127
|
args=( "(--after=)--after=}[Import entries newer than date]" "(--autotag)--autotag}[Autotag entries]" "(--before=)--before=}[Import entries older than date]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-f,--from=}"[Date range to import]" "(--not)--not}[Import items that *dont* match search/tag/date filterst* match search/tag/date filters]" "(--only_timed)--only_timed}[Only import items with recorded time intervals]" "(--overlap)--overlap}[Allow entries that overlap existing times]" "(--prefix=)--prefix=}[Prefix entries with]" {-s,--section=}"[Target section]" "(--search=)--search=}[Only import items matching search]" {-t,--tag=}"[Tag all imported entries]" "(--type=)--type=}[Import type]" {-x,--exact}"[Force exact search string matching]" )
|
128
128
|
;;
|
129
129
|
last)
|
130
|
-
args=( "(--bool=)--bool=}[Tag boolean]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-d,--delete}"[Delete the last entry]" "(--duration)--duration}[Show elapsed time if entry is not tagged @done]" {-e,--editor}"[Edit entry with vim]" "(--not)--not}[Show items that *dont* match search string or tag filtert* match search string or tag filter]" {-s,--section=}"[Specify a section]" "(--search=)--search=}[Search filter]" "(--tag=)--tag=}[Tag filter]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
130
|
+
args=( "(--bool=)--bool=}[Tag boolean]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-d,--delete}"[Delete the last entry]" "(--duration)--duration}[Show elapsed time if entry is not tagged @done]" {-e,--editor}"[Edit entry with vim]" {-h,--hilite}"[Highlight search matches in output]" "(--not)--not}[Show items that *dont* match search string or tag filtert* match search string or tag filter]" {-s,--section=}"[Specify a section]" "(--search=)--search=}[Search filter]" "(--tag=)--tag=}[Tag filter]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
131
131
|
;;
|
132
132
|
later)
|
133
133
|
args=( "(--ask)--ask}[Prompt for note via multi-line input]" {-b,--back=}"[Backdate start time to date string [4pm|20m|2h|yesterday noon]]" {-e,--editor}"[Edit entry with vim]" {-n,--note=}"[Note]" )
|
@@ -178,7 +178,7 @@ function _doing() {
|
|
178
178
|
args=( {-a,--archive}"[Archive selected items]" "(--after=)--after=}[Select from entries newer than date]" "(--resume)--resume}[Copy selection as a new entry with current time and no @done tag]" "(--before=)--before=}[Select from entries older than date]" {-c,--cancel}"[Cancel selected items]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" {-d,--delete}"[Delete selected items]" {-e,--editor}"[Edit selected item(s)]" {-f,--finish}"[Add @done with current time to selected item(s)]" "(--flag)--flag}[Add flag to selected item(s)]" "(--force)--force}[Perform action without confirmation]" "(--from=)--from=}[Date range to show]" {-m,--move=}"[Move selected items to section]" "(--menu)--menu}[Use --no-menu to skip the interactive menu]" "(--not)--not}[Select items that *dont* match search/tag filterst* match search/tag filters]" {-o,--output=}"[Output entries to format]" {-q,--query=}"[Initial search query for filtering]" {-r,--remove}"[Reverse -c]" {-s,--section=}"[Select from a specific section]" "(--save_to=)--save_to=}[Save selected entries to file using --output format]" "(--search=)--search=}[Select from entries matching search filter]" {-t,--tag=}"[Tag selected entries]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
179
179
|
;;
|
180
180
|
show)
|
181
|
-
args=( {-a,--age=}"[Age]" "(--after=)--after=}[Show entries newer than date]" {-b,--bool=}"[Tag boolean]" "(--before=)--before=}[Show entries older than date]" {-c,--count=}"[Max count to show]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" "(--from=)--from=}[Date range to show]" {-i,--interactive}"[Select from a menu of matching entries to perform additional operations]" {-m,--menu}"[Select section or tag to display from a menu]" "(--not)--not}[Show items that *dont* match search/tag/date filterst* match search/tag/date filters]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--sort=}"[Sort order]" "(--search=)--search=}[Search filter]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag=)--tag=}[Tag filter]" "(--tag_order=)--tag_order=}[Tag sort direction]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
181
|
+
args=( {-a,--age=}"[Age]" "(--after=)--after=}[Show entries newer than date]" {-b,--bool=}"[Tag boolean]" "(--before=)--before=}[Show entries older than date]" {-c,--count=}"[Max count to show]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" "(--from=)--from=}[Date range to show]" {-h,--hilite}"[Highlight search matches in output]" {-i,--interactive}"[Select from a menu of matching entries to perform additional operations]" {-m,--menu}"[Select section or tag to display from a menu]" "(--not)--not}[Show items that *dont* match search/tag/date filterst* match search/tag/date filters]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--sort=}"[Sort order]" "(--search=)--search=}[Search filter]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag=)--tag=}[Tag filter]" "(--tag_order=)--tag_order=}[Tag sort direction]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
182
182
|
;;
|
183
183
|
since)
|
184
184
|
args=( "(--duration)--duration}[Show elapsed time on entries without @done tag]" {-o,--output=}"[Output to export format]" {-s,--section=}"[Section]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show time totals at the end of output]" )
|
@@ -205,7 +205,7 @@ function _doing() {
|
|
205
205
|
args=( {-f,--file=}"[Specify alternate doing file]" {-i,--interactive}"[Select from recent backups]" {-p,--prune=}"[Remove old backups]" {-r,--redo}"[Redo last undo]" )
|
206
206
|
;;
|
207
207
|
view)
|
208
|
-
args=( "(--after=)--after=}[View entries newer than date]" "(--age=)--age=}[Age]" {-b,--bool=}"[Tag boolean]" "(--before=)--before=}[View entries older than date]" {-c,--count=}"[Count to display]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" "(--color)--color}[Include colors in output]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" "(--from=)--from=}[Date range to show]" {-i,--interactive}"[Select from a menu of matching entries to perform additional operations]" "(--not)--not}[Show items that *dont* match search stringt* match search string]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--section=}"[Section]" "(--search=)--search=}[Search filter]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag=)--tag=}[Tag filter]" "(--tag_order=)--tag_order=}[Tag sort direction]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
208
|
+
args=( "(--after=)--after=}[View entries newer than date]" "(--age=)--age=}[Age]" {-b,--bool=}"[Tag boolean]" "(--before=)--before=}[View entries older than date]" {-c,--count=}"[Count to display]" "(--case=)--case=}[Case sensitivity for search string matching [(c)ase-sensitive]" "(--color)--color}[Include colors in output]" "(--duration)--duration}[Show elapsed time on entries without @done tag]" "(--from=)--from=}[Date range to show]" {-h,--hilite}"[Highlight search matches in output]" {-i,--interactive}"[Select from a menu of matching entries to perform additional operations]" "(--not)--not}[Show items that *dont* match search stringt* match search string]" {-o,--output=}"[Output to export format]" "(--only_timed)--only_timed}[Only show items with recorded time intervals]" {-s,--section=}"[Section]" "(--search=)--search=}[Search filter]" {-t,--times}"[Show time intervals on @done tasks]" "(--tag=)--tag=}[Tag filter]" "(--tag_order=)--tag_order=}[Tag sort direction]" "(--tag_sort=)--tag_sort=}[Sort tags by]" "(--totals)--totals}[Show intervals with totals at the end of output]" "(--val=)--val=}[Perform a tag value query]" {-x,--exact}"[Force exact search string matching]" )
|
209
209
|
;;
|
210
210
|
views)
|
211
211
|
args=( {-c,--column}"[List in single column]" )
|
data/lib/completion/doing.bash
CHANGED
@@ -81,9 +81,9 @@ _doing_config() {
|
|
81
81
|
_doing_done() {
|
82
82
|
|
83
83
|
if [[ "$token" == --* ]]; then
|
84
|
-
COMPREPLY=( $( compgen -W '--archive --ask --
|
84
|
+
COMPREPLY=( $( compgen -W '--archive --ask --finished --started --date --editor --from --note --remove --section --for --unfinished' -- $token ) )
|
85
85
|
elif [[ "$token" == -* ]]; then
|
86
|
-
COMPREPLY=( $( compgen -W '-a -e -n -r -s -
|
86
|
+
COMPREPLY=( $( compgen -W '-a -e -n -r -s -u --archive --ask --finished --started --date --editor --from --note --remove --section --for --unfinished' -- $token ) )
|
87
87
|
|
88
88
|
fi
|
89
89
|
}
|
@@ -91,9 +91,9 @@ _doing_done() {
|
|
91
91
|
_doing_finish() {
|
92
92
|
|
93
93
|
if [[ "$token" == --* ]]; then
|
94
|
-
COMPREPLY=( $( compgen -W '--archive --at --auto --back --bool --case --date --interactive --not --remove --section --search --
|
94
|
+
COMPREPLY=( $( compgen -W '--archive --at --auto --back --bool --case --date --interactive --not --remove --section --search --for --tag --unfinished --val --exact' -- $token ) )
|
95
95
|
elif [[ "$token" == -* ]]; then
|
96
|
-
COMPREPLY=( $( compgen -W '-a -b -i -r -s -
|
96
|
+
COMPREPLY=( $( compgen -W '-a -b -i -r -s -u -x --archive --at --auto --back --bool --case --date --interactive --not --remove --section --search --for --tag --unfinished --val --exact' -- $token ) )
|
97
97
|
|
98
98
|
fi
|
99
99
|
}
|
@@ -101,9 +101,9 @@ _doing_finish() {
|
|
101
101
|
_doing_grep() {
|
102
102
|
|
103
103
|
if [[ "$token" == --* ]]; then
|
104
|
-
COMPREPLY=( $( compgen -W '--after --before --bool --case --delete --duration --editor --from --interactive --not --output --only_timed --section --times --tag_sort --totals --val --exact' -- $token ) )
|
104
|
+
COMPREPLY=( $( compgen -W '--after --before --bool --case --delete --duration --editor --from --hilite --interactive --not --output --only_timed --section --times --tag_sort --totals --val --exact' -- $token ) )
|
105
105
|
elif [[ "$token" == -* ]]; then
|
106
|
-
COMPREPLY=( $( compgen -W '-d -e -i -o -s -t -x --after --before --bool --case --delete --duration --editor --from --interactive --not --output --only_timed --section --times --tag_sort --totals --val --exact' -- $token ) )
|
106
|
+
COMPREPLY=( $( compgen -W '-d -e -h -i -o -s -t -x --after --before --bool --case --delete --duration --editor --from --hilite --interactive --not --output --only_timed --section --times --tag_sort --totals --val --exact' -- $token ) )
|
107
107
|
|
108
108
|
fi
|
109
109
|
}
|
@@ -131,9 +131,9 @@ _doing_import() {
|
|
131
131
|
_doing_last() {
|
132
132
|
|
133
133
|
if [[ "$token" == --* ]]; then
|
134
|
-
COMPREPLY=( $( compgen -W '--bool --case --delete --duration --editor --not --section --search --tag --val --exact' -- $token ) )
|
134
|
+
COMPREPLY=( $( compgen -W '--bool --case --delete --duration --editor --hilite --not --section --search --tag --val --exact' -- $token ) )
|
135
135
|
elif [[ "$token" == -* ]]; then
|
136
|
-
COMPREPLY=( $( compgen -W '-d -e -s -x --bool --case --delete --duration --editor --not --section --search --tag --val --exact' -- $token ) )
|
136
|
+
COMPREPLY=( $( compgen -W '-d -e -h -s -x --bool --case --delete --duration --editor --hilite --not --section --search --tag --val --exact' -- $token ) )
|
137
137
|
|
138
138
|
fi
|
139
139
|
}
|
@@ -276,9 +276,9 @@ local words=$(doing sections)
|
|
276
276
|
IFS="$OLD_IFS"
|
277
277
|
|
278
278
|
if [[ "$token" == --* ]]; then
|
279
|
-
COMPREPLY=( $( compgen -W '--age --after --bool --before --count --case --duration --from --interactive --menu --not --output --only_timed --sort --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
279
|
+
COMPREPLY=( $( compgen -W '--age --after --bool --before --count --case --duration --from --hilite --interactive --menu --not --output --only_timed --sort --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
280
280
|
elif [[ "$token" == -* ]]; then
|
281
|
-
COMPREPLY=( $( compgen -W '-a -b -c -i -m -o -s -t -x --age --after --bool --before --count --case --duration --from --interactive --menu --not --output --only_timed --sort --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
281
|
+
COMPREPLY=( $( compgen -W '-a -b -c -h -i -m -o -s -t -x --age --after --bool --before --count --case --duration --from --hilite --interactive --menu --not --output --only_timed --sort --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
282
282
|
else
|
283
283
|
local nocasematchWasOff=0
|
284
284
|
shopt nocasematch >/dev/null || nocasematchWasOff=1
|
@@ -376,9 +376,9 @@ local words=$(doing views)
|
|
376
376
|
IFS="$OLD_IFS"
|
377
377
|
|
378
378
|
if [[ "$token" == --* ]]; then
|
379
|
-
COMPREPLY=( $( compgen -W '--after --age --bool --before --count --case --color --duration --from --interactive --not --output --only_timed --section --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
379
|
+
COMPREPLY=( $( compgen -W '--after --age --bool --before --count --case --color --duration --from --hilite --interactive --not --output --only_timed --section --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
380
380
|
elif [[ "$token" == -* ]]; then
|
381
|
-
COMPREPLY=( $( compgen -W '-b -c -i -o -s -t -x --after --age --bool --before --count --case --color --duration --from --interactive --not --output --only_timed --section --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
381
|
+
COMPREPLY=( $( compgen -W '-b -c -h -i -o -s -t -x --after --age --bool --before --count --case --color --duration --from --hilite --interactive --not --output --only_timed --section --search --times --tag --tag_order --tag_sort --totals --val --exact' -- $token ) )
|
382
382
|
else
|
383
383
|
local nocasematchWasOff=0
|
384
384
|
shopt nocasematch >/dev/null || nocasematchWasOff=1
|
data/lib/completion/doing.fish
CHANGED
@@ -148,14 +148,15 @@ complete -c doing -l dump -s d -f -n '__fish_doing_using_command config' -d DEP
|
|
148
148
|
complete -c doing -l update -s u -f -n '__fish_doing_using_command config' -d DEPRECATED
|
149
149
|
complete -c doing -l archive -s a -f -n '__fish_doing_using_command done did' -d Immediately\ archive\ the\ entry
|
150
150
|
complete -c doing -l ask -f -n '__fish_doing_using_command done did' -d Prompt\ for\ note\ via\ multi-line\ input
|
151
|
-
complete -c doing -l
|
151
|
+
complete -c doing -l finished -f -r -n '__fish_doing_using_command done did' -d Set\ finish\ date\ to\ specific\ date/time
|
152
152
|
complete -c doing -l started -f -r -n '__fish_doing_using_command done did' -d Backdate\ start\ date\ by\ interval\ or\ set\ to\ time\ \[4pm\|20m\|2h\|\"yesterday\ noon\"\]
|
153
153
|
complete -c doing -l date -f -n '__fish_doing_using_command done did' -d Include\ date
|
154
154
|
complete -c doing -l editor -s e -f -n '__fish_doing_using_command done did' -d Edit\ entry\ with\ vim
|
155
|
+
complete -c doing -l from -f -r -n '__fish_doing_using_command done did' -d Start\ and\ end\ times\ as\ a\ date/time\ range\ \`doing\ done\ --from\ \"1am\ to\ 8am\"\`
|
155
156
|
complete -c doing -l note -s n -f -r -n '__fish_doing_using_command done did' -d Include\ a\ note
|
156
157
|
complete -c doing -l remove -s r -f -n '__fish_doing_using_command done did' -d Remove\ @done\ tag
|
157
158
|
complete -c doing -l section -s s -f -r -n '__fish_doing_using_command done did' -d Section
|
158
|
-
complete -c doing -l
|
159
|
+
complete -c doing -l for -f -r -n '__fish_doing_using_command done did' -d Set\ completion\ date\ to\ start\ date\ plus\ interval
|
159
160
|
complete -c doing -l unfinished -s u -f -n '__fish_doing_using_command done did' -d Finish\ last\ entry\ not\ already\ marked\ @done
|
160
161
|
complete -c doing -l archive -s a -f -n '__fish_doing_using_command finish' -d Archive\ entries
|
161
162
|
complete -c doing -l at -f -r -n '__fish_doing_using_command finish' -d Set\ finish\ date\ to\ specific\ date/time
|
@@ -169,7 +170,7 @@ complete -c doing -l not -f -n '__fish_doing_using_command finish' -d Finish\
|
|
169
170
|
complete -c doing -l remove -s r -f -n '__fish_doing_using_command finish' -d Remove\ done\ tag
|
170
171
|
complete -c doing -l section -s s -f -r -n '__fish_doing_using_command finish' -d Section
|
171
172
|
complete -c doing -l search -f -r -n '__fish_doing_using_command finish' -d Finish\ the\ last\ X\ entries\ matching\ search\ filter
|
172
|
-
complete -c doing -l
|
173
|
+
complete -c doing -l for -f -r -n '__fish_doing_using_command finish' -d Set\ the\ completed\ date\ to\ the\ start\ date\ plus\ XX\[hmd\]
|
173
174
|
complete -c doing -l tag -f -r -n '__fish_doing_using_command finish' -d Finish\ the\ last\ X\ entries\ containing\ TAG
|
174
175
|
complete -c doing -l unfinished -s u -f -n '__fish_doing_using_command finish' -d Finish\ last\ entry
|
175
176
|
complete -c doing -l val -f -r -n '__fish_doing_using_command finish' -d Perform\ a\ tag\ value\ query
|
@@ -182,6 +183,7 @@ complete -c doing -l delete -s d -f -n '__fish_doing_using_command grep search'
|
|
182
183
|
complete -c doing -l duration -f -n '__fish_doing_using_command grep search' -d Show\ elapsed\ time\ on\ entries\ without\ @done\ tag
|
183
184
|
complete -c doing -l editor -s e -f -n '__fish_doing_using_command grep search' -d Edit\ matching\ entries\ with\ vim
|
184
185
|
complete -c doing -l from -f -r -n '__fish_doing_using_command grep search' -d Date\ range\ to\ show
|
186
|
+
complete -c doing -l hilite -s h -f -n '__fish_doing_using_command grep search' -d Highlight\ search\ matches\ in\ output
|
185
187
|
complete -c doing -l interactive -s i -f -n '__fish_doing_using_command grep search' -d Display\ an\ interactive\ menu\ of\ results\ to\ perform\ further\ operations
|
186
188
|
complete -c doing -l not -f -n '__fish_doing_using_command grep search' -d Show\ items\ that\ \*don\'t\*\ match\ search\ string
|
187
189
|
complete -c doing -l output -s o -f -r -n '__fish_doing_using_command grep search' -d Output\ to\ export\ format
|
@@ -212,6 +214,7 @@ complete -c doing -l case -f -r -n '__fish_doing_using_command last' -d Case\ s
|
|
212
214
|
complete -c doing -l delete -s d -f -n '__fish_doing_using_command last' -d Delete\ the\ last\ entry
|
213
215
|
complete -c doing -l duration -f -n '__fish_doing_using_command last' -d Show\ elapsed\ time\ if\ entry\ is\ not\ tagged\ @done
|
214
216
|
complete -c doing -l editor -s e -f -n '__fish_doing_using_command last' -d Edit\ entry\ with\ vim
|
217
|
+
complete -c doing -l hilite -s h -f -n '__fish_doing_using_command last' -d Highlight\ search\ matches\ in\ output
|
215
218
|
complete -c doing -l not -f -n '__fish_doing_using_command last' -d Show\ items\ that\ \*don\'t\*\ match\ search\ string\ or\ tag\ filter
|
216
219
|
complete -c doing -l section -s s -f -r -n '__fish_doing_using_command last' -d Specify\ a\ section
|
217
220
|
complete -c doing -l search -f -r -n '__fish_doing_using_command last' -d Search\ filter
|
@@ -330,6 +333,7 @@ complete -c doing -l count -s c -f -r -n '__fish_doing_using_command show' -d Ma
|
|
330
333
|
complete -c doing -l case -f -r -n '__fish_doing_using_command show' -d Case\ sensitivity\ for\ search\ string\ matching\ \[\(c\)ase-sensitive
|
331
334
|
complete -c doing -l duration -f -n '__fish_doing_using_command show' -d Show\ elapsed\ time\ on\ entries\ without\ @done\ tag
|
332
335
|
complete -c doing -l from -f -r -n '__fish_doing_using_command show' -d Date\ range\ to\ show
|
336
|
+
complete -c doing -l hilite -s h -f -n '__fish_doing_using_command show' -d Highlight\ search\ matches\ in\ output
|
333
337
|
complete -c doing -l interactive -s i -f -n '__fish_doing_using_command show' -d Select\ from\ a\ menu\ of\ matching\ entries\ to\ perform\ additional\ operations
|
334
338
|
complete -c doing -l menu -s m -f -n '__fish_doing_using_command show' -d Select\ section\ or\ tag\ to\ display\ from\ a\ menu
|
335
339
|
complete -c doing -l not -f -n '__fish_doing_using_command show' -d Show\ items\ that\ \*don\'t\*\ match\ search/tag/date\ filters
|
@@ -407,6 +411,7 @@ complete -c doing -l case -f -r -n '__fish_doing_using_command view' -d Case\ s
|
|
407
411
|
complete -c doing -l color -f -n '__fish_doing_using_command view' -d Include\ colors\ in\ output
|
408
412
|
complete -c doing -l duration -f -n '__fish_doing_using_command view' -d Show\ elapsed\ time\ on\ entries\ without\ @done\ tag
|
409
413
|
complete -c doing -l from -f -r -n '__fish_doing_using_command view' -d Date\ range\ to\ show
|
414
|
+
complete -c doing -l hilite -s h -f -n '__fish_doing_using_command view' -d Highlight\ search\ matches\ in\ output
|
410
415
|
complete -c doing -l interactive -s i -f -n '__fish_doing_using_command view' -d Select\ from\ a\ menu\ of\ matching\ entries\ to\ perform\ additional\ operations
|
411
416
|
complete -c doing -l not -f -n '__fish_doing_using_command view' -d Show\ items\ that\ \*don\'t\*\ match\ search\ string
|
412
417
|
complete -c doing -l output -s o -f -r -n '__fish_doing_using_command view' -d Output\ to\ export\ format
|
@@ -0,0 +1,57 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Doing
|
4
|
+
# Chronify array helpers
|
5
|
+
class ::Array
|
6
|
+
##
|
7
|
+
## Format [d, h, m] as string
|
8
|
+
##
|
9
|
+
## @param time [Array] Array of [days, hours,
|
10
|
+
## minutes]
|
11
|
+
## @param format [Symbol] The format, :dhm, :hm, :m, :clock, :natural
|
12
|
+
## @return [String] formatted string
|
13
|
+
##
|
14
|
+
def time_string(format: :dhm)
|
15
|
+
raise InvalidArgument, 'Invalid array, must be [d,h,m]' unless count == 3
|
16
|
+
|
17
|
+
d, h, m = self
|
18
|
+
case format
|
19
|
+
when :clock
|
20
|
+
format('%<d>02d:%<h>02d:%<m>02d', d: d, h: h, m: m)
|
21
|
+
when :dhm
|
22
|
+
output = []
|
23
|
+
output.push(format('%<d>dd', d: d)) if d.positive?
|
24
|
+
output.push(format('%<h>dh', h: h)) if h.positive?
|
25
|
+
output.push(format('%<m>dm', m: m)) if m.positive?
|
26
|
+
output.join(' ')
|
27
|
+
when :hm
|
28
|
+
h += d * 24 if d.positive?
|
29
|
+
format('%<h> 4dh %<m>02dm', h: h, m: m)
|
30
|
+
when :m
|
31
|
+
h += d * 24 if d.positive?
|
32
|
+
m += h * 60 if h.positive?
|
33
|
+
format('%<m> 4dm', m: m)
|
34
|
+
when :natural
|
35
|
+
human = []
|
36
|
+
human.push(format('%<d>d %<s>s', d: d, s: 'day'.to_p(d))) if d.positive?
|
37
|
+
human.push(format('%<h>d %<s>s', h: h, s: 'hour'.to_p(h))) if h.positive?
|
38
|
+
human.push(format('%<m>d %<s>s', m: m, s: 'minute'.to_p(m))) if m.positive?
|
39
|
+
human.join(', ')
|
40
|
+
when :speech
|
41
|
+
human = []
|
42
|
+
human.push(format('%<d>d %<s>s', d: d, s: 'day'.to_p(d))) if d.positive?
|
43
|
+
human.push(format('%<h>d %<s>s', h: h, s: 'hour'.to_p(h))) if h.positive?
|
44
|
+
human.push(format('%<m>d %<s>s', m: m, s: 'minute'.to_p(m))) if m.positive?
|
45
|
+
last = human.pop
|
46
|
+
case human.count
|
47
|
+
when 2
|
48
|
+
human.join(', ') + ", and #{last}"
|
49
|
+
when 1
|
50
|
+
"#{human[0]} and #{last}"
|
51
|
+
when 0
|
52
|
+
last
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
data/lib/doing/colors.rb
CHANGED
@@ -24,6 +24,7 @@ module Doing
|
|
24
24
|
[:yellow, 33],
|
25
25
|
[:blue, 34],
|
26
26
|
[:magenta, 35],
|
27
|
+
[:purple, 35],
|
27
28
|
[:cyan, 36],
|
28
29
|
[:white, 37],
|
29
30
|
[:bgblack, 40],
|
@@ -32,6 +33,7 @@ module Doing
|
|
32
33
|
[:bgyellow, 43],
|
33
34
|
[:bgblue, 44],
|
34
35
|
[:bgmagenta, 45],
|
36
|
+
[:bgpurple, 45],
|
35
37
|
[:bgcyan, 46],
|
36
38
|
[:bgwhite, 47],
|
37
39
|
[:boldblack, 90], # High intensity, aixterm (works in OS X)
|
@@ -40,6 +42,7 @@ module Doing
|
|
40
42
|
[:boldyellow, 93],
|
41
43
|
[:boldblue, 94],
|
42
44
|
[:boldmagenta, 95],
|
45
|
+
[:boldpurple, 95],
|
43
46
|
[:boldcyan, 96],
|
44
47
|
[:boldwhite, 97],
|
45
48
|
[:boldbgblack, 100], # High intensity background, aixterm (works in OS X)
|
@@ -48,6 +51,7 @@ module Doing
|
|
48
51
|
[:boldbgyellow, 103],
|
49
52
|
[:boldbgblue, 104],
|
50
53
|
[:boldbgmagenta, 105],
|
54
|
+
[:boldbgpurple, 105],
|
51
55
|
[:boldbgcyan, 106],
|
52
56
|
[:boldbgwhite, 107],
|
53
57
|
[:softpurple, '0;35;40'],
|
data/lib/doing/configuration.rb
CHANGED
@@ -99,9 +99,13 @@ module Doing
|
|
99
99
|
'search' => {
|
100
100
|
'matching' => 'pattern', # fuzzy, pattern, exact
|
101
101
|
'distance' => 3,
|
102
|
-
'case' => 'smart' # sensitive, ignore, smart
|
102
|
+
'case' => 'smart', # sensitive, ignore, smart
|
103
|
+
'highlight' => false
|
103
104
|
},
|
104
|
-
'include_notes' => true
|
105
|
+
'include_notes' => true,
|
106
|
+
'interaction' => {
|
107
|
+
'confirm_longer_than' => '5h'
|
108
|
+
}
|
105
109
|
}
|
106
110
|
|
107
111
|
def initialize(file = nil, options: {})
|