localseconds string - part-cw/lambdanative GitHub Wiki
(localseconds->string sec fmt)
localseconds->string converts seconds to string, specified in format. Uses UTC, e.g. for relative times.
Parameter | Description |
---|---|
sec | Seconds (Unix epoch) value to be converted |
fmt | Output string format. Accepting printf % notation and SRFI-19 ~ notation |
Example
Example 1: Get timestamp of now on the UTC clock
> (localseconds->string (current-time-seconds) "%Y-%m-%d %H:%M:%S")
"2013-08-09 06:25:46"