Page MenuHomeFreeBSD

bsdgrep(1): Fix coloring to respect --color=when properly
AbandonedPublic

Authored by kevans on Mar 23 2017, 1:05 PM.
Tags
None
Referenced Files
F86781352: D10120.id.diff
Tue, Jun 25, 12:16 PM
Unknown Object (File)
Feb 3 2024, 12:45 PM
Unknown Object (File)
Jan 1 2024, 12:26 AM
Unknown Object (File)
Dec 20 2023, 4:00 PM
Unknown Object (File)
Dec 14 2023, 11:53 AM
Unknown Object (File)
Oct 28 2023, 1:20 PM
Unknown Object (File)
Sep 24 2023, 3:36 PM
Unknown Object (File)
Sep 4 2023, 9:01 PM
Subscribers
None

Details

Reviewers
emaste
Summary

bsdgrep(1) does not currently respect --color=when, specifically for when=auto. It currently either always colors or it never colors. If --color=auto, don't color fulltext matches, just partial line matches, and if the -o flag is set we generally shouldn't color unless --color=always

Test Plan

Run kyua tests to make sure we've introduced no regressions.

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 8252
Build 8495: arc lint + arc unit

Event Timeline

kevans created this revision.

Remove bogus symlink that snuck in

Apologies for the noise -- too tired for this. =)