diff options
author | Markus Heiser <markus.heiser@darmarit.de> | 2024-02-20 12:21:49 +0100 |
---|---|---|
committer | Markus Heiser <markus.heiser@darmarIT.de> | 2024-02-20 12:29:13 +0100 |
commit | 894f164869649b820e7d145d4017e59e256dd947 (patch) | |
tree | 537252c6edf805777bf4bea9f83d8569a481cb3a /searxng_extra | |
parent | ed66ed758dbd1c926296aa227da8a82fff9166e1 (diff) | |
download | searxng-894f164869649b820e7d145d4017e59e256dd947.tar.gz searxng-894f164869649b820e7d145d4017e59e256dd947.zip |
[fix] sort RTL_LOCALES before written into locales.json
To avoid unnecessary changes to the file, the list should be sorted before it is
written to the file.
You can test it by calling multiple times::
make data.locales
and searx/data/locales.json should be unchanged.
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'searxng_extra')
-rwxr-xr-x[-rw-r--r--] | searxng_extra/update/update_locales.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/searxng_extra/update/update_locales.py b/searxng_extra/update/update_locales.py index e823ebaf1..d97a5dd88 100644..100755 --- a/searxng_extra/update/update_locales.py +++ b/searxng_extra/update/update_locales.py @@ -58,7 +58,7 @@ def main(): content = { "LOCALE_NAMES": LOCALE_NAMES, - "RTL_LOCALES": list(RTL_LOCALES), + "RTL_LOCALES": sorted(RTL_LOCALES), } with open(LOCALE_DATA_FILE, 'w', encoding='utf-8') as f: |