[clock] Rewrite most of the module

Remove a few unused functions, and add ability for
users/channels to set their own formats for time.