aboutsummaryrefslogtreecommitdiffhomepage
path: root/bin
diff options
context:
space:
mode:
authorHsieh Chin Fan <pham@topo.tw>2023-04-10 14:39:35 +0800
committerHsieh Chin Fan <pham@topo.tw>2023-04-10 14:39:35 +0800
commitc74169974e67152be756eafa5eef097ff9e1140c (patch)
tree45196dc48248f191735860da1aeac89c60e149b2 /bin
parentdaa7578cf0b5dadcd83c28f2094bcaacd632df99 (diff)
Update
Diffstat (limited to 'bin')
-rwxr-xr-xbin/task/context9
1 files changed, 6 insertions, 3 deletions
diff --git a/bin/task/context b/bin/task/context
index 600eae0..6e48df3 100755
--- a/bin/task/context
+++ b/bin/task/context
@@ -1,8 +1,9 @@
1#! /bin/bash 1#! /bin/bash
2 2
3# Usage: 3# Usage:
4# context 1h2m30s (Update current context with given time) 4# context 1h2m30s (Update current context with given time)
5# context (Check total time of each context) 5# context -s 1h20m (Set current context with given time)
6# context (Check total time of each context)
6 7
7LOG_FILE=~/log/.context && touch $LOG_FILE 8LOG_FILE=~/log/.context && touch $LOG_FILE
8PLAN_FILE=~/log/plan.context.md 9PLAN_FILE=~/log/plan.context.md
@@ -14,7 +15,9 @@ time="$1"
14# If it is 900(seconds), then the minimal symbol of 15# If it is 900(seconds), then the minimal symbol of
15# time display is 15min 16# time display is 15min
16UNIT=900 17UNIT=900
17BLOCK_CHAR=▊ 18#BLOCK_CHAR=
19BLOCK_CHAR=▮ #▊◼
20
18# This dictionary store the valid contexts and the time I plan to spend on 21# This dictionary store the valid contexts and the time I plan to spend on
19declare -A SPEND 22declare -A SPEND
20 23