File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -25,9 +25,11 @@ function _command_duration() {
2525 local -i minutes=0 seconds=0 deciseconds=0
2626 local -i command_start_seconds=" ${command_start% .* } "
2727 local -i command_start_deciseconds=$(( 10 #${command_start##* .} ))
28+ command_start_deciseconds=" ${command_start_deciseconds: 0: 1} "
2829 local current_time=" ${EPOCHREALTIME:- $SECONDS } "
2930 local -i current_time_seconds=" ${current_time% .* } "
3031 local -i current_time_deciseconds=" $(( 10 #${current_time##* .} )) "
32+ current_time_deciseconds=" ${current_time_deciseconds: 0: 1} "
3133
3234 if [[ " ${command_start_seconds:- 0} " -gt 0 ]]; then
3335 # seconds
@@ -50,9 +52,9 @@ function _command_duration() {
5052
5153 _dynamic_clock_icon " ${command_duration} "
5254 if (( minutes > 0 )) ; then
53- printf " %s%s%dm %ds" " ${COMMAND_DURATION_ICON:- } " " ${COMMAND_DURATION_COLOR:- } " " $minutes " " $seconds "
55+ printf " %s %s%dm %ds" " ${COMMAND_DURATION_ICON:- } " " ${COMMAND_DURATION_COLOR:- } " " $minutes " " $seconds "
5456 elif (( seconds >= COMMAND_DURATION_MIN_SECONDS)) ; then
55- printf " %s%s%d.%01ds" " ${COMMAND_DURATION_ICON:- } " " ${COMMAND_DURATION_COLOR:- } " " $seconds " " $deciseconds "
57+ printf " %s %s%d.%01ds" " ${COMMAND_DURATION_ICON:- } " " ${COMMAND_DURATION_COLOR:- } " " $seconds " " $deciseconds "
5658 fi
5759}
5860
You can’t perform that action at this time.
0 commit comments