-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWsummary
More file actions
executable file
·49 lines (45 loc) · 1.06 KB
/
Copy pathWsummary
File metadata and controls
executable file
·49 lines (45 loc) · 1.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/bin/bash
# Define the paths to your HTML files.
M_BASE="/home/xz/Videos/2025 Long-term summary.html"
W_FILE="/home/xz/Videos/weekly Summary_ Always set a number of STEPS.html"
D_FILE="/home/xz/Videos/Daily Summary 2025.html"
# Extract the current month.
MONTH=$(date +"%m")
# MONTH="09" # for testing
# Determine the M_FILE URL based on the current month.
case "$MONTH" in
01|02|03)
M_FILE="file://${M_BASE}#Quater-1"
;;
04|05|06)
M_FILE="file://${M_BASE}#Quater-2"
;;
07|08|09)
M_FILE="file://${M_BASE}#Quater-3"
;;
10|11|12)
M_FILE="file://${M_BASE}#Quater-4"
;;
*)
M_FILE="file://${M_BASE}" # default case if needed
;;
esac
# Check the provided arguments.
case "$1" in
-m)
firefox "$M_FILE"
;;
-w)
firefox "$W_FILE"
;;
-d)
firefox "$D_FILE"
;;
*)
echo "Usage: $0 {-m|-w|-d}"
echo "-m: Open M_FILE"
echo "-w: Open W_FILE"
echo "-d: Open D_FILE"
exit 1
;;
esac