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

wgsl: Do not make error output colorful when the terminal is dumb #1707

Merged
merged 1 commit into from
Jan 29, 2022

Conversation

rhysd
Copy link
Contributor

@rhysd rhysd commented Jan 29, 2022

Recently I'm trying to integrate naga command to my text editor to check WGSL sources on the fly.

However, a WGSL parse error output is hard to parse because it contains many color escape sequences. By this PR, error outputs are colorful only when stderr is connected to terminal. By this patch, tools like text editors can get error outputs without color escape sequences and easily parse the outputs.

@kvark kvark merged commit d6f8958 into gfx-rs:master Jan 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants