fish: show command duration after longer command
This commit is contained in:
parent
6b386be43b
commit
39dcb58a9b
1 changed files with 6 additions and 0 deletions
|
@ -107,6 +107,12 @@
|
||||||
|
|
||||||
fish_right_prompt.body = ''
|
fish_right_prompt.body = ''
|
||||||
fish_jj_prompt || fish_vcs_prompt
|
fish_jj_prompt || fish_vcs_prompt
|
||||||
|
if test $CMD_DURATION -gt 3000
|
||||||
|
# Show duration of the last command in seconds
|
||||||
|
set duration (echo "$CMD_DURATION 1000" | awk '{printf "%.1fs", $1 / $2}')
|
||||||
|
echo " ⏳$duration"
|
||||||
|
end
|
||||||
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
transient_prompt_func.body = ''
|
transient_prompt_func.body = ''
|
||||||
|
|
Loading…
Reference in a new issue