This repository was archived by the owner on Apr 26, 2021. It is now read-only.
Added mlbstreamer config option for 24h military time#21
Open
snipem wants to merge 2 commits into
Open
Conversation
Contributor
|
I think it would be better to use the user's locale settings instead of adding an application-specific parameter for this. Something like this, from https://stackoverflow.com/questions/41864935/how-can-i-check-if-the-current-locale-uses-am-pm-or-24-hour-time?rq=1 should work. |
Contributor
Author
|
This would be the best solution and I was searching for a similar approach. Unfortunately, on my German installation also the "AM" flag is returned: The aforementioned code might not solve the problem and won't determine safely if the users locale does normally show AM or PM times. |
Contributor
|
You are of course correct. My bad. It seems you can use this using babel which comes with its own set of mappings |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added option for setting 24 hour time aka military time:
This option can be set by inserting
military_time: trueinto$HOME/.config/mlbstreamer/config.yaml.If nothing is set or
military_timeis set tofalsethe default 12 hour formatting is used.