4 ms·
Read this thread [1] at the Zsh mailing list to the end. It looks like either share_history or inc_append_history break recording duration in a fundamental way
by cb321 6y ago
Read this thread [1] at the Zsh mailing list to the end.
It looks like either share_history or inc_append_history break recording duration in a fundamental way. The TL;DR is that the history line is written out before the command in question completes. I guess the thinking is that inc/shared history with some very long running command is not as useful if you wait until it ends and you have elapsed time data to append that line. I feel like that might be a personal issue - like if you almost only ever run commands 1-90 seconds then you are fine with the delay.
Anyway, this also explains why it is available from the `history -fD` command but not in the file.
[1] https://www.zsh.org/mla/workers/2011/msg01297.html https://www.zsh.org/mla/workers/2011/msg01297.html