11# hours
22
3- ✨ Overview
4- ---
3+ ` hours ` is a no-frills time tracking toolkit for the command line.
4+
5+ It's designed for users who want basic time tracking for their tasks/projects
6+ right in the terminal. With a simple and minimalistic UI, almost everything in
7+ ` hours ` can be achieved with one or two keypresses. It can also generate
8+ plaintext reports, summary statistics, and logs based on time tracked.
9+
10+ ![ Usage] ( https://tools.dhruvs.space/images/hours/hours.gif )
511
6- ` hours ` is a no-frills command-line app for tracking time on tasks. It's
7- designed for users who want basic time tracking for their tasks/projects, right
8- in the terminal. With a simple and minimalistic UI, almost everything in ` hours `
9- can be achieved with one or two keypresses. It can also generate plaintext
10- reports, summary statistics, and logs based on time tracked.
12+ [ Link to Video] [ 2 ]
1113
1214🤔 Motivation
1315---
@@ -22,6 +24,12 @@ precisely fit these needs, so I decided to build one for myself.
2224💾 Install
2325---
2426
27+ ** homebrew** :
28+
29+ ``` sh
30+ brew install dhth/tap/hours
31+ ```
32+
2533** go** :
2634
2735``` sh
@@ -31,6 +39,8 @@ go install github.com/dhth/hours@latest
3139⚡️ Usage
3240---
3341
42+ ### TUI
43+
3444Open the TUI by simply running ` hours ` . The TUI lets you do the following:
3545
3646- create/update tasks
@@ -39,125 +49,93 @@ Open the TUI by simply running `hours`. The TUI lets you do the following:
3949- deactivate/activate a task
4050- view historical task log entries
4151
52+ ![ Usage] ( https://tools.dhruvs.space/images/hours/tui-1.png )
53+
54+ ![ Usage] ( https://tools.dhruvs.space/images/hours/tui-2.png )
55+
56+ ![ Usage] ( https://tools.dhruvs.space/images/hours/tui-3.png )
57+
4258Besides a TUI, ` hours ` also offers reports, statistics, and logs based on the
4359time tracking you do. These can be viewed using the subcommands ` report ` ,
4460` stats ` , and ` log ` respectively.
4561
4662### Reports
4763
64+ ``` bash
65+ hours report [flags] [arg]
4866```
49- hours report -h
5067
5168Output a report based on task log entries.
5269
5370Reports show time spent on tasks per day in the time period you specify. These
54- can also be aggregated (using -a ) to consolidate all task entries and show the
71+ can also be aggregated (using ` -a ` ) to consolidate all task entries and show the
5572cumulative time spent on each task per day.
5673
5774Accepts an argument, which can be one of the following:
5875
59- today: for today's report
60- yest: for yesterday's report
61- 3d: for a report on the last 3 days (default)
62- week: for a report on the current week
63- date: for a report for a specific date (eg. "2024/06/08")
64- range: for a report for a date range (eg. "2024/06/08...2024/06/12")
76+ today: for today's report
77+ yest: for yesterday's report
78+ 3d: for a report on the last 3 days (default)
79+ week: for a report on the current week
80+ date: for a report for a specific date (eg. "2024/06/08")
81+ range: for a report for a date range (eg. "2024/06/08...2024/06/12")
6582
66- Note: If a task log continues past midnight in your local timezone, it
67- will be reported on the day it ends.
83+ * Note: If a task log continues past midnight in your local timezone, it will be
84+ reported on the day it ends.*
6885
69- Usage:
70- hours report [flags]
86+ ![ Usage] ( https://tools.dhruvs.space/images/hours/report-1.png )
7187
72- Flags:
73- -a, --agg whether to aggregate data by task for each day in report
74- -p, --plain whether to output report without any formatting
75- ```
88+ ### Logs
7689
7790``` bash
78- # see report from last 3 days
79- hours report
80-
81- # see aggregated time spent on tasks
82- hours report -a
83-
84- # see report for the 7 days
85- hours report week
86-
87- # see report for a specific date range
88- hours report 2024/06/08...2024/06/12
89- ```
90-
91- Statistics
92- ---
93-
91+ hours log [flags] [arg]
9492```
95- hours stats -h
9693
97- Output statistics for tracked time .
94+ Output task log entries .
9895
9996Accepts an argument, which can be one of the following:
10097
101- today: show stats for today
102- yest: show stats for yesterday
103- 3d: show stats for the last 3 days (default)
104- week: show stats for the current week
105- month: show stats for the current month
106- date: show stats for a specific date (eg. "2024/06/08")
107- range: show stats for a specific date range (eg. "2024/06/08...2024/06/12")
108- all: show stats for all log entries
109-
110- Note: If a task log continues past midnight in your local timezone, it'll
111- be considered in the stats for the day it ends.
98+ today: for log entries from today
99+ yest: for log entries from yesterday
100+ 3d: for log entries from the last 3 days (default)
101+ week: for log entries from the current week
102+ date: for log entries from a specific date (eg. "2024/06/08")
103+ range: for log entries from a specific date range (eg. "2024/06/08...2024/06/12")
112104
113- Usage:
114- hours stats [flags]
105+ * Note: If a task log continues past midnight in your local timezone, it'll
106+ appear in the log for the day it ends. *
115107
116- Flags:
117- -p, --plain whether to output stats without any formatting
118- ```
108+ ![ Usage] ( https://tools.dhruvs.space/images/hours/log-1.png )
119109
120- ### Logs
110+ Statistics
111+ ---
121112
113+ ``` bash
114+ hours stats [flag] [arg]
122115```
123- hours log -h
124116
125- Output task log entries .
117+ Output statistics for tracked time .
126118
127119Accepts an argument, which can be one of the following:
128120
129- today: for log entries from today
130- yest: for log entries from yesterday
131- 3d: for log entries from the last 3 days (default)
132- week: for log entries from the current week
133- date: for log entries from a specific date (eg. "2024/06/08")
134- range: for log entries from a specific date range (eg. "2024/06/08...2024/06/12")
135-
136- Note: If a task log continues past midnight in your local timezone, it'll
137- appear in the log for the day it ends.
138-
139- Usage:
140- hours log [flags]
141-
142- Flags:
143- -p, --plain whether to output log without any formatting
144- ```
121+ today: show stats for today
122+ yest: show stats for yesterday
123+ 3d: show stats for the last 3 days (default)
124+ week: show stats for the current week
125+ month: show stats for the current month
126+ date: show stats for a specific date (eg. "2024/06/08")
127+ range: show stats for a specific date range (eg. "2024/06/08...2024/06/12")
128+ all: show stats for all log entries
145129
146- ``` bash
147- # see log entries from today
148- hours log today
130+ * Note: If a task log continues past midnight in your local timezone, it'll
131+ be considered in the stats for the day it ends.*
149132
150- # see log entries from a specific day
151- hours log 2024/06/08
152-
153- # see log entries from a specific date range
154- hours log 2024/06/08...2024/06/12
155- ```
133+ ![ Usage] ( https://tools.dhruvs.space/images/hours/stats-1.png )
156134
157135📋 TUI Reference Manual
158136---
159137
160- ```
138+ ``` text
161139"hours" has 5 panes:
162140 - Tasks List View Shows your tasks
163141 - Task Management View Allows you to create/update tasks
@@ -213,3 +191,4 @@ Acknowledgements
213191` hours ` is built using the TUI framework [ bubbletea] [ 1 ] .
214192
215193[ 1 ] : https://github.com/charmbracelet/bubbletea
194+ [ 2 ] : https://www.youtube.com/watch?v=o244r1nyxac
0 commit comments