Show exec time after executing command
Published at 2024-05-07
Last update over 365 days ago
Licensed under CC BY-NC-SA 4.0
softwares-and-tools
fish
Show exec time after executing command
ref: https://www.reddit.com/r/fishshell/comments/4yyoi5/see_the_time_of_execution_after_the_end_of_a/
function printtime --on-event fish_postexec
set duration (echo "$CMD_DURATION 1000" | awk '{printf "%.3fs", $1 / $2}')
echo \t\($duration\)
end