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

Stop implicitly manipulating NO_COLOR/NOCOLOR #1188

Closed
wants to merge 1 commit into from

Commits on Nov 29, 2023

  1. Stop implicitly manipulating NO_COLOR/NOCOLOR

    Stop implicitly forcing `NO_COLOR` and `NOCOLOR` in ebuild environment.
    This is undesired for several reasons:
    
    1. It makes it impossible to control color for emerge output
       independently of command output, e.g. when one goes to a pty while
       the other goes to logs.
    
    2. It makes it impossible to get color output in logs when running
       `emerge --jobs ...`.
    
    3. Forcing `NO_COLOR=1` turns out to cause random test failures,
       and while fixing them is commendable, it is a pain for arch testing
       and it is currently blocking stabilization requests.
    
    With the new approach, the color output in programs is consistent
    between using ``--jobs`` or ``--quiet-build``, and not.  Therefore,
    both cases generate uniform logs.  In order to obtain logs free of color
    codes, one can either filter them via `ansifilter(1)` (as the manpages
    already recommend) or explicitly set `NO_COLOR`.
    
    Furthermore, one can combine color-free build output (for clean logs)
    with colorful emerge output by using:
    
        NO_COLOR=true emerge --color y ...
    
    Bug: https://bugs.gentoo.org/918515
    Signed-off-by: Michał Górny <mgorny@gentoo.org>
    mgorny committed Nov 29, 2023
    Configuration menu
    Copy the full SHA
    9c02566 View commit details
    Browse the repository at this point in the history