Adding metadata information

Adding extra information to your tracked time.

In the previous section you added enhanced your time tracking with tags to categorize your intervals.

However, you already have tracked some time before without tags (those with IDs @4, @5, and @6):

$ timew summary :ids

^[[4mWk^[[0m ^[[4mDate      ^[[0m ^[[4mDay^[[0m ^[[4mID^[[0m ^[[4mTags         ^[[0m ^[[4m   Start^[[0m ^[[4m     End^[[0m ^[[4m   Time^[[0m ^[[4m  Total^[[0m
W8 2025-02-23 Sun @6                8:05:21  8:22:56 0:17:35
                  @5                8:31:07  9:20:02 0:48:55
                  @4                9:23:00  9:54:28 0:31:28
                  @3 CLIENT        11:02:13 11:14:56 0:12:43
                  @2 CLIENT, PHONE 11:14:56 11:19:22 0:04:26
                  @1 CLIENT        11:19:22 11:34:07 0:14:45 2:09:52
                                                             ^[[4m       ^[[0m
                                                             2:09:52

$ ▒

How can you add tags to those intervals?

To add tags to those intervals, you can use the tag command, which accepts one or more tags and one or more interval IDs:

$ timew tag @4 @5 @6 PREPARATION HOME
Note: 'HOME' is a new tag.
Note: 'PREPARATION' is a new tag.
Added HOME PREPARATION to @6
Added HOME PREPARATION to @5
Added HOME PREPARATION to @4
$ ▒

Now you have added tags PREPARATION and HOME and your tracked time looks like this:

$ timew summary :ids

^[[4mWk^[[0m ^[[4mDate      ^[[0m ^[[4mDay^[[0m ^[[4mID^[[0m ^[[4mTags             ^[[0m ^[[4m   Start^[[0m ^[[4m     End^[[0m ^[[4m   Time^[[0m ^[[4m  Total^[[0m
W8 2025-02-23 Sun @6 HOME, PREPARATION  8:05:21  8:22:56 0:17:35
                  @5 HOME, PREPARATION  8:31:07  9:20:02 0:48:55
                  @4 HOME, PREPARATION  9:23:00  9:54:28 0:31:28
                  @3 CLIENT            11:02:13 11:14:56 0:12:43
                  @2 CLIENT, PHONE     11:14:56 11:19:22 0:04:26
                  @1 CLIENT            11:19:22 11:34:07 0:14:45 2:09:52
                                                                 ^[[4m       ^[[0m
                                                                 2:09:52

$ ▒

But wait, PREPARATION should go only to @5, and HOME should go only to @4, and @6 should have a completely different tag set. How can you correct this?

You can remove tags from intervals with the untag command. Similar to the tag command, it accepts one or more tags and one or more interval IDs. So, let’s remove the unwanted tags from intervals @4 and @5:

$ timew untag @5 HOME
Removed HOME from @5
$ timew untag @4 PREPARATION
Removed PREPARATION from @4
$ ▒

With that your tracked time looks like this:

$ timew summary :ids

^[[4mWk^[[0m ^[[4mDate      ^[[0m ^[[4mDay^[[0m ^[[4mID^[[0m ^[[4mTags             ^[[0m ^[[4m   Start^[[0m ^[[4m     End^[[0m ^[[4m   Time^[[0m ^[[4m  Total^[[0m
W8 2025-02-23 Sun @6 HOME, PREPARATION  8:05:21  8:22:56 0:17:35
                  @5 PREPARATION        8:31:07  9:20:02 0:48:55
                  @4 HOME               9:23:00  9:54:28 0:31:28
                  @3 CLIENT            11:02:13 11:14:56 0:12:43
                  @2 CLIENT, PHONE     11:14:56 11:19:22 0:04:26
                  @1 CLIENT            11:19:22 11:34:07 0:14:45 2:09:52
                                                                 ^[[4m       ^[[0m
                                                                 2:09:52

$ ▒

We could now use the untag command to remove the tags from interval @6 and then add the correct ones, but there is a more efficient way with the retag command.

While tag and untag only add or remove the given tags, retag replaces the complete tag set of an interval with the given ones.

$ timew retag @6 SPORT
Note: 'SPORT' is a new tag.
Retagged @6 as SPORT
$ ▒

When you now review your tracked time, all intervals have tags:

$ timew summary :ids

^[[4mWk^[[0m ^[[4mDate      ^[[0m ^[[4mDay^[[0m ^[[4mID^[[0m ^[[4mTags         ^[[0m ^[[4m   Start^[[0m ^[[4m     End^[[0m ^[[4m   Time^[[0m ^[[4m  Total^[[0m
W8 2025-02-23 Sun @6 SPORT          8:05:21  8:22:56 0:17:35
                  @5 PREPARATION    8:31:07  9:20:02 0:48:55
                  @4 HOME           9:23:00  9:54:28 0:31:28
                  @3 CLIENT        11:02:13 11:14:56 0:12:43
                  @2 CLIENT, PHONE 11:14:56 11:19:22 0:04:26
                  @1 CLIENT        11:19:22 11:34:07 0:14:45 2:09:52
                                                             ^[[4m       ^[[0m
                                                             2:09:52

$ ▒

Now that your tracked time has more information, you now notice that there is a gap between the intervals with ID @3 and @4, where you forgot to track time. Is there a way to correct this?

In the next section, you will see how you can use time information to fix this – and how use them for more precise time tracking.

Or you return to the Tutorial section and pick another topic of interest.