From 008fbf78a52155adf7d3ac6e28c4fa0cae0b2239 Mon Sep 17 00:00:00 2001 From: peace-maker Date: Thu, 30 Mar 2023 01:13:40 +0200 Subject: [PATCH] Cleanup the translation files (#1962) * Remove obsolete slapslay.phrases.txt That plugin isn't in the stock arsenal since forever. * Remove "Dead Player Rename" phrase Unused since #313 * Remove nominations phrases from rockthevote Those phrases were moved to their own nominations.phrases.txt * Remove "Next Map" phrase from nextmap.phrases.txt It was moved to basetriggers.phrases.txt * Remove unused phrases from common.phrases.txt Only "Slapped Player" was moved to funvotes.phrases.txt * Delete empty phrase files * Fix workflow python version selection 3.10 would select Python 3.1 and fail * Deduplicate "Please select a map" phrase Only keep it in the plugin.basecommands.txt file and remove it from the basevotes.phrases.txt. Both plugins using the phrase load the basecommands phrases. * Allow manual triggering of translations action * Actually use the nextmap phrases They were never referenced in the plugin. The "ago" phrase doesn't work the way it is and needs more rethinking. --- .github/workflows/translations.yml | 4 +- plugins/nextmap.sp | 6 +- translations/ar/basevotes.phrases.txt | 5 -- translations/ar/common.phrases.txt | 20 ------ translations/ar/nextmap.phrases.txt | 5 -- translations/ar/playercommands.phrases.txt | 5 -- translations/ar/plugin.basecommands.txt | 5 ++ translations/ar/rockthevote.phrases.txt | 35 ---------- translations/basevotes.phrases.txt | 5 -- translations/bg/antiflood.phrases.txt | 3 - translations/bg/common.phrases.txt | 15 ---- translations/bg/funvotes.phrases.txt | 4 ++ translations/bg/nextmap.phrases.txt | 5 -- translations/bg/playercommands.phrases.txt | 5 -- translations/bg/rockthevote.phrases.txt | 3 - translations/bg/sounds.phrases.txt | 3 - translations/bg/sqladmins.phrases.txt | 3 - translations/chi/basevotes.phrases.txt | 5 -- translations/chi/common.phrases.txt | 20 ------ translations/chi/nextmap.phrases.txt | 5 -- translations/chi/playercommands.phrases.txt | 5 -- translations/chi/plugin.basecommands.txt | 5 ++ translations/chi/rockthevote.phrases.txt | 35 ---------- translations/chi/slapslay.phrases.txt | 28 -------- translations/cze/basevotes.phrases.txt | 5 -- translations/cze/common.phrases.txt | 20 ------ translations/cze/nextmap.phrases.txt | 5 -- translations/cze/playercommands.phrases.txt | 5 -- translations/cze/rockthevote.phrases.txt | 35 ---------- translations/da/basevotes.phrases.txt | 5 -- translations/da/common.phrases.txt | 20 ------ translations/da/nextmap.phrases.txt | 5 -- translations/da/playercommands.phrases.txt | 5 -- translations/da/plugin.basecommands.txt | 5 ++ translations/da/rockthevote.phrases.txt | 35 ---------- translations/da/slapslay.phrases.txt | 28 -------- translations/de/basevotes.phrases.txt | 5 -- translations/de/common.phrases.txt | 20 ------ translations/de/nextmap.phrases.txt | 5 -- translations/de/playercommands.phrases.txt | 5 -- translations/de/plugin.basecommands.txt | 5 ++ translations/de/rockthevote.phrases.txt | 35 ---------- translations/de/slapslay.phrases.txt | 28 -------- translations/el/basevotes.phrases.txt | 5 -- translations/el/common.phrases.txt | 20 ------ translations/el/nextmap.phrases.txt | 5 -- translations/el/playercommands.phrases.txt | 5 -- translations/el/plugin.basecommands.txt | 5 ++ translations/el/rockthevote.phrases.txt | 35 ---------- translations/es/basevotes.phrases.txt | 5 -- translations/es/common.phrases.txt | 20 ------ translations/es/nextmap.phrases.txt | 5 -- translations/es/playercommands.phrases.txt | 5 -- translations/es/rockthevote.phrases.txt | 35 ---------- translations/es/slapslay.phrases.txt | 28 -------- translations/fi/basevotes.phrases.txt | 5 -- translations/fi/common.phrases.txt | 20 ------ translations/fi/nextmap.phrases.txt | 5 -- translations/fi/playercommands.phrases.txt | 5 -- translations/fi/rockthevote.phrases.txt | 35 ---------- translations/fr/basevotes.phrases.txt | 5 -- translations/fr/common.phrases.txt | 20 ------ translations/fr/nextmap.phrases.txt | 5 -- translations/fr/playercommands.phrases.txt | 5 -- translations/fr/plugin.basecommands.txt | 5 ++ translations/fr/rockthevote.phrases.txt | 35 ---------- translations/fr/slapslay.phrases.txt | 73 -------------------- translations/he/basetriggers.phrases.txt | 3 - translations/he/basevotes.phrases.txt | 3 - translations/he/clientprefs.phrases.txt | 3 - translations/he/common.phrases.txt | 3 - translations/he/funvotes.phrases.txt | 3 - translations/he/mapchooser.phrases.txt | 3 - translations/he/nextmap.phrases.txt | 3 - translations/he/nominations.phrases.txt | 3 - translations/he/plugin.basecommands.txt | 3 - translations/he/reservedslots.phrases.txt | 3 - translations/he/rockthevote.phrases.txt | 3 - translations/he/sounds.phrases.txt | 3 - translations/he/sqladmins.phrases.txt | 3 - translations/hu/basevotes.phrases.txt | 5 -- translations/hu/common.phrases.txt | 20 ------ translations/hu/nextmap.phrases.txt | 5 -- translations/hu/playercommands.phrases.txt | 5 -- translations/hu/plugin.basecommands.txt | 5 ++ translations/hu/rockthevote.phrases.txt | 35 ---------- translations/hu/slapslay.phrases.txt | 28 -------- translations/it/basevotes.phrases.txt | 5 -- translations/it/common.phrases.txt | 20 ------ translations/it/nextmap.phrases.txt | 5 -- translations/it/playercommands.phrases.txt | 5 -- translations/it/plugin.basecommands.txt | 5 ++ translations/it/rockthevote.phrases.txt | 35 ---------- translations/jp/basevotes.phrases.txt | 5 -- translations/jp/common.phrases.txt | 20 ------ translations/jp/nextmap.phrases.txt | 5 -- translations/jp/playercommands.phrases.txt | 5 -- translations/jp/plugin.basecommands.txt | 5 ++ translations/jp/rockthevote.phrases.txt | 35 ---------- translations/jp/slapslay.phrases.txt | 28 -------- translations/ko/basevotes.phrases.txt | 5 -- translations/ko/common.phrases.txt | 20 ------ translations/ko/nextmap.phrases.txt | 5 -- translations/ko/playercommands.phrases.txt | 5 -- translations/ko/rockthevote.phrases.txt | 35 ---------- translations/las/basevotes.phrases.txt | 5 -- translations/las/common.phrases.txt | 20 ------ translations/las/nextmap.phrases.txt | 5 -- translations/las/playercommands.phrases.txt | 5 -- translations/las/rockthevote.phrases.txt | 35 ---------- translations/las/slapslay.phrases.txt | 28 -------- translations/lt/basevotes.phrases.txt | 5 -- translations/lt/common.phrases.txt | 20 ------ translations/lt/nextmap.phrases.txt | 5 -- translations/lt/playercommands.phrases.txt | 5 -- translations/lt/plugin.basecommands.txt | 5 ++ translations/lt/rockthevote.phrases.txt | 35 ---------- translations/lv/basevotes.phrases.txt | 5 -- translations/lv/common.phrases.txt | 20 ------ translations/lv/nextmap.phrases.txt | 5 -- translations/lv/playercommands.phrases.txt | 5 -- translations/lv/plugin.basecommands.txt | 5 ++ translations/lv/rockthevote.phrases.txt | 35 ---------- translations/lv/slapslay.phrases.txt | 28 -------- translations/nl/basevotes.phrases.txt | 5 -- translations/nl/common.phrases.txt | 20 ------ translations/nl/nextmap.phrases.txt | 5 -- translations/nl/playercommands.phrases.txt | 5 -- translations/nl/rockthevote.phrases.txt | 35 ---------- translations/no/basevotes.phrases.txt | 3 - translations/no/clientprefs.phrases.txt | 3 - translations/no/common.phrases.txt | 3 - translations/no/core.phrases.txt | 3 - translations/no/funcommands.phrases.txt | 3 - translations/no/funvotes.phrases.txt | 3 - translations/no/mapchooser.phrases.txt | 3 - translations/no/nextmap.phrases.txt | 3 - translations/no/nominations.phrases.txt | 3 - translations/no/playercommands.phrases.txt | 3 - translations/no/plugin.basecommands.txt | 3 - translations/no/reservedslots.phrases.txt | 3 - translations/no/rockthevote.phrases.txt | 3 - translations/no/slapslay.phrases.txt | 28 -------- translations/no/sounds.phrases.txt | 3 - translations/no/sqladmins.phrases.txt | 3 - translations/pl/basevotes.phrases.txt | 5 -- translations/pl/common.phrases.txt | 20 ------ translations/pl/nextmap.phrases.txt | 5 -- translations/pl/playercommands.phrases.txt | 5 -- translations/pl/rockthevote.phrases.txt | 35 ---------- translations/pl/slapslay.phrases.txt | 28 -------- translations/pt/basevotes.phrases.txt | 5 -- translations/pt/common.phrases.txt | 20 ------ translations/pt/nextmap.phrases.txt | 5 -- translations/pt/playercommands.phrases.txt | 5 -- translations/pt/rockthevote.phrases.txt | 35 ---------- translations/pt/slapslay.phrases.txt | 28 -------- translations/pt_p/basevotes.phrases.txt | 5 -- translations/pt_p/common.phrases.txt | 20 ------ translations/pt_p/nextmap.phrases.txt | 5 -- translations/pt_p/playercommands.phrases.txt | 5 -- translations/pt_p/plugin.basecommands.txt | 5 ++ translations/pt_p/rockthevote.phrases.txt | 35 ---------- translations/ro/basetriggers.phrases.txt | 2 +- translations/ro/basevotes.phrases.txt | 5 -- translations/ro/common.phrases.txt | 20 ------ translations/ro/nextmap.phrases.txt | 5 -- translations/ro/playercommands.phrases.txt | 5 -- translations/ro/rockthevote.phrases.txt | 35 ---------- translations/ro/slapslay.phrases.txt | 28 -------- translations/ru/basevotes.phrases.txt | 5 -- translations/ru/common.phrases.txt | 20 ------ translations/ru/nextmap.phrases.txt | 5 -- translations/ru/playercommands.phrases.txt | 5 -- translations/ru/rockthevote.phrases.txt | 35 ---------- translations/ru/slapslay.phrases.txt | 28 -------- translations/sk/basevotes.phrases.txt | 5 -- translations/sk/common.phrases.txt | 20 ------ translations/sk/nextmap.phrases.txt | 5 -- translations/sk/playercommands.phrases.txt | 5 -- translations/sk/rockthevote.phrases.txt | 35 ---------- translations/sv/basevotes.phrases.txt | 5 -- translations/sv/common.phrases.txt | 20 ------ translations/sv/nextmap.phrases.txt | 5 -- translations/sv/playercommands.phrases.txt | 5 -- translations/sv/plugin.basecommands.txt | 5 ++ translations/sv/rockthevote.phrases.txt | 35 ---------- translations/sv/slapslay.phrases.txt | 28 -------- translations/th/.gitkeep | 0 translations/th/adminhelp.phrases.txt | 3 - translations/th/adminmenu.phrases.txt | 3 - translations/th/antiflood.phrases.txt | 3 - translations/th/basebans.phrases.txt | 3 - translations/th/basecomm.phrases.txt | 3 - translations/th/basetriggers.phrases.txt | 3 - translations/th/basevotes.phrases.txt | 3 - translations/th/clientprefs.phrases.txt | 3 - translations/th/common.phrases.txt | 3 - translations/th/core.phrases.txt | 3 - translations/th/funcommands.phrases.txt | 3 - translations/th/funvotes.phrases.txt | 3 - translations/th/mapchooser.phrases.txt | 3 - translations/th/nextmap.phrases.txt | 3 - translations/th/nominations.phrases.txt | 3 - translations/th/playercommands.phrases.txt | 3 - translations/th/plugin.basecommands.txt | 3 - translations/th/reservedslots.phrases.txt | 3 - translations/th/rockthevote.phrases.txt | 3 - translations/th/sounds.phrases.txt | 3 - translations/th/sqladmins.phrases.txt | 3 - translations/tr/basevotes.phrases.txt | 5 -- translations/tr/common.phrases.txt | 20 ------ translations/tr/funvotes.phrases.txt | 2 +- translations/tr/nextmap.phrases.txt | 5 -- translations/tr/playercommands.phrases.txt | 5 -- translations/tr/plugin.basecommands.txt | 5 ++ translations/tr/rockthevote.phrases.txt | 35 ---------- translations/tr/slapslay.phrases.txt | 28 -------- translations/ua/basevotes.phrases.txt | 5 -- translations/ua/common.phrases.txt | 20 ------ translations/ua/nextmap.phrases.txt | 5 -- translations/ua/playercommands.phrases.txt | 5 -- translations/ua/rockthevote.phrases.txt | 35 ---------- translations/vi/basevotes.phrases.txt | 5 -- translations/vi/common.phrases.txt | 20 ------ translations/vi/nextmap.phrases.txt | 5 -- translations/vi/playercommands.phrases.txt | 5 -- translations/vi/rockthevote.phrases.txt | 35 ---------- translations/zho/basevotes.phrases.txt | 5 -- translations/zho/common.phrases.txt | 20 ------ translations/zho/nextmap.phrases.txt | 5 -- translations/zho/playercommands.phrases.txt | 5 -- translations/zho/plugin.basecommands.txt | 5 ++ translations/zho/rockthevote.phrases.txt | 35 ---------- 234 files changed, 86 insertions(+), 2649 deletions(-) delete mode 100644 translations/bg/antiflood.phrases.txt delete mode 100644 translations/bg/rockthevote.phrases.txt delete mode 100644 translations/bg/sounds.phrases.txt delete mode 100644 translations/bg/sqladmins.phrases.txt delete mode 100644 translations/chi/slapslay.phrases.txt delete mode 100644 translations/da/slapslay.phrases.txt delete mode 100644 translations/de/slapslay.phrases.txt delete mode 100644 translations/es/slapslay.phrases.txt delete mode 100644 translations/fr/slapslay.phrases.txt delete mode 100644 translations/he/basetriggers.phrases.txt delete mode 100644 translations/he/basevotes.phrases.txt delete mode 100644 translations/he/clientprefs.phrases.txt delete mode 100644 translations/he/common.phrases.txt delete mode 100644 translations/he/funvotes.phrases.txt delete mode 100644 translations/he/mapchooser.phrases.txt delete mode 100644 translations/he/nextmap.phrases.txt delete mode 100644 translations/he/nominations.phrases.txt delete mode 100644 translations/he/plugin.basecommands.txt delete mode 100644 translations/he/reservedslots.phrases.txt delete mode 100644 translations/he/rockthevote.phrases.txt delete mode 100644 translations/he/sounds.phrases.txt delete mode 100644 translations/he/sqladmins.phrases.txt delete mode 100644 translations/hu/slapslay.phrases.txt delete mode 100644 translations/jp/slapslay.phrases.txt delete mode 100644 translations/las/slapslay.phrases.txt delete mode 100644 translations/lv/slapslay.phrases.txt delete mode 100644 translations/no/basevotes.phrases.txt delete mode 100644 translations/no/clientprefs.phrases.txt delete mode 100644 translations/no/common.phrases.txt delete mode 100644 translations/no/core.phrases.txt delete mode 100644 translations/no/funcommands.phrases.txt delete mode 100644 translations/no/funvotes.phrases.txt delete mode 100644 translations/no/mapchooser.phrases.txt delete mode 100644 translations/no/nextmap.phrases.txt delete mode 100644 translations/no/nominations.phrases.txt delete mode 100644 translations/no/playercommands.phrases.txt delete mode 100644 translations/no/plugin.basecommands.txt delete mode 100644 translations/no/reservedslots.phrases.txt delete mode 100644 translations/no/rockthevote.phrases.txt delete mode 100644 translations/no/slapslay.phrases.txt delete mode 100644 translations/no/sounds.phrases.txt delete mode 100644 translations/no/sqladmins.phrases.txt delete mode 100644 translations/pl/slapslay.phrases.txt delete mode 100644 translations/pt/slapslay.phrases.txt delete mode 100644 translations/ro/slapslay.phrases.txt delete mode 100644 translations/ru/slapslay.phrases.txt delete mode 100644 translations/sv/slapslay.phrases.txt create mode 100644 translations/th/.gitkeep delete mode 100644 translations/th/adminhelp.phrases.txt delete mode 100644 translations/th/adminmenu.phrases.txt delete mode 100644 translations/th/antiflood.phrases.txt delete mode 100644 translations/th/basebans.phrases.txt delete mode 100644 translations/th/basecomm.phrases.txt delete mode 100644 translations/th/basetriggers.phrases.txt delete mode 100644 translations/th/basevotes.phrases.txt delete mode 100644 translations/th/clientprefs.phrases.txt delete mode 100644 translations/th/common.phrases.txt delete mode 100644 translations/th/core.phrases.txt delete mode 100644 translations/th/funcommands.phrases.txt delete mode 100644 translations/th/funvotes.phrases.txt delete mode 100644 translations/th/mapchooser.phrases.txt delete mode 100644 translations/th/nextmap.phrases.txt delete mode 100644 translations/th/nominations.phrases.txt delete mode 100644 translations/th/playercommands.phrases.txt delete mode 100644 translations/th/plugin.basecommands.txt delete mode 100644 translations/th/reservedslots.phrases.txt delete mode 100644 translations/th/rockthevote.phrases.txt delete mode 100644 translations/th/sounds.phrases.txt delete mode 100644 translations/th/sqladmins.phrases.txt delete mode 100644 translations/tr/slapslay.phrases.txt diff --git a/.github/workflows/translations.yml b/.github/workflows/translations.yml index fd491f6d..1b086099 100644 --- a/.github/workflows/translations.yml +++ b/.github/workflows/translations.yml @@ -5,6 +5,7 @@ on: - master paths: - 'translations/**' + workflow_dispatch: jobs: update_translations: runs-on: ubuntu-latest @@ -12,7 +13,7 @@ jobs: - uses: actions/setup-python@v4 name: Setup Python 3.10 with: - python-version: 3.10 + python-version: "3.10" - name: Install Python dependencies working-directory: tools/language_check @@ -35,4 +36,3 @@ jobs: run: | python ./compare_translation_phrases.py - \ No newline at end of file diff --git a/plugins/nextmap.sp b/plugins/nextmap.sp index 755c8417..e793ad6b 100644 --- a/plugins/nextmap.sp +++ b/plugins/nextmap.sp @@ -191,11 +191,11 @@ public Action Command_MapHistory(int client, int args) int lastMapStartTime = g_CurrentMapStartTime; - PrintToConsole(client, "Map History:\n"); - PrintToConsole(client, "Map : Started : Played Time : Reason for ending"); + PrintToConsole(client, "%t:\n", "Map History"); + PrintToConsole(client, "%t : %t : %t : %t", "Map", "Started", "Played Time", "Reason"); GetCurrentMap(mapName, sizeof(mapName)); - PrintToConsole(client, "%02i. %s (Current Map)", 0, mapName); + PrintToConsole(client, "%02i. %s (%t)", 0, mapName, "Current Map"); for (int i=0; i