aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorromkatv <roman.perepelitsa@gmail.com>2019-07-16 01:47:50 +0300
committerromkatv <roman.perepelitsa@gmail.com>2019-07-16 01:50:37 +0300
commit06aa8da96e68d6e9aaaee065c34e1e96520e20d5 (patch)
treef94d118bda03f8332131a8b50ee18e4de0ddcb64
parent0eff9fe1b90b07ddd53502d604186ad2bd6ebe5b (diff)
round to seconds instead of truncating
-rwxr-xr-xinternal/p10k.zsh2
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/p10k.zsh b/internal/p10k.zsh
index 9201dafe..9e0630e6 100755
--- a/internal/p10k.zsh
+++ b/internal/p10k.zsh
@@ -926,7 +926,7 @@ prompt_command_execution_time() {
if (( _P9K_COMMAND_DURATION < 60 )); then
if [[ $POWERLEVEL9K_COMMAND_EXECUTION_TIME_PRECISION == 0 ]]; then
- local -i sec=_P9K_COMMAND_DURATION
+ local -i sec=$((_P9K_COMMAND_DURATION + 0.5))
else
local -F $POWERLEVEL9K_COMMAND_EXECUTION_TIME_PRECISION sec=_P9K_COMMAND_DURATION
fi