Skip to content
This repository has been archived by the owner on Aug 7, 2021. It is now read-only.

Duration formatting fix #6

Merged
merged 1 commit into from Mar 30, 2011
Merged

Duration formatting fix #6

merged 1 commit into from Mar 30, 2011

Conversation

akaihola
Copy link
Contributor

Hi,

PyOrgMode keeps original formatting amazinlgy well when loading and saving an org-mode file. The only quirks I found were in date/time formatting.

Org-mode uses local weekday abbreviations, and PyOrgMode does write them correctly as long as the locale is set correctly (locale.setlocale()). I can't see an easy way to auto-detect the locale an .org file was written in, so this must be left to the user to take care of.

I fixed duration formatting to omit the leading zero of the hour just like org-mode does. I verified that org-mode does not use leading zeros in the C, en-US nor fi-FI locales. It might or might not do so in other locales – I haven't verified the Elisp code.

Anyway, great stuff, hope you appreciate the patch.

Antti

@bjonnh bjonnh merged commit 6f2ddea into bjonnh:master Mar 30, 2011
@bjonnh
Copy link
Owner

bjonnh commented Mar 30, 2011

Thanks for your help ! It doesn't seems that Org mode takes care of the weekday abbreviation (I may be wrong). Maybe a parameter on the beginning on the file would do the trick… What do you think about this way of circumventing the problem ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants