@@ 113,7 113,7 @@ case $action in
fi
strippeditem="$(echo "$strippeditem" | sed -E 's/^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9] //')"
echo "$NOW $strippeditem" >> "$TIMETRACK_FILE"
- sed -i -E "s/#timetracking//g" "$TODO_FILE"
+ sed -i -E "s/ *#timetracking//g" "$TODO_FILE"
if echo "$itemno" | grep -qE '^[0-9]+$'; then
sed -i -E "${itemno}s|$| #timetracking|" "$TODO_FILE"
fi
@@ 121,7 121,7 @@ case $action in
;;
"stop")
echo "$NOW idle" >> "$TIMETRACK_FILE"
- sed -i -E "s/#timetracking//g" "$TODO_FILE"
+ sed -i -E "s/ *#timetracking//g" "$TODO_FILE"
[ "$TODOTXT_NOTIFY" = 1 ] && notify-send -a "todo.txt-more" "Task stopped (tracking)"
;;
"edit")