Files
update/software-client/software_client/common
Sabyasachi Nayak ba92ca3c62 User confirmation support in the Software CLI
Added a generic user confirmation prompt in the Software CLI Framework
for all service-impacting commands.
This ensures critical operations require explicit user approval unless
overridden with --yes.
The "cli_confirmations" system service parameter is used to enabling or
disabling the confirmation prompt.

Confirmation Prompt:
            WARNING: This is a high-risk operation that may cause a
            service interruption or remove critical resources.
            Do you want to continue? (yes/No):

Service-Impacting Commands:
           software deploy host 1
           software delete fake-release

Behavior:
      1. When cli_confirmations is disabled, commands execute without
         confirmation.

      2. When cli_confirmations is disabled & --yes is used, commands
         proceed normally to maintain consistency in internal calls.

      3. When cli_confirmations is enabled & --yes is used, commands
         execute without prompts.

      4. When cli_confirmations is enabled & --yes is not provided, a
         confirmation prompt appears, and if no response is given, it
         times out.

      5. Normal operations should not prompt cli confirmations prompt.

Test Plan:
PASS - AIO-SX:
      Verified CLI behavior aligns with the above conditions.

Story: 2011240
Task: 51197

Change-Id: If7ab960272bff6cc1f33fc3500435c225f2b5dc9
Signed-off-by: Sabyasachi Nayak <sabyasachi.nayak@windriver.com>
2025-04-17 12:47:56 +00:00
..
2024-04-26 15:54:21 +00:00
2024-03-20 22:41:48 +00:00