0

In org mode I use a german time format for timestamps

(setq org-time-stamp-custom-formats '("<%a. %d.%m.%Y>" . "<%a. %d.%m.%Y %H:%M>"))

For example <Fr. 25.06.2021>. Internally this is represented as <2021-06-25 Fr>.

So, I can for example isearch-forward for 06-25 to find the time stamp, but searching for 25.06. doesn't work.

Is there any way to configure emacs such that it works to useisearch-forward for a substring of the german time stamp representation?

1 Answer 1

0

org-times-stamp-custom-formats affects the display of time stamps: it does not affect how the time stamp is stored in the file. isearch on the other hand does not care about how the display looks; it only cares about what's in the buffer.

So I believe the answer to your question is "no".

The custom time stamp format is implemented using overlays (do C-h i g (elisp) Overlays to read about them). You might be able to cobble up something using the functions described there, but I think it is going to be a fairly fragile thing.

Org mode really only supports the ISO time stamp format, so you are probably better off remembering that and using ISO format (sub)expressions for searching.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.