mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
9 lines
338 B
Text
9 lines
338 B
Text
|
|
## Given an interval, returns a string of the form 3m34s to
|
|
## give a minimalized human readable string for the minutes
|
|
## and seconds represented by the interval.
|
|
function duration_to_mins_secs(dur: interval): string
|
|
{
|
|
local dur_count = double_to_count(interval_to_double(dur));
|
|
return fmt("%dm%ds", dur_count/60, dur_count%60);
|
|
}
|