tm-timer 2.0__tar.gz → 2.2__tar.gz
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.
- tm_timer-2.2/PKG-INFO +108 -0
- tm_timer-2.2/README.md +96 -0
- {tm_timer-2.0 → tm_timer-2.2}/pyproject.toml +1 -1
- {tm_timer-2.0 → tm_timer-2.2}/setup.py +1 -1
- {tm_timer-2.0 → tm_timer-2.2}/tm_timer/cli.py +99 -34
- tm_timer-2.2/tm_timer.egg-info/PKG-INFO +108 -0
- {tm_timer-2.0 → tm_timer-2.2}/tm_timer.egg-info/SOURCES.txt +0 -1
- tm_timer-2.0/LICENSE +0 -22
- tm_timer-2.0/PKG-INFO +0 -67
- tm_timer-2.0/README.md +0 -53
- tm_timer-2.0/tm_timer.egg-info/PKG-INFO +0 -67
- {tm_timer-2.0 → tm_timer-2.2}/setup.cfg +0 -0
- {tm_timer-2.0 → tm_timer-2.2}/tm_timer/__init__.py +0 -0
- {tm_timer-2.0 → tm_timer-2.2}/tm_timer.egg-info/dependency_links.txt +0 -0
- {tm_timer-2.0 → tm_timer-2.2}/tm_timer.egg-info/entry_points.txt +0 -0
- {tm_timer-2.0 → tm_timer-2.2}/tm_timer.egg-info/top_level.txt +0 -0
tm_timer-2.2/PKG-INFO
ADDED
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: tm-timer
|
|
3
|
+
Version: 2.2
|
|
4
|
+
Summary: Minimalistic terminal-based timer with Study/Train tracking
|
|
5
|
+
Author: ph4nt01
|
|
6
|
+
Author-email: Ph4nt01 <ph4nt0.84@email.com>
|
|
7
|
+
License: MIT
|
|
8
|
+
Requires-Python: >=3.6
|
|
9
|
+
Description-Content-Type: text/markdown
|
|
10
|
+
Dynamic: author
|
|
11
|
+
Dynamic: requires-python
|
|
12
|
+
|
|
13
|
+
# In The Name of God
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
# ⏱️ tm-timer
|
|
17
|
+
> Minimalistic Terminal timer with dynamic activity tracking
|
|
18
|
+
|
|
19
|
+
## Features
|
|
20
|
+
|
|
21
|
+
- Countdown timer:
|
|
22
|
+
- `tm 10s`, `tm 25m`, `tm 1h30m`
|
|
23
|
+
- Dynamic Activity modes (track anything):
|
|
24
|
+
- `tm -a study` -> track study sessions
|
|
25
|
+
- `tm -a train` -> track training sessions
|
|
26
|
+
- `tm -a reading` -> track custom activities (resets daily, accumulates across multiple runs)
|
|
27
|
+
- Daily logging:
|
|
28
|
+
- Records totals in `~/.tm_timer/data.json`
|
|
29
|
+
- Each day resets at midnight (splits time correctly if a session crosses midnight)
|
|
30
|
+
- Statistics:
|
|
31
|
+
- Average daily hours
|
|
32
|
+
- Standard Deviation of Time
|
|
33
|
+
- Status report:
|
|
34
|
+
- **Very Good** (SD < AVG/2)
|
|
35
|
+
- **Good** (SD = AVG/2)
|
|
36
|
+
- **Not Good** (SD > AVG/2)
|
|
37
|
+
- Export & Management:
|
|
38
|
+
- `tm -s study` -> show study table + stats
|
|
39
|
+
- `tm --list` -> list all tracked activities and their total time
|
|
40
|
+
- `tm -t` -> export all activity tables to `tables.md`
|
|
41
|
+
- Controls:
|
|
42
|
+
- `p` -> pause/resume
|
|
43
|
+
- `q` -> quit and save
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## Installation
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
sudo apt install pipx # if not installed
|
|
51
|
+
pipx install tm-timer # install tm-timer
|
|
52
|
+
pipx ensurepath # add tm to PATH
|
|
53
|
+
exec $SHELL # reload shell
|
|
54
|
+
````
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
## Example Usage
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
# Start a study session
|
|
62
|
+
tm -a study
|
|
63
|
+
|
|
64
|
+
# Check study stats
|
|
65
|
+
tm -s study
|
|
66
|
+
|
|
67
|
+
# Start a train session
|
|
68
|
+
tm -a train
|
|
69
|
+
|
|
70
|
+
# Start a custom activity session (e.g., reading)
|
|
71
|
+
tm -a reading
|
|
72
|
+
|
|
73
|
+
# List all recorded activities
|
|
74
|
+
tm --list
|
|
75
|
+
|
|
76
|
+
# Export tables to tables.md
|
|
77
|
+
tm -t
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
---
|
|
81
|
+
|
|
82
|
+
## Example Tables Output
|
|
83
|
+
|
|
84
|
+
```markdown
|
|
85
|
+
## STUDY Table
|
|
86
|
+
|
|
87
|
+
| Date | Day | Time |
|
|
88
|
+
| ---------- | --- | ------ |
|
|
89
|
+
| 2025-10-03 | FRI | 05:00:00 |
|
|
90
|
+
| 2025-10-02 | THU | 02:50:00 |
|
|
91
|
+
| 2025-09-29 | MON | 04:05:00 |
|
|
92
|
+
| 2025-09-27 | SAT | 03:36:00 |
|
|
93
|
+
|
|
94
|
+
[AVG] = 3.98h [Standard Deviation of Time] = 0.75h Status = Very Good
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
## TRAIN Table
|
|
98
|
+
|
|
99
|
+
| Date | Day | Time |
|
|
100
|
+
| ---------- | --- | ------ |
|
|
101
|
+
| 2025-10-03 | FRI | 00:57:00 |
|
|
102
|
+
| 2025-10-02 | THU | 00:50:00 |
|
|
103
|
+
| 2025-09-30 | SUN | 00:35:00 |
|
|
104
|
+
| 2025-09-28 | SAT | 01:36:00 |
|
|
105
|
+
|
|
106
|
+
[AVG] = 1.05h [Standard Deviation of Time] = 0.38h Status = Very Good
|
|
107
|
+
```
|
|
108
|
+
|
tm_timer-2.2/README.md
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# In The Name of God
|
|
2
|
+
|
|
3
|
+
---
|
|
4
|
+
# ⏱️ tm-timer
|
|
5
|
+
> Minimalistic Terminal timer with dynamic activity tracking
|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
- Countdown timer:
|
|
10
|
+
- `tm 10s`, `tm 25m`, `tm 1h30m`
|
|
11
|
+
- Dynamic Activity modes (track anything):
|
|
12
|
+
- `tm -a study` -> track study sessions
|
|
13
|
+
- `tm -a train` -> track training sessions
|
|
14
|
+
- `tm -a reading` -> track custom activities (resets daily, accumulates across multiple runs)
|
|
15
|
+
- Daily logging:
|
|
16
|
+
- Records totals in `~/.tm_timer/data.json`
|
|
17
|
+
- Each day resets at midnight (splits time correctly if a session crosses midnight)
|
|
18
|
+
- Statistics:
|
|
19
|
+
- Average daily hours
|
|
20
|
+
- Standard Deviation of Time
|
|
21
|
+
- Status report:
|
|
22
|
+
- **Very Good** (SD < AVG/2)
|
|
23
|
+
- **Good** (SD = AVG/2)
|
|
24
|
+
- **Not Good** (SD > AVG/2)
|
|
25
|
+
- Export & Management:
|
|
26
|
+
- `tm -s study` -> show study table + stats
|
|
27
|
+
- `tm --list` -> list all tracked activities and their total time
|
|
28
|
+
- `tm -t` -> export all activity tables to `tables.md`
|
|
29
|
+
- Controls:
|
|
30
|
+
- `p` -> pause/resume
|
|
31
|
+
- `q` -> quit and save
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
## Installation
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
sudo apt install pipx # if not installed
|
|
39
|
+
pipx install tm-timer # install tm-timer
|
|
40
|
+
pipx ensurepath # add tm to PATH
|
|
41
|
+
exec $SHELL # reload shell
|
|
42
|
+
````
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
## Example Usage
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
# Start a study session
|
|
50
|
+
tm -a study
|
|
51
|
+
|
|
52
|
+
# Check study stats
|
|
53
|
+
tm -s study
|
|
54
|
+
|
|
55
|
+
# Start a train session
|
|
56
|
+
tm -a train
|
|
57
|
+
|
|
58
|
+
# Start a custom activity session (e.g., reading)
|
|
59
|
+
tm -a reading
|
|
60
|
+
|
|
61
|
+
# List all recorded activities
|
|
62
|
+
tm --list
|
|
63
|
+
|
|
64
|
+
# Export tables to tables.md
|
|
65
|
+
tm -t
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
---
|
|
69
|
+
|
|
70
|
+
## Example Tables Output
|
|
71
|
+
|
|
72
|
+
```markdown
|
|
73
|
+
## STUDY Table
|
|
74
|
+
|
|
75
|
+
| Date | Day | Time |
|
|
76
|
+
| ---------- | --- | ------ |
|
|
77
|
+
| 2025-10-03 | FRI | 05:00:00 |
|
|
78
|
+
| 2025-10-02 | THU | 02:50:00 |
|
|
79
|
+
| 2025-09-29 | MON | 04:05:00 |
|
|
80
|
+
| 2025-09-27 | SAT | 03:36:00 |
|
|
81
|
+
|
|
82
|
+
[AVG] = 3.98h [Standard Deviation of Time] = 0.75h Status = Very Good
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
## TRAIN Table
|
|
86
|
+
|
|
87
|
+
| Date | Day | Time |
|
|
88
|
+
| ---------- | --- | ------ |
|
|
89
|
+
| 2025-10-03 | FRI | 00:57:00 |
|
|
90
|
+
| 2025-10-02 | THU | 00:50:00 |
|
|
91
|
+
| 2025-09-30 | SUN | 00:35:00 |
|
|
92
|
+
| 2025-09-28 | SAT | 01:36:00 |
|
|
93
|
+
|
|
94
|
+
[AVG] = 1.05h [Standard Deviation of Time] = 0.38h Status = Very Good
|
|
95
|
+
```
|
|
96
|
+
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "tm-timer"
|
|
7
|
-
version = "2.
|
|
7
|
+
version = "2.2"
|
|
8
8
|
description = "Minimalistic terminal-based timer with Study/Train tracking"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
authors = [{ name="Ph4nt01", email="ph4nt0.84@email.com" }]
|
|
@@ -57,18 +57,21 @@ DATA_FILE = DATA_DIR / "data.json"
|
|
|
57
57
|
|
|
58
58
|
def load_data():
|
|
59
59
|
if not DATA_FILE.exists():
|
|
60
|
-
return {
|
|
60
|
+
return {}
|
|
61
61
|
try:
|
|
62
62
|
with DATA_FILE.open("r", encoding="utf-8") as f:
|
|
63
63
|
data = json.load(f)
|
|
64
64
|
except Exception:
|
|
65
|
-
return {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
65
|
+
return {}
|
|
66
|
+
if not isinstance(data, dict):
|
|
67
|
+
return {}
|
|
68
|
+
# normalize: every value must be a dict of {date_str: int_seconds}
|
|
69
|
+
cleaned = {}
|
|
70
|
+
for activity, days in data.items():
|
|
71
|
+
if not isinstance(days, dict):
|
|
72
|
+
continue
|
|
73
|
+
cleaned[activity] = {str(k): int(v) for k, v in days.items()}
|
|
74
|
+
return cleaned
|
|
72
75
|
|
|
73
76
|
|
|
74
77
|
def save_data(data):
|
|
@@ -159,11 +162,12 @@ def print_activity_table(activity):
|
|
|
159
162
|
def write_tables_md(path="tables.md"):
|
|
160
163
|
data = load_data()
|
|
161
164
|
lines = []
|
|
162
|
-
for activity in (
|
|
165
|
+
for activity in sorted(data.keys()):
|
|
163
166
|
lines.append(f"## {activity.upper()} Table\n")
|
|
164
167
|
lines.append("| Date | Day | Time |\n")
|
|
165
168
|
lines.append("| ---- | --- | ---- |\n")
|
|
166
|
-
items = sorted(data.get(activity, {}).items(),
|
|
169
|
+
items = sorted(data.get(activity, {}).items(),
|
|
170
|
+
key=lambda kv: kv[0], reverse=True)
|
|
167
171
|
for date_str, secs in items:
|
|
168
172
|
try:
|
|
169
173
|
dt = datetime.datetime.strptime(date_str, "%Y-%m-%d").date()
|
|
@@ -171,13 +175,17 @@ def write_tables_md(path="tables.md"):
|
|
|
171
175
|
except Exception:
|
|
172
176
|
day_name = ""
|
|
173
177
|
lines.append(f"| {date_str} | {day_name} | {format_hms(secs)} |\n")
|
|
178
|
+
|
|
174
179
|
stats = compute_stats_for_activity(activity)
|
|
175
180
|
if stats["n"] < 2:
|
|
176
181
|
lines.append("\nNot enough recording for statistics (need 2+ days).\n\n")
|
|
177
182
|
else:
|
|
178
183
|
lines.append(
|
|
179
|
-
f"\n[AVG] = {stats['avg']:.2f}h
|
|
184
|
+
f"\n[AVG] = {stats['avg']:.2f}h "
|
|
185
|
+
f"[Standard Deviation of Time] = {stats['sd']:.2f}h "
|
|
186
|
+
f"Status = {status_from_avg_sd(stats['avg'], stats['sd'])}\n\n"
|
|
180
187
|
)
|
|
188
|
+
|
|
181
189
|
out_path = Path.cwd() / path
|
|
182
190
|
out_path.write_text("".join(lines), encoding="utf-8")
|
|
183
191
|
return str(out_path.resolve())
|
|
@@ -215,10 +223,10 @@ def run_activity(activity):
|
|
|
215
223
|
stats_before = compute_stats_for_activity(activity)
|
|
216
224
|
if stats_before["n"] >= 2:
|
|
217
225
|
print(
|
|
218
|
-
f"[
|
|
226
|
+
f"[AVG] = {stats_before['avg']:.2f}h [Standard Deviation of Time] = {stats_before['sd']:.2f}h Status = {status_from_avg_sd(stats_before['avg'], stats_before['sd'])}"
|
|
219
227
|
)
|
|
220
228
|
else:
|
|
221
|
-
print("
|
|
229
|
+
print("Not enough recordings to compute AVG/SD (need 2+ days).")
|
|
222
230
|
|
|
223
231
|
# input listener thread
|
|
224
232
|
def input_listener():
|
|
@@ -337,37 +345,93 @@ def run_countdown(target_seconds, target_input):
|
|
|
337
345
|
print("Timer stopped.")
|
|
338
346
|
|
|
339
347
|
|
|
340
|
-
#
|
|
348
|
+
# Back-compat alias map: old flag -> activity name
|
|
349
|
+
# LEGACY_ALIASES = {
|
|
350
|
+
# "study": "study",
|
|
351
|
+
# "train": "train",
|
|
352
|
+
# "studystatus": "study", # for --studystatus
|
|
353
|
+
# "trainstatus": "train", # for --trainstatus
|
|
354
|
+
# }
|
|
355
|
+
|
|
356
|
+
|
|
341
357
|
def main():
|
|
342
|
-
parser = argparse.ArgumentParser(
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
358
|
+
parser = argparse.ArgumentParser(
|
|
359
|
+
description="tm_timer - terminal timer with per-activity logging",
|
|
360
|
+
formatter_class=argparse.RawDescriptionHelpFormatter,
|
|
361
|
+
epilog=(
|
|
362
|
+
"Examples:\n"
|
|
363
|
+
" tm_timer -a study # start study timer\n"
|
|
364
|
+
" tm_timer -a reading # start a custom 'reading' timer\n"
|
|
365
|
+
" tm_timer -s study # show study table + stats\n"
|
|
366
|
+
" tm_timer -t # export tables.md\n"
|
|
367
|
+
" tm_timer 25m # plain countdown\n"
|
|
368
|
+
),
|
|
369
|
+
)
|
|
370
|
+
parser.add_argument(
|
|
371
|
+
"-a", "--activity", metavar="NAME",
|
|
372
|
+
help="Run timer for the given activity (any name you like).",
|
|
373
|
+
)
|
|
374
|
+
parser.add_argument(
|
|
375
|
+
"-s", "--status", metavar="NAME",
|
|
376
|
+
help="Show daily table and statistics for the given activity.",
|
|
377
|
+
)
|
|
378
|
+
parser.add_argument(
|
|
379
|
+
"--list", action="store_true",
|
|
380
|
+
help="List all activities recorded so far.",
|
|
381
|
+
)
|
|
382
|
+
parser.add_argument(
|
|
383
|
+
"-t", "--tables", action="store_true",
|
|
384
|
+
help="Export tables.md (all activities) to the current directory.",
|
|
385
|
+
)
|
|
386
|
+
|
|
387
|
+
# Deprecated back-compat aliases
|
|
388
|
+
# parser.add_argument("--study", action="store_true", help="(deprecated) alias for -a study")
|
|
389
|
+
# parser.add_argument("--train", action="store_true", help="(deprecated) alias for -a train")
|
|
390
|
+
# parser.add_argument("--studystatus", action="store_true", help="(deprecated) alias for --status study")
|
|
391
|
+
# parser.add_argument("--trainstatus", action="store_true", help="(deprecated) alias for --status train")
|
|
392
|
+
|
|
393
|
+
parser.add_argument("duration", nargs="?",
|
|
394
|
+
help="Optional duration e.g. 1h30m (countdown mode).")
|
|
349
395
|
args = parser.parse_args()
|
|
350
396
|
|
|
351
|
-
#
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
if args.
|
|
356
|
-
|
|
397
|
+
# Resolve legacy aliases into the new flags
|
|
398
|
+
activity = args.activity
|
|
399
|
+
status_of = args.status
|
|
400
|
+
# if args.study: activity = activity or "study"
|
|
401
|
+
# if args.train: activity = activity or "train"
|
|
402
|
+
# if args.studystatus: status_of = status_of or "study"
|
|
403
|
+
# if args.trainstatus: status_of = status_of or "train"
|
|
404
|
+
|
|
405
|
+
# 1) status
|
|
406
|
+
if status_of:
|
|
407
|
+
print_activity_table(status_of)
|
|
357
408
|
return
|
|
409
|
+
|
|
410
|
+
# 2) tables export
|
|
358
411
|
if args.tables:
|
|
359
412
|
out = write_tables_md("tables.md")
|
|
360
413
|
print(f"created {out}")
|
|
361
414
|
return
|
|
362
415
|
|
|
363
|
-
|
|
364
|
-
|
|
416
|
+
# 3) list activities
|
|
417
|
+
if args.list:
|
|
418
|
+
data = load_data()
|
|
419
|
+
if not data:
|
|
420
|
+
print("No activities recorded yet.")
|
|
421
|
+
return
|
|
422
|
+
print("Activities:")
|
|
423
|
+
for name in sorted(data):
|
|
424
|
+
n_days = len(data[name])
|
|
425
|
+
total = sum(data[name].values())
|
|
426
|
+
print(f" - {name:<15} {n_days:>3} days total {format_hms(total)}")
|
|
365
427
|
return
|
|
366
|
-
|
|
367
|
-
|
|
428
|
+
|
|
429
|
+
# 4) run an activity timer
|
|
430
|
+
if activity:
|
|
431
|
+
run_activity(activity)
|
|
368
432
|
return
|
|
369
433
|
|
|
370
|
-
#
|
|
434
|
+
# 5) plain countdown (backward compatible)
|
|
371
435
|
if args.duration:
|
|
372
436
|
try:
|
|
373
437
|
target_seconds = parse_time_input(args.duration)
|
|
@@ -375,8 +439,9 @@ def main():
|
|
|
375
439
|
print(e)
|
|
376
440
|
sys.exit(1)
|
|
377
441
|
run_countdown(target_seconds, args.duration)
|
|
378
|
-
|
|
379
|
-
|
|
442
|
+
return
|
|
443
|
+
|
|
444
|
+
parser.print_help()
|
|
380
445
|
|
|
381
446
|
|
|
382
447
|
if __name__ == "__main__":
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: tm-timer
|
|
3
|
+
Version: 2.2
|
|
4
|
+
Summary: Minimalistic terminal-based timer with Study/Train tracking
|
|
5
|
+
Author: ph4nt01
|
|
6
|
+
Author-email: Ph4nt01 <ph4nt0.84@email.com>
|
|
7
|
+
License: MIT
|
|
8
|
+
Requires-Python: >=3.6
|
|
9
|
+
Description-Content-Type: text/markdown
|
|
10
|
+
Dynamic: author
|
|
11
|
+
Dynamic: requires-python
|
|
12
|
+
|
|
13
|
+
# In The Name of God
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
# ⏱️ tm-timer
|
|
17
|
+
> Minimalistic Terminal timer with dynamic activity tracking
|
|
18
|
+
|
|
19
|
+
## Features
|
|
20
|
+
|
|
21
|
+
- Countdown timer:
|
|
22
|
+
- `tm 10s`, `tm 25m`, `tm 1h30m`
|
|
23
|
+
- Dynamic Activity modes (track anything):
|
|
24
|
+
- `tm -a study` -> track study sessions
|
|
25
|
+
- `tm -a train` -> track training sessions
|
|
26
|
+
- `tm -a reading` -> track custom activities (resets daily, accumulates across multiple runs)
|
|
27
|
+
- Daily logging:
|
|
28
|
+
- Records totals in `~/.tm_timer/data.json`
|
|
29
|
+
- Each day resets at midnight (splits time correctly if a session crosses midnight)
|
|
30
|
+
- Statistics:
|
|
31
|
+
- Average daily hours
|
|
32
|
+
- Standard Deviation of Time
|
|
33
|
+
- Status report:
|
|
34
|
+
- **Very Good** (SD < AVG/2)
|
|
35
|
+
- **Good** (SD = AVG/2)
|
|
36
|
+
- **Not Good** (SD > AVG/2)
|
|
37
|
+
- Export & Management:
|
|
38
|
+
- `tm -s study` -> show study table + stats
|
|
39
|
+
- `tm --list` -> list all tracked activities and their total time
|
|
40
|
+
- `tm -t` -> export all activity tables to `tables.md`
|
|
41
|
+
- Controls:
|
|
42
|
+
- `p` -> pause/resume
|
|
43
|
+
- `q` -> quit and save
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## Installation
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
sudo apt install pipx # if not installed
|
|
51
|
+
pipx install tm-timer # install tm-timer
|
|
52
|
+
pipx ensurepath # add tm to PATH
|
|
53
|
+
exec $SHELL # reload shell
|
|
54
|
+
````
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
## Example Usage
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
# Start a study session
|
|
62
|
+
tm -a study
|
|
63
|
+
|
|
64
|
+
# Check study stats
|
|
65
|
+
tm -s study
|
|
66
|
+
|
|
67
|
+
# Start a train session
|
|
68
|
+
tm -a train
|
|
69
|
+
|
|
70
|
+
# Start a custom activity session (e.g., reading)
|
|
71
|
+
tm -a reading
|
|
72
|
+
|
|
73
|
+
# List all recorded activities
|
|
74
|
+
tm --list
|
|
75
|
+
|
|
76
|
+
# Export tables to tables.md
|
|
77
|
+
tm -t
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
---
|
|
81
|
+
|
|
82
|
+
## Example Tables Output
|
|
83
|
+
|
|
84
|
+
```markdown
|
|
85
|
+
## STUDY Table
|
|
86
|
+
|
|
87
|
+
| Date | Day | Time |
|
|
88
|
+
| ---------- | --- | ------ |
|
|
89
|
+
| 2025-10-03 | FRI | 05:00:00 |
|
|
90
|
+
| 2025-10-02 | THU | 02:50:00 |
|
|
91
|
+
| 2025-09-29 | MON | 04:05:00 |
|
|
92
|
+
| 2025-09-27 | SAT | 03:36:00 |
|
|
93
|
+
|
|
94
|
+
[AVG] = 3.98h [Standard Deviation of Time] = 0.75h Status = Very Good
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
## TRAIN Table
|
|
98
|
+
|
|
99
|
+
| Date | Day | Time |
|
|
100
|
+
| ---------- | --- | ------ |
|
|
101
|
+
| 2025-10-03 | FRI | 00:57:00 |
|
|
102
|
+
| 2025-10-02 | THU | 00:50:00 |
|
|
103
|
+
| 2025-09-30 | SUN | 00:35:00 |
|
|
104
|
+
| 2025-09-28 | SAT | 01:36:00 |
|
|
105
|
+
|
|
106
|
+
[AVG] = 1.05h [Standard Deviation of Time] = 0.38h Status = Very Good
|
|
107
|
+
```
|
|
108
|
+
|
tm_timer-2.0/LICENSE
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 Ph4nt01
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in
|
|
13
|
-
all copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
20
|
-
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
|
21
|
-
DEALINGS IN THE SOFTWARE.
|
|
22
|
-
|
tm_timer-2.0/PKG-INFO
DELETED
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.4
|
|
2
|
-
Name: tm-timer
|
|
3
|
-
Version: 2.0
|
|
4
|
-
Summary: Minimalistic terminal-based timer with Study/Train tracking
|
|
5
|
-
Author: ph4nt01
|
|
6
|
-
Author-email: Ph4nt01 <ph4nt0.84@email.com>
|
|
7
|
-
License: MIT
|
|
8
|
-
Requires-Python: >=3.6
|
|
9
|
-
Description-Content-Type: text/markdown
|
|
10
|
-
License-File: LICENSE
|
|
11
|
-
Dynamic: author
|
|
12
|
-
Dynamic: license-file
|
|
13
|
-
Dynamic: requires-python
|
|
14
|
-
|
|
15
|
-
# In The Name of God
|
|
16
|
-
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
## ⏱ tm : Minimalistic Terminal-based timer with Study/Train tracking
|
|
20
|
-
|
|
21
|
-
### Features:
|
|
22
|
-
|
|
23
|
-
- Run from terminal:
|
|
24
|
-
- Countdown timer: `tm 10s`, `tm 25m`, `tm 1h30m`
|
|
25
|
-
- Study session: `tm --study` (tracks across sessions, resets daily)
|
|
26
|
-
- Train session: `tm --train` (tracks across sessions, resets daily)
|
|
27
|
-
- Daily study/train totals saved in `~/.tm_timer/data.json`
|
|
28
|
-
- Tables and statistics:
|
|
29
|
-
- `tm --studystatus` / `tm --trainstatus` → show daily table and Standard Deviation
|
|
30
|
-
- `tm --tables` → export `tables.md`
|
|
31
|
-
- Statistics:
|
|
32
|
-
- Average daily hours
|
|
33
|
-
- Standard Deviation of daily hours
|
|
34
|
-
- Status report (Very Good / Good / Not Good)
|
|
35
|
-
- Controls:
|
|
36
|
-
- Press `p` to pause/resume
|
|
37
|
-
- Press `q` to quit early
|
|
38
|
-
- Supports human durations like `2h45m30s`
|
|
39
|
-
- Simple, no graphical BLOAT.
|
|
40
|
-
|
|
41
|
-
---
|
|
42
|
-
|
|
43
|
-
### Installation:
|
|
44
|
-
|
|
45
|
-
```bash
|
|
46
|
-
sudo apt install pipx # if not installed
|
|
47
|
-
pipx install tm-timer # to install tm-timer
|
|
48
|
-
pipx ensurepath # to add tm to PATH
|
|
49
|
-
exec $SHELL # reload shell
|
|
50
|
-
|
|
51
|
-
#or run locally with using cli.py
|
|
52
|
-
python3 cli.py 3h40m
|
|
53
|
-
```
|
|
54
|
-
|
|
55
|
-
Example Usage:
|
|
56
|
-
bash
|
|
57
|
-
Copy code
|
|
58
|
-
tm --study
|
|
59
|
-
# Timer starts, press 'q' to stop, progress saved daily
|
|
60
|
-
|
|
61
|
-
tm --studystatus
|
|
62
|
-
# Shows study table and stats
|
|
63
|
-
|
|
64
|
-
tm --tables
|
|
65
|
-
# Exports study/train tables as tables.md
|
|
66
|
-
⏱ tm preview:
|
|
67
|
-
|
tm_timer-2.0/README.md
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
# In The Name of God
|
|
2
|
-
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
## ⏱ tm : Minimalistic Terminal-based timer with Study/Train tracking
|
|
6
|
-
|
|
7
|
-
### Features:
|
|
8
|
-
|
|
9
|
-
- Run from terminal:
|
|
10
|
-
- Countdown timer: `tm 10s`, `tm 25m`, `tm 1h30m`
|
|
11
|
-
- Study session: `tm --study` (tracks across sessions, resets daily)
|
|
12
|
-
- Train session: `tm --train` (tracks across sessions, resets daily)
|
|
13
|
-
- Daily study/train totals saved in `~/.tm_timer/data.json`
|
|
14
|
-
- Tables and statistics:
|
|
15
|
-
- `tm --studystatus` / `tm --trainstatus` → show daily table and Standard Deviation
|
|
16
|
-
- `tm --tables` → export `tables.md`
|
|
17
|
-
- Statistics:
|
|
18
|
-
- Average daily hours
|
|
19
|
-
- Standard Deviation of daily hours
|
|
20
|
-
- Status report (Very Good / Good / Not Good)
|
|
21
|
-
- Controls:
|
|
22
|
-
- Press `p` to pause/resume
|
|
23
|
-
- Press `q` to quit early
|
|
24
|
-
- Supports human durations like `2h45m30s`
|
|
25
|
-
- Simple, no graphical BLOAT.
|
|
26
|
-
|
|
27
|
-
---
|
|
28
|
-
|
|
29
|
-
### Installation:
|
|
30
|
-
|
|
31
|
-
```bash
|
|
32
|
-
sudo apt install pipx # if not installed
|
|
33
|
-
pipx install tm-timer # to install tm-timer
|
|
34
|
-
pipx ensurepath # to add tm to PATH
|
|
35
|
-
exec $SHELL # reload shell
|
|
36
|
-
|
|
37
|
-
#or run locally with using cli.py
|
|
38
|
-
python3 cli.py 3h40m
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
Example Usage:
|
|
42
|
-
bash
|
|
43
|
-
Copy code
|
|
44
|
-
tm --study
|
|
45
|
-
# Timer starts, press 'q' to stop, progress saved daily
|
|
46
|
-
|
|
47
|
-
tm --studystatus
|
|
48
|
-
# Shows study table and stats
|
|
49
|
-
|
|
50
|
-
tm --tables
|
|
51
|
-
# Exports study/train tables as tables.md
|
|
52
|
-
⏱ tm preview:
|
|
53
|
-
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.4
|
|
2
|
-
Name: tm-timer
|
|
3
|
-
Version: 2.0
|
|
4
|
-
Summary: Minimalistic terminal-based timer with Study/Train tracking
|
|
5
|
-
Author: ph4nt01
|
|
6
|
-
Author-email: Ph4nt01 <ph4nt0.84@email.com>
|
|
7
|
-
License: MIT
|
|
8
|
-
Requires-Python: >=3.6
|
|
9
|
-
Description-Content-Type: text/markdown
|
|
10
|
-
License-File: LICENSE
|
|
11
|
-
Dynamic: author
|
|
12
|
-
Dynamic: license-file
|
|
13
|
-
Dynamic: requires-python
|
|
14
|
-
|
|
15
|
-
# In The Name of God
|
|
16
|
-
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
## ⏱ tm : Minimalistic Terminal-based timer with Study/Train tracking
|
|
20
|
-
|
|
21
|
-
### Features:
|
|
22
|
-
|
|
23
|
-
- Run from terminal:
|
|
24
|
-
- Countdown timer: `tm 10s`, `tm 25m`, `tm 1h30m`
|
|
25
|
-
- Study session: `tm --study` (tracks across sessions, resets daily)
|
|
26
|
-
- Train session: `tm --train` (tracks across sessions, resets daily)
|
|
27
|
-
- Daily study/train totals saved in `~/.tm_timer/data.json`
|
|
28
|
-
- Tables and statistics:
|
|
29
|
-
- `tm --studystatus` / `tm --trainstatus` → show daily table and Standard Deviation
|
|
30
|
-
- `tm --tables` → export `tables.md`
|
|
31
|
-
- Statistics:
|
|
32
|
-
- Average daily hours
|
|
33
|
-
- Standard Deviation of daily hours
|
|
34
|
-
- Status report (Very Good / Good / Not Good)
|
|
35
|
-
- Controls:
|
|
36
|
-
- Press `p` to pause/resume
|
|
37
|
-
- Press `q` to quit early
|
|
38
|
-
- Supports human durations like `2h45m30s`
|
|
39
|
-
- Simple, no graphical BLOAT.
|
|
40
|
-
|
|
41
|
-
---
|
|
42
|
-
|
|
43
|
-
### Installation:
|
|
44
|
-
|
|
45
|
-
```bash
|
|
46
|
-
sudo apt install pipx # if not installed
|
|
47
|
-
pipx install tm-timer # to install tm-timer
|
|
48
|
-
pipx ensurepath # to add tm to PATH
|
|
49
|
-
exec $SHELL # reload shell
|
|
50
|
-
|
|
51
|
-
#or run locally with using cli.py
|
|
52
|
-
python3 cli.py 3h40m
|
|
53
|
-
```
|
|
54
|
-
|
|
55
|
-
Example Usage:
|
|
56
|
-
bash
|
|
57
|
-
Copy code
|
|
58
|
-
tm --study
|
|
59
|
-
# Timer starts, press 'q' to stop, progress saved daily
|
|
60
|
-
|
|
61
|
-
tm --studystatus
|
|
62
|
-
# Shows study table and stats
|
|
63
|
-
|
|
64
|
-
tm --tables
|
|
65
|
-
# Exports study/train tables as tables.md
|
|
66
|
-
⏱ tm preview:
|
|
67
|
-
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|