Summary: | Colors support improvements | ||
---|---|---|---|
Product: | Portage Development | Reporter: | Arfrever Frehtes Taifersar Arahesis (RETIRED) <arfrever> |
Component: | Core - Interface (emerge) | Assignee: | Portage team <dev-portage> |
Status: | RESOLVED FIXED | ||
Severity: | enhancement | Keywords: | InVCS |
Priority: | High | ||
Version: | 2.1 | ||
Hardware: | All | ||
OS: | All | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 181949 | ||
Attachments: |
Patch to pym/portage/output.py
Patch |
Description
Arfrever Frehtes Taifersar Arahesis (RETIRED)
2007-07-01 17:50:14 UTC
I've just discovered that PKG_MERGE_ARG and PKG_NOMERGE_ARG are used for system packages when emerge is invoked with world as an argument :) . I have some suggestions to make system of colors more consistent: 1. PKG_MERGE_SYSTEM / PKG_NOMERGE_SYSTEM should be always used for system packages not given as command line arguments. PKG_MERGE_WORLD / PKG_NOMERGE_WORLD should be always used for world packages not given as command line arguments. PKG_MERGE_ARG_SYSTEM / PKG_NOMERGE_ARG_SYSTEM should be created and always used for system packages given as command line arguments. PKG_MERGE_ARG_WORLD / PKG_NOMERGE_ARG_WORLD should be created and always used for world packages given as command line arguments. 2. Default values: PKG_MERGE_ARG="darkgreen red" PKG_MERGE_SYSTEM="bg_green" PKG_MERGE_ARG_SYSTEM="bg_green red" PKG_MERGE_ARG_WORLD="green red" PKG_NOMERGE_ARG="darkblue red" PKG_NOMERGE_SYSTEM="bg_blue" PKG_NOMERGE_ARG_SYSTEM="bg_blue red" PKG_NOMERGE_ARG_WORLD="blue red" So background color would mean system package and red foreground color would mean package given as command line argument. It would be easier to understand and remember. If you want to enable some background colors in your local config then that's fine. If we do it by default then I'm quite sure that it will upset lots of people. Lots of people are very sensitive to user interface changes like that. Personally, I don't want any background colors on my terminal. :) (In reply to comment #3) OK. They were also some stupid typos in that suggestion (because I originally thought about "underline" instead of "red"), so here is the new one: Default values: PKG_MERGE_ARG="darkgreen" // No change PKG_MERGE_SYSTEM="green" // No change PKG_MERGE_ARG_SYSTEM="green" PKG_MERGE_ARG_WORLD="green" PKG_NOMERGE_ARG="darkblue" // No change PKG_NOMERGE_SYSTEM="blue" // No change PKG_NOMERGE_ARG_SYSTEM="blue" PKG_NOMERGE_ARG_WORLD="blue" Created attachment 123826 [details, diff] Patch to pym/portage/output.py This patch only fixes issues described in comment #0 and adds default values for new variables. These new variables still aren't used. Changing of "raise" to "print" is intentional. Thanks again, this is all in svn now. I'm not sure if people are really going to use the *ARG* color classes. Maybe we should just remove them to simplify things. Created attachment 124064 [details, diff]
Patch
pym/portage/output.py:
-I think that background colors should have names similar to corresponding
foreground colors.
-codes["white"] is set earlier to real white color.
-pym/output.py@3029 says that "fuscia" is spelled wrong and now it isn't
used anywhere.
pym/emerge/__init__.py:
-I think that pkg_system should be checked before pkg_world. Otherwise
PKG_{,NO}MERGE_SYSTEM won't be used in many cases.
man/color.map.5:
-I think that hexadecimal values shouldn't be used in this manual, because
only limited set of such values is available. People can still check them
in pym/portage/output.py.
-New section: "LIST OF VALID ATTRIBUTES".
(In reply to comment #9) > Created an attachment (id=124064) [edit] > Patch Thanks again, that's in svn r7184. This has been released in 2.1.3_rc7. |