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

fix(rosetta): prints colors to log file #61

Merged
merged 1 commit into from
Apr 12, 2023

Conversation

rix0rrr
Copy link
Contributor

@rix0rrr rix0rrr commented Apr 12, 2023

Rosetta error messages contain colors codes in the errors, which makes the errors produced by Rosetta look like garbage and very hard to parse.

Strip the colors if we detect a non-TTY input.

(Copied the regex from an MIT-licensed package to avoid adding extra dependencies)

Port of aws/jsii#3953


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Rosetta error messages contain colors codes in the errors, which makes the errors produced by Rosetta look like garbage and very hard to parse.

Strip the colors if we detect a non-TTY input.

(Copied the regex from an MIT-licensed package to avoid adding extra dependencies)

Port of aws/jsii#3953
@rix0rrr rix0rrr requested a review from a team April 12, 2023 08:23
@rix0rrr rix0rrr self-assigned this Apr 12, 2023
@aws-cdk-automation aws-cdk-automation added this pull request to the merge queue Apr 12, 2023
Merged via the queue into main with commit 6ab1817 Apr 12, 2023
@aws-cdk-automation aws-cdk-automation deleted the huijbers/no-colors branch April 12, 2023 09:44
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.

3 participants