Skip to content

Add support for globally registering color schemes #516

@bobtiernay-okta

Description

@bobtiernay-okta

Right now it doesn't appear to be possible to globally set anCommandLine.Help.ColorScheme and have this be consistently applied to an application. A common example is when using subcommands and an HelpCommand. If the parent command modifies the color scheme, this doesn't propagate to the help command.

As a workaround, one can do something similar to:

    static {
        // Color scheme
        System.setProperty("picocli.color.options", "fg(249)");
        System.setProperty("picocli.color.parameters", "fg(249)");
    }

But this is less than ideal from a localization and overriding perspective.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions