Is it possible to change the default language?
saltasatelites opened this issue · comments
Hello.
In your old python script, user @PavlosMelissinos made some changes to read the results in another language, specifically in Greek https://github.com/PavlosMelissinos/dotfiles/blob/166bced1541e47632f34f4f4de081fecc882eb64/.config/waybar/waybar-wttr.py and I did the same in my language. Would it be possible to do something similar in this new script? My Rust skills are minimal.
Regards
Hey @saltasatelites , I'm reopening it because I think it could be a nice idea to allow configuring the language through the toml config file.
Hi bjesus
I have closed it for the lack of information by my side and vampirism. My idea was to play around with Rust and open a new topic if necessary.
Thanks for reopening it!
Hi @bjesus
I've been playing with the variable --Accept-Language but for now with no result, so I haven't nothing to show..
Maybe if you want and /or you have time you could take a look..
https://github.com/chubin/wttr.in#internationalization-and-localization
Thanks
For json output &lang=
property or Accept-Language
header adds only a localized json field "lang_<LANG_CODE>" with weather type information inside current_condition
. It does not localize area info or astronomy, so almost all localization should be implemented inside wttrbar.
thanks to @s1ls this is now finally possible! 🥳