mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-06-26 10:54:28 +02:00
96 lines
2.8 KiB
Text
96 lines
2.8 KiB
Text
Use Cases
|
||
=========
|
||
|
||
Basic usage summary:
|
||
|
||
$ timew start tag1 # Start tracking now
|
||
$ timew start "Home Improvement Project" # Stop old interval, start new interval now
|
||
$ timew stop # Stop all tracking
|
||
$ timew report month # Run report 'month'
|
||
|
||
If a time is specified, it always means today:
|
||
|
||
$ timew track 8am - 10am tag1
|
||
|
||
If days are specified, they always mean the past:
|
||
|
||
$ timew track mon - wed tag1
|
||
|
||
If today is thursday, the following covers the curent week because the previous
|
||
monday would be after the previous friday, therefore the friday refers to the
|
||
next friday, at EOW:
|
||
|
||
$ timew track mon - fri tag1
|
||
|
||
If overlapping intervals are permitted (configuration: interval.overlap=yes),
|
||
then this creates overlapping intervals:
|
||
|
||
1 $ timew start tag1
|
||
...
|
||
2 $ timew start tag2
|
||
...
|
||
3 $ timew stop tag1
|
||
...
|
||
4 $ timew stop tag2
|
||
|
||
With overlapping intervals:
|
||
o-------o tag1
|
||
o--------o tag2
|
||
1--2----3---4---> time
|
||
|
||
Track time but backfill to the most recent interval end:
|
||
|
||
$ timew track fill tag1
|
||
|
||
Record yesterday's time:
|
||
|
||
$ timew track yesterday tag1
|
||
|
||
Defining Exclusions:
|
||
|
||
$ timew define holidays eng-USA
|
||
$ timew define holidays work 2015-11-26
|
||
$ timew define workweek mon-fri
|
||
$ timew define workday start 8:30am
|
||
$ timew define workday end 1730
|
||
$ timew define workday tue end 3pm
|
||
|
||
The above examples simply use ad-hoc tags, which is an undefined tag. They are
|
||
simply used as tags, and have no metadata. Defining a tag allows it to have
|
||
associated metadata:
|
||
|
||
$ timew define tag "tag1"
|
||
$ timew define tag "tag1" description "Description of tag1"
|
||
$ timew define tag "tag1" start 2016-01-01
|
||
$ timew define tag "tag1" end 2016-06-30
|
||
$ timew define tag "tag1" budget 20 hours per week
|
||
$ timew define tag "tag1" budget 400 hours total
|
||
$ timew define tag "tag1" overlap
|
||
|
||
---
|
||
|
||
P: So the first six lines of examples show timew in use without any exclusions. That just turns it into a stopwatch.
|
||
F: yes.
|
||
P: But when you add exclusions, you get to say “timew track monday tag1” and it does something less than 24 hours.
|
||
You also get to use fill.
|
||
F: Right.
|
||
|
||
|
||
F: I like the rules for days.
|
||
Referring to the past.
|
||
P: Yes, I think that makes sense.
|
||
F: Do we want to have “modifiers” for this?
|
||
P: How so?
|
||
F: timew track last week mon - wed tag1
|
||
or
|
||
timew track mon - wed last week tag1
|
||
P: Yes, we do, but I would prefer this:
|
||
timew track last week monday - last week wednesday tag1
|
||
F: Yes.
|
||
P: Maybe we’ll find a better way to do this, but we need to be able to do all kinds of weird things with dates:
|
||
last monday, this monday, next monday, monday
|
||
F: Would this here ever happen?
|
||
timew track last week tag1
|
||
P: yes
|
||
That’s an auto-fill if you have exclusions.
|
||
F: tag1 = vacation on the island
|