clan_cli: fix missing quotes around nix-command flakes

Before:

    [$] nix \
        --extra-experimental-features nix-command flakes \
        show-config \
        --json

After:

    [$] nix \
        --extra-experimental-features 'nix-command flakes' \
        show-config \
        --json
This commit is contained in:
Michael Hoang
2024-12-04 19:35:11 +11:00
parent 4b22869dec
commit ca26431d12

View File

@@ -74,7 +74,7 @@ def indent_command(command_list: list[str]) -> str:
# Indent after the next argument
formatted_command.append(" ")
i += 1
formatted_command.append(command_list[i])
formatted_command.append(shlex.quote(command_list[i]))
if i < len(command_list) - 1:
# Add line continuation only if it's not the last argument