[IMP] script todo: dashboard de suivi — défaut OUI
« Suivi interactif (dashboard) ? » répondait NON par défaut (réponse vide). Le défaut est désormais OUI : nouveau helper _is_yes_default_yes (vide = oui) et libellé « (O/n, défaut : oui) » / « (Y/n, default: yes) ». Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
e3c548e57b
commit
c60b3f5cbd
2 changed files with 9 additions and 3 deletions
|
|
@ -2345,6 +2345,12 @@ class TODO:
|
|||
"""Réponse affirmative, FR et EN (o/oui/y/yes)."""
|
||||
return ans.strip().lower() in ("y", "yes", "o", "oui")
|
||||
|
||||
@staticmethod
|
||||
def _is_yes_default_yes(ans):
|
||||
"""Comme _is_yes mais le DÉFAUT (réponse vide) est OUI."""
|
||||
a = ans.strip().lower()
|
||||
return a == "" or a in ("y", "yes", "o", "oui")
|
||||
|
||||
@staticmethod
|
||||
def _is_no(ans):
|
||||
"""Réponse négative explicite, FR et EN (n/no/non). Utile pour les
|
||||
|
|
@ -3248,7 +3254,7 @@ class TODO:
|
|||
if self._is_yes(ans):
|
||||
install_branch = self._qemu_pick_branch()
|
||||
_label, install_cmd = self._qemu_pick_install_profile()
|
||||
install_monitor = self._is_yes(
|
||||
install_monitor = self._is_yes_default_yes(
|
||||
input(t("Interactive monitoring dashboard? (y/N): "))
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -2102,8 +2102,8 @@ TRANSLATIONS = {
|
|||
"en": "ERPLibre Deployment (+ QEMU + dev)",
|
||||
},
|
||||
"Interactive monitoring dashboard? (y/N): ": {
|
||||
"fr": "Suivi interactif (dashboard) ? (o/N, défaut : non) : ",
|
||||
"en": "Interactive monitoring dashboard? (y/N, default: no): ",
|
||||
"fr": "Suivi interactif (dashboard) ? (O/n, défaut : oui) : ",
|
||||
"en": "Interactive monitoring dashboard? (Y/n, default: yes): ",
|
||||
},
|
||||
"resolving IP...": {
|
||||
"fr": "résolution de l'IP...",
|
||||
|
|
|
|||
Loading…
Reference in a new issue