bastibe / org-journal

A simple org-mode based journaling mode
BSD 3-Clause "New" or "Revised" License
1.23k stars 122 forks source link

fix: do not error out on timestamps with extra components #407

Closed xeruf closed 1 year ago

xeruf commented 1 year ago

When a timestamp contains items beyond the date, org-journal used to error out. Now it simply ignores them.

Has been in production use by me in the last months.

fix https://github.com/bastibe/org-journal/issues/397

bastibe commented 1 year ago

I don't think I fully grasp the regexp magic you did there. Could you give an example of what "[]>]$" and "[A-z0-9: ]*\\&" refer to in practice? (and probably add that as a comment in the code as well)

xeruf commented 1 year ago

honestly, I forgot too, and don't quite understand it anymore :sweat_smile: let me test what happens without it and report back

xeruf commented 1 year ago

ah, now I know: it adds matching for weekday and time to the timestamp regex, to fix https://github.com/bastibe/org-journal/issues/397

bastibe commented 1 year ago

So it replaces any remaining matchers in the square brackets with a non-capturing wildcard match? That sounds reasonable.

👍