Hello, the man page of revdep-rebuild from app-portage/gentoolkit-0.3.2-r1 says: revdep-rebuild honors the NOCOLOR and PORTAGE_NICENESS variables from make.conf In my /etc/portage/make.conf there is line: NOCOLOR="true" But the revdep-rebuild still outputs colors. Is there some problem with my configuration or does revdep-rebuild just ignore this NOCOLOR from make.conf? Thank you. Regards, Robert Wolf.
hmm, quick look at the code... revdep itself has its own nocolor option, and will pass that to portage. But it otherwise does not check what the state of it is for portage with setting loaded from make.conf. Zac, whe portage is imported is the nocolor option setting from make.conf loaded and then can be used to pre-set revdep's cli option?
(In reply to Brian Dolbec from comment #1) > revdep itself has its own nocolor option, and will pass that to portage. *** Yes, I know. But I would like set it permanently. I have search man page for config file where I could set it and I have found the "revdep-rebuild honors the NOCOLOR and PORTAGE_NICENESS variables from make.conf" > Zac, whe portage is imported is the nocolor option setting from make.conf > loaded and then can be used to pre-set revdep's cli option? *** I have found some code in equery and some other command to play with some settings with NOCOLOR, but I am not sure if this is really NOCOLOR from make.conf or some other NOCOLOR. Thank you. Regards, Robert Wolf.
(In reply to Robert Wolf from comment #2) > (In reply to Brian Dolbec from comment #1) > > revdep itself has its own nocolor option, and will pass that to portage. > > *** Yes, I know. But I would like set it permanently. I have search man page > for config file where I could set it and I have found the "revdep-rebuild > honors the NOCOLOR and PORTAGE_NICENESS variables from make.conf" The man page was written for the old version of revdep-rebuild (i.e. revdep-rebuild.sh). With that said, the goal is for the new Python version to have the same behaviors and options as the old version, except where not technically feasible. Where it is not feasible, we need to update the man page. So yes, this a valid bug and Brian is investigating if it is technically feasible to implement in the Python version.
(In reply to Paul Varner from comment #3) > So yes, this a valid bug and Brian is investigating if it is technically > feasible to implement in the Python version. *** OK, thank you for confirmation. It would be great, if you could support NOCOLOR from make.conf. Otherwise own config file with NOCOLOR should be good too. Or at least some ENV variable. Thank you. Regards, Robert Wolf.
Current gentoolkit equery nocolor setting: # Guess color output if ( CONFIG["color"] == -1 and os.getenv("NOCOLOR") in ("yes", "true") or CONFIG["color"] == 0 ): pp.output.nocolor() if CONFIG["piping"]: CONFIG["verbose"] = False # set extra wide, should disable wrapping unless # there is some extra long text CONFIG["termWidth"] = 600 # turn off color pp.output.nocolor() It looks for a NOCOLOR setting from the environment. So, just add it to your .bashrc. Adding in code for importing the portage module to get the make.conf setting at this early stage would only slow the run time further. Likely not worth the effort. Certain parts of the various modules do load in portage and can get it easily, but not all modules require portage code imports.