Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: PATCH: strftime builtin

Clint Adams wrote:
> > The strftime formats are probably pretty useless without a strftime
> > builtin.
> This probably doesn't belong in the zsh/langinfo module.
> Should it get its own module?
> interim documentation: strftime format secs_since_epoch

You should probably use zsh's own function ztrftime (in utils.c), which
calls strftime if that's available, else does some of the simpler formats,
and makes a couple of extra formats available.  If that doesn't seem
appropriate for some reason, at least test for HAVE_STRFTIME which is
already handled by configure.

I suppose it would be better in its own module, or else a module
timeutils or stringutils if there's any more stuff that can usefully be

Peter Stephenson <pws@xxxxxxx>                  Software Engineer
CSR Ltd., Science Park, Milton Road,
Cambridge, CB4 0WH, UK                          Tel: +44 (0)1223 392070

The information transmitted is intended only for the person or
entity to which it is addressed and may contain confidential 
and/or privileged material. 
Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by 
persons or entities other than the intended recipient is 
If you received this in error, please contact the sender and 
delete the material from any computer.

Messages sorted by: Reverse Date, Date, Thread, Author