emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@gmail.com>
To: tomas@tuxteam.de
Cc: emacs-orgmode@gnu.org
Subject: Re: org-time-stamp-custom-formats with out the name of the day of the week
Date: Sat, 03 Sep 2022 21:31:48 +0800	[thread overview]
Message-ID: <874jxo60u3.fsf@localhost> (raw)
In-Reply-To: <YxMByLv0SY1O8+ZF@tuxteam.de>

<tomas@tuxteam.de> writes:

>> This cannot currently be customized. However, you can change
>> org-time-stamp-formats constant. Removing the %a should be safe.
>
> FWIW, I have this in an (eval-after-load 'org ...)
>
>   (setq org-time-stamp-formats
>      '("<%Y-%m-%d>" ."<%Y-%m-%d %H:%M>"))
>
> since years (> 5) and haven't observed any side effects. But then
> I don't meet every nook and cranny of org (I bow in awe to those
> who meet half of them :-)

This only works because you changed org-time-stamp-formats in one of the
few safe ways.

Org declares org-time-stamp-formats and Org code treats its value as a
constant making various kinds of unsafe assumptions that can break
things if the value of org-time-stamp-formats is changed. For example,
it is assumed that first/last characters are triangular brackets; it is
assumed that the output can be parsed using parse-time-string; it is
assumed that 1..11 substring in the format contains a full date; it is
assumed that the formatted output conforms to timestamp syntax; etc.

-- 
Ihor Radchenko,
Org mode contributor,
Learn more about Org mode at https://orgmode.org/.
Support Org development at https://liberapay.com/org-mode,
or support my work at https://liberapay.com/yantar92


      reply	other threads:[~2022-09-03 13:33 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-31 15:59 org-time-stamp-custom-formats with out the name of the day of the week Uwe Brauer
2022-09-01  7:16 ` Ihor Radchenko
2022-09-01 15:50   ` Uwe Brauer
2022-09-02 13:01     ` Ihor Radchenko
2022-09-02 13:23       ` Uwe Brauer
2022-09-02 13:33         ` Ihor Radchenko
2022-09-03  7:27           ` tomas
2022-09-03 13:31             ` Ihor Radchenko [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.orgmode.org/

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

  git send-email \
    --in-reply-to=874jxo60u3.fsf@localhost \
    --to=yantar92@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=tomas@tuxteam.de \
    /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/org-mode.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).