Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow colored logging output via CPP_LINTER_COLOR env var #275

Open
2bndy5 opened this issue Oct 18, 2024 · 1 comment · May be fixed by #276
Open

Allow colored logging output via CPP_LINTER_COLOR env var #275

2bndy5 opened this issue Oct 18, 2024 · 1 comment · May be fixed by #276
Labels
enhancement New feature or request

Comments

@2bndy5
Copy link
Collaborator

2bndy5 commented Oct 18, 2024

Is your idea related to an existing feature?

verbosity

Describe the behavior you would like

The logs can be rather monotonous when looking for errors.

The cpp-linter python package already has support for using the rich package to add color and style to log outputs. This action only needs to ensure rich is installed if users want colored (and stylized) output in the CI logs.

Proposal

- uses: cpp-linter/cpp-linter-action@v2
  env:
    # enabled colored output in logs (uses `rich` package)
    CPP_LINTER_COLOR: true

Acceptable values that mean "color enabled" include true, on, and 1. By default, color output should be disabled because the ASCII color codes are included in the raw logs that can be downloaded to a text file.

Describe alternatives you have considered

No response

Additional context

The cpp-linter-rs project already includes support for this env variable (see cpp-linter/cpp-linter-rs#52), and it does not require additional dependencies installed. Migrating this new feature to use the rust project should be seamless.

@2bndy5 2bndy5 added the enhancement New feature or request label Oct 18, 2024
2bndy5 added a commit that referenced this issue Oct 18, 2024
@2bndy5 2bndy5 linked a pull request Oct 18, 2024 that will close this issue
2bndy5 added a commit that referenced this issue Oct 18, 2024
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@github-actions github-actions bot added the Stale label Dec 17, 2024
@2bndy5 2bndy5 removed the Stale label Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant