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

Disable colored output for non-interactive terminals #3310

Merged
merged 1 commit into from
Sep 10, 2019

Conversation

rhuitl
Copy link
Contributor

@rhuitl rhuitl commented Aug 28, 2019

Disables colored output for non-interactive terminals. PCL_CLICOLOR_FORCE or pcl::console::enableColoredOutput() can be used to override this behavior.

Fixes #3308.

…ry#3308).

PCL_CLICOLOR_FORCE or pcl::console::enableColoredOutput() can be used to override this behavior.
@taketwo
Copy link
Member

taketwo commented Aug 28, 2019

I think it'll compile on Linux and Windows but not sure how to check - do you have a build server to test that?

We do have CI, however there are no unit tests for console printing functions. Nevertheless, we can see that it works on Ubuntu. If you open the "Run Unit Tests" step in the last master branch build, you will see colored output here and there. In this PR build, however, there are no colors. Unfortunately, we can not perform the same check for Windows since unit tests are not currently running for that platform. But the build succeeded at least.

@taketwo taketwo added changelog: behavior change Meta-information for changelog generation module: common labels Aug 28, 2019
@taketwo taketwo changed the title Disable colored output for non-interactive terminals (#3308). Disable colored output for non-interactive terminals Aug 28, 2019
@rhuitl
Copy link
Contributor Author

rhuitl commented Sep 6, 2019

Thanks @taketwo! Can we merge this or do we need more reviewers? I don't have write access so I cannot merge.

@taketwo
Copy link
Member

taketwo commented Sep 6, 2019

We usually try to follow the rule of two reviews per PR. @SergioRAgostinho do you have time to have a look?

If we don't hear back in a couple of days, I'll merge.

@taketwo taketwo merged commit 261f07e into PointCloudLibrary:master Sep 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog: behavior change Meta-information for changelog generation module: common
Projects
None yet
Development

Successfully merging this pull request may close these issues.

pcl::console::print_highlight should not emit color codes on non-interactive terminals
2 participants