subiquity/subiquitycore
Olivier Gayot f284d25757 utils: add parameter to avoid clearing the LC_* variables
We used to set LC_ALL=C unconditionally when executing a command. This
is a problem if we want the output of a specific command to be
translated (provided a locale definition and an actual translation exist
for the requested language).

This patch adds the clean_locale parameter, which can be used to specify
if we want the locale variable to be cleaned, to most of the helpers
that execute commands.

The value defaults to True so the default behavior is preserved.
If one wants a command to be translated, they have to  explicitly pass
clean_locale=False.

Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2023-02-07 18:18:16 +01:00
..
controllers loop: replace use of asyncio.get_event_loop 2022-10-07 18:45:11 +02:00
models network: use routes instead of gateway directives 2022-09-06 16:44:12 -06:00
testing support for editing existing partitions 2019-05-30 15:10:54 +12:00
tests ui: avoid crashing when removing overlay that does not exist 2022-12-07 10:31:05 +01:00
ui ui: add a helper to open a confirmation dialog and get the response 2023-01-05 09:54:51 +01:00
__init__.py pyflakes3 fixes for subiquitycore/__init__.py 2018-05-24 16:59:31 -05:00
async_helpers.py async: add helper to run fire-and-forget tasks 2023-01-24 12:50:23 +01:00
context.py add a mode argument to shutdown to allow reboot or power off 2021-08-22 09:36:41 +12:00
controller.py Add type hinting for controller base class attributes 2022-01-14 13:02:44 +01:00
controllerset.py fixes for how install failures are presented 2020-09-21 14:01:23 +12:00
core.py Remove Application.aio_loop attribute 2022-12-08 12:52:14 +13:00
file_util.py file_util: generate_timestamped_header function to any subiquity written files 2022-07-14 21:48:51 -06:00
i18n.py remove stdlib backports from Python 3.8 2021-10-12 18:55:09 -06:00
log.py logging: 0770 log dir in install env, 0750 later 2022-03-11 12:44:22 -07:00
lsb_release.py Add type hints where necessary to make mypy happy 2022-04-06 11:23:34 +02:00
netplan.py do not log wifi passwords from existing configs 2020-05-19 07:47:33 +12:00
palette.py Merge pull request #1393 from CarlosNihelton/fix-gray-contrast 2022-08-24 08:44:45 -06:00
prober.py probert: implement os prober arg 2022-03-29 15:09:21 -06:00
pubsub.py loop: invoke asyncio.create_task() directly 2022-10-28 17:05:54 +02:00
screen.py Move the code for setting up the screen to its own file 2020-07-27 23:40:17 +12:00
snapd.py call into snapd to set up encryption when required 2022-11-11 14:46:44 +13:00
ssh.py fix getting ssh info when sshd is not installed 2022-11-30 11:12:51 +13:00
tui.py Remove Application.aio_loop attribute 2022-12-08 12:52:14 +13:00
tuicontroller.py simple replacement for urwid signals wrapper as used in server 2021-04-13 09:41:43 +12:00
utils.py utils: add parameter to avoid clearing the LC_* variables 2023-02-07 18:18:16 +01:00
view.py ui: add a helper to open a confirmation dialog and get the response 2023-01-05 09:54:51 +01:00