Skip to content

Add JSON Output Format #376

Open
Open
@roulpriya

Description

@roulpriya

Add support for JSON output for toolchain management commands:

  • List toolchains
  • Install toolchain
  • Use toolchain

Create structured result types for each command operation, define clear structs/classes for outputs like toolchain lists, version info, etc and include fields for all data currently output as text

Modify command implementations to return these structured types instead of directly printing text, and separate logic from presentation concerns

Implement a rendering layer with text and JSON formatters by creating interfaces with implementations for each output format.

Use a command-line argument like --format=json to control the output format

For backward compatibility:

  • Default to text output when no format is specified
  • Ensure text formatting matches the current output closely

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions