Skip to content

Conversation

@ChrisDryden
Copy link
Contributor

@ChrisDryden ChrisDryden commented Nov 26, 2025

This PR takes the commit from @3v1n0 to split it from the rest of his PR to add the feature of reading from the COLUMNS variable to determine how long the lines are in the output. This is because the changes in that PR related to the flags are separate and it might be a while until some upstream changes related to that change are merged.

I added tests that cover that when printing, ideally once we expect the output of the --all command to be matching we should be able to add GNU matching testing to the COLUMNS tests. These integ tests match how the GNU integ tests validate that this env variable is working properly

#9432 this is the PR where the COLUMNS support is added from

When reviewing this, an important thing to note is that the COLUMNS environment variable is only used when piping output.

Do the same as GNU stty when it has to prints the parameter, doing
proper text wrapping
@ChrisDryden ChrisDryden force-pushed the columns_env_support branch 2 times, most recently from 3e6051f to 96937d3 Compare November 26, 2025 02:31
@codspeed-hq
Copy link

codspeed-hq bot commented Nov 26, 2025

CodSpeed Performance Report

Merging #9490 will not alter performance

Comparing ChrisDryden:columns_env_support (c82800d) with main (b8edd13)

Summary

✅ 126 untouched
⏩ 6 skipped1

Footnotes

  1. 6 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@github-actions
Copy link

GNU testsuite comparison:

Skipping an intermittent issue tests/tail/overlay-headers (passes in this run but fails in the 'main' branch)

@ChrisDryden ChrisDryden force-pushed the columns_env_support branch 2 times, most recently from 53628a6 to bf1f813 Compare November 26, 2025 03:08
@github-actions
Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/tail/overlay-headers (fails in this run but passes in the 'main' branch)

@github-actions
Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/tail/overlay-headers (fails in this run but passes in the 'main' branch)

@ChrisDryden ChrisDryden marked this pull request as ready for review November 26, 2025 04:14
@ChrisDryden
Copy link
Contributor Author

Am so glad that we now have the integ tests running on the CI for this binary, it spotted a bunch of stuff.

@github-actions
Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/misc/tee (fails in this run but passes in the 'main' branch)

@ChrisDryden
Copy link
Contributor Author

Moved the libc to a helper function with comments and added some comments to the main wrapped printer class

@ChrisDryden
Copy link
Contributor Author

The only errors are coming from this PR: #9471

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