[IMP] todo menus: language only in Configuration, Fork moved there

Execute carried a Preferences section whose one entry, the language, is
already Configuration's first item: two places for one setting. It is
removed, with its two unused translations. Fork, which opens a second TODO,
leaves the main menu for Configuration; the main menu now numbers Telemetry
4 and Configuration 5, and Reset all preferences becomes 6.
Checked: Configuration displayed with Fork at 5; 108 tests pass.

--- FR ---

[IMP] menus todo : langue dans Configuration seule, Fork y déménage

Execute portait une section Préférences dont la seule entrée, la langue, est
déjà la première de Configuration : deux endroits pour un réglage. Elle part,
avec ses deux traductions devenues inutiles. Fork, qui ouvre un second TODO,
quitte le menu principal pour Configuration ; le menu principal numérote
désormais Télémétrie 4 et Configuration 5, et la réinitialisation devient 6.
Vérifié : Configuration affichée avec Fork en 5 ; 108 tests passent.

Assisted-by: Claude Opus 5.5
This commit is contained in:
Mathieu Benoit 2026-09-25 01:41:48 -04:00
parent 7c1f8c4e71
commit 034d40d403
2 changed files with 8 additions and 26 deletions

View file

@ -253,9 +253,8 @@ class TODO(
[1] {t("Execute")} [1] {t("Execute")}
[2] {t("Install")} [2] {t("Install")}
[3] {t("Assistant")} [3] {t("Assistant")}
[4] {t("Fork - Open TODO in a new tab")} [4] {t("Navigation telemetry (TUI)")}
[5] {t("Navigation telemetry (TUI)")} [5] {t("Configuration")}
[6] {t("Configuration")}
[0] 🚪 {t("Quit")} [0] 🚪 {t("Quit")}
""" """
while True: while True:
@ -281,15 +280,8 @@ class TODO(
elif status == "3": elif status == "3":
self.prompt_assistant() self.prompt_assistant()
elif status == "4": elif status == "4":
# cmd = (
# f"gnome-terminal --tab -- bash -c 'source"
# f" ./{VENV_ERPLIBRE}/bin/activate;make todo'"
# )
cmd = "make todo"
self.execute.exec_command_live(cmd, source_erplibre=True)
elif status == "5":
self._todo_telemetry_tui() self._todo_telemetry_tui()
elif status == "6": elif status == "5":
self.prompt_configuration() self.prompt_configuration()
# elif status == "3" or status == "install": # elif status == "3" or status == "install":
# print("install") # print("install")
@ -346,9 +338,6 @@ class TODO(
[13] {t("Deploy - Deploy ERPLibre locally")} [13] {t("Deploy - Deploy ERPLibre locally")}
[14] {t("Network - Network tools")} [14] {t("Network - Network tools")}
[15] {t("Security - Dependency security audit")} [15] {t("Security - Dependency security audit")}
── {t("Preferences")} ──
[16] {t("Language - Change language / Changer la langue")}
[0] {t("Back")} [0] {t("Back")}
""" """
while True: while True:
@ -416,10 +405,6 @@ class TODO(
status = self.prompt_execute_security() status = self.prompt_execute_security()
if status is not False: if status is not False:
return return
elif status == "16":
status = self._change_language()
if status is not False:
return
else: else:
print(t("Command not found !")) print(t("Command not found !"))
@ -869,6 +854,7 @@ class TODO(
f"({self._pref_label('migration_ui')})" f"({self._pref_label('migration_ui')})"
) )
}, },
{"prompt_description": t("Fork - Open TODO in a new tab")},
{"section": t("Maintenance")}, {"section": t("Maintenance")},
{"prompt_description": t("Reset all preferences")}, {"prompt_description": t("Reset all preferences")},
] ]
@ -885,6 +871,10 @@ class TODO(
elif status == "4": elif status == "4":
self._pref_edit("migration_ui") self._pref_edit("migration_ui")
elif status == "5": elif status == "5":
self.execute.exec_command_live(
"make todo", source_erplibre=True
)
elif status == "6":
n = todo_prefs.reset() n = todo_prefs.reset()
print(f"✅ {t('Preferences reset')} ({n})") print(f"✅ {t('Preferences reset')} ({n})")
else: else:

View file

@ -100,10 +100,6 @@ TRANSLATIONS = {
"fr": "🪙 RTK - Proxy CLI pour réduire la consommation de tokens LLM", "fr": "🪙 RTK - Proxy CLI pour réduire la consommation de tokens LLM",
"en": "🪙 RTK - CLI proxy to reduce LLM token consumption", "en": "🪙 RTK - CLI proxy to reduce LLM token consumption",
}, },
"Language - Change language / Changer la langue": {
"fr": "🌍 Langue - Changer la langue / Change language",
"en": "🌍 Language - Change language / Changer la langue",
},
# Deploy section # Deploy section
"Deploy - Deploy ERPLibre locally": { "Deploy - Deploy ERPLibre locally": {
"fr": "🚀 Déploiement - Déployer ERPLibre localement", "fr": "🚀 Déploiement - Déployer ERPLibre localement",
@ -185,10 +181,6 @@ TRANSLATIONS = {
"fr": "🌐 Déploiement, réseau & sécurité", "fr": "🌐 Déploiement, réseau & sécurité",
"en": "🌐 Deployment, network & security", "en": "🌐 Deployment, network & security",
}, },
"Preferences": {
"fr": "🎨 Préférences",
"en": "🎨 Preferences",
},
"Deployment": { "Deployment": {
"fr": "🚀 Déploiement", "fr": "🚀 Déploiement",
"en": "🚀 Deployment", "en": "🚀 Deployment",