Skip to content

Commit

Permalink
fix(translation): Add missing translations for WARNING and ERROR
Browse files Browse the repository at this point in the history
The "WARNING" and "ERROR" words (used when printing a warning or an error messages to users) were missing from the translations files and were thus printed as such whatever language is used.

Fixes #182
  • Loading branch information
Antiz96 committed Jul 4, 2024
1 parent a1d264e commit 09c521b
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 2 deletions.
10 changes: 10 additions & 0 deletions po/arch-update.pot
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,16 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"

#: src/script/arch-update.sh:120
#, sh-format
msgid "WARNING"
msgstr ""

#: src/script/arch-update.sh:126
#, sh-format
msgid "ERROR"
msgstr ""

#: src/script/arch-update.sh:131
#, sh-format
msgid "Press \"enter\" to continue "
Expand Down
10 changes: 10 additions & 0 deletions po/fr.po
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,16 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"

#: src/script/arch-update.sh:120
#, sh-format
msgid "WARNING"
msgstr "AVERTISSEMENT"

#: src/script/arch-update.sh:126
#, sh-format
msgid "ERROR"
msgstr "ERREUR"

#: src/script/arch-update.sh:131
#, sh-format
msgid "Press \"enter\" to continue "
Expand Down
4 changes: 2 additions & 2 deletions src/script/arch-update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -117,13 +117,13 @@ ask_msg() {
# Definition of the warning_msg function: Display a message as a warning message
warning_msg() {
msg="${1}"
echo -e "${yellow}==> WARNING:${color_off}${bold} ${msg}${color_off}"
echo -e "${yellow}==> "$(eval_gettext "WARNING")":${color_off}${bold} ${msg}${color_off}"
}

# Definition of the error_msg function: Display a message as an error message
error_msg() {
msg="${1}"
echo -e >&2 "${red}==> ERROR:${color_off}${bold} ${msg}${color_off}"
echo -e >&2 "${red}==> "$(eval_gettext "ERROR")":${color_off}${bold} ${msg}${color_off}"
}

# Definition of the continue_msg function: Display the continue message
Expand Down

0 comments on commit 09c521b

Please sign in to comment.