Arduino CLI locale not configured by default #1636
Labels
topic: CLI
Related to Arduino CLI
topic: code
Related to content of the project itself
type: imperfection
Perceived defect in any part of project
Describe the problem
Arduino IDE 2.x has been localized to 17 languages thanks to the amazing work of the community translators.
Output exposed to Arduino IDE users when performing various operations often originates from the strings defined in the Arduino CLI codebase. These strings have also been localized. Arduino CLI must be configured by Arduino IDE to use the locale set in the "Language" field of the Arduino IDE preferences dialog.
By default, the Arduino IDE 2.x user interface is localized to English.
🐛 Arduino IDE 2.x does not configure the Arduino CLI locale by default, so Arduino CLI uses the system locale, resulting in inconsistent localization of the strings shown the Arduino IDE 2.x user interface.
To reproduce
Set your system locale to a non-English language that Arduino CLI has significant translation coverage for:
https://explore.transifex.com/arduino-1/arduino-cli/
Select File > Quit from the Arduino IDE menus if it is running.
Delete the following folders to adequately simulate a fresh installation of Arduino IDE 2.x:
Windows:
(e.g.,
C:\Users\<username>\.arduinoIDE\
)(e.g.,
C:\Users\<user name>\AppData\Roaming\arduino-ide\
)Linux:
macOS:
Start Arduino IDE.
🙂 The UI is localized according to the locale set in the "Language" field of the Arduino IDE "Preferences" dialog (which defaults to "English").
Compile any sketch for any board.
Wait for the compilation to finish.
🐛 The output originating from Arduino CLI in the "Output" view is localized according to the system locale setting.
Select File > Preferences... from the Arduino IDE menus.
Select any language other than "English" from the "Language" menu.
Click the OK button.
Select File > Preferences... from the Arduino IDE menus.
Select "English" from the "Language" menu.
Click the OK button.
Compile any sketch for any board.
Wait for the compilation to finish.
🙂 The output originating from Arduino CLI in the "Output" view is localized according to the locale set in the "Language" field of the Arduino IDE "Preferences" dialog.
Expected behavior
Arduino CLI locale configuration always matches the Arduino IDE locale configuration.
Arduino IDE version
Original report
b998d35
Last verified with
2.2.1
Operating system
Operating system version
Additional context
Arduino CLI locale is configured via the
locale
key in thearduino-cli.yaml
configuration file:https://arduino.github.io/arduino-cli/dev/configuration/
A source of potential confusion is that one of the log entries does show a
locale
setting even though none is set in thearduino-cli.yaml
file:Originally reported by @CptHolzschnauz at #1614 (comment)
Related
Keywords
localization
localized
l10n
internationalization
internationalized
i18n
translate
translation
Issue checklist
The text was updated successfully, but these errors were encountered: