unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Juri Linkov <juri@jurta.org>
To: MON KEY <monkey@sandpframing.com>
Cc: emacs-devel@gnu.org
Subject: Re: Can `format-time-string' produce full/extended ISO 8601 times?
Date: Thu, 06 Aug 2009 23:41:28 +0300	[thread overview]
Message-ID: <87d478n093.fsf@mail.jurta.org> (raw)
In-Reply-To: <d2afcfda0908061139o2be96033vf66ebdbf704e61e7@mail.gmail.com> (MON KEY's message of "Thu, 6 Aug 2009 14:39:20 -0400")

> To reiterate, the gist of my query is this:
>
>   Is it possible to format the UTC offset/ZONE with a colon per the
> 'Extended format?

I looked briefly at the implementation of time formatting in Emacs
and see that it is an old copy of the function `strftime' from gnulib.
I wonder is it possible to call this function directly from the library
where it already has more supported formats including time zones with
a colon:

`%z'
     RFC 2822/ISO 8601 style numeric time zone (e.g., `-0600' or
     `+0530'), or nothing if no time zone is determinable.
     This is a GNU extension.

`%:z'
     RFC 3339/ISO 8601 style numeric time zone with `:' (e.g., `-06:00'
     or `+05:30'), or nothing if no time zone is determinable.  This is
     a GNU extension.

`%::z'
     Numeric time zone to the nearest second with `:' (e.g.,
     `-06:00:00' or `+05:30:00'), or nothing if no time zone is
     determinable.  This is a GNU extension.

`%:::z'
     Numeric time zone with `:' using the minimum necessary precision
     (e.g., `-06', `+05:30', or `-04:56:02'), or nothing if no time
     zone is determinable.  This is a GNU extension.

-- 
Juri Linkov
http://www.jurta.org/emacs/




      parent reply	other threads:[~2009-08-06 20:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-30 22:10 Can `format-time-string' produce full/extended ISO 8601 times? MON KEY
2009-08-02 23:52 ` Juri Linkov
2009-08-06 18:39   ` MON KEY
2009-08-06 18:47     ` Edward O'Connor
2009-08-06 20:41     ` Juri Linkov [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d478n093.fsf@mail.jurta.org \
    --to=juri@jurta.org \
    --cc=emacs-devel@gnu.org \
    --cc=monkey@sandpframing.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).