Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Portage / emerge: Marking new flags with % / yellow toggle?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
AllenJB
Veteran
Veteran


Joined: 02 Sep 2005
Posts: 1283
Location: Ashford, Kent

PostPosted: Sun Jan 29, 2006 12:14 am    Post subject: Portage / emerge: Marking new flags with % / yellow toggle? Reply with quote

Hi all,

I've just run through the modular X howto on my laptop, and it wanted me to upgrade portage to 2.1_pre4 (~amd64). Is there any way to toggle the new feature of marking new flags in yellow / with %. I very much liked being able to easily see whether flags were on or off by just looking at what colour they were, and for packages where there's lots of use flags (in this particular case it was modular X). With this new feature I have to squint at every use flag (I could increase my default font size, but this would be annoying everywhere else - I like my font size as it is right now (take note nvidia *cough*)).

So basically: Is there a toggle for this feature? If not, can we have one please?

Allen
_________________
http://gentoo-wiki.com :: http://lug.org.uk :: http://www.linux.org/groups/ :: User Blogs
Back to top
View user's profile Send private message
ednos
n00b
n00b


Joined: 27 Nov 2004
Posts: 22

PostPosted: Sun Jan 29, 2006 4:56 am    Post subject: Reply with quote

When your USE flags change from build to build (of the same package), changed ones will have an asterisk in front of them, and ones that have been added will be green.
Back to top
View user's profile Send private message
ecatmur
Advocate
Advocate


Joined: 20 Oct 2003
Posts: 3595
Location: Edinburgh

PostPosted: Sun Jan 29, 2006 8:24 am    Post subject: Reply with quote

Unlikely. More flags, more toggles, mean more work for maintainers; marking new USE flags makes a lot of sense. Is it really that difficult to see a minus sign?
_________________
No more cruft
dep: Revdeps that work
Using command-line ACCEPT_KEYWORDS?
Back to top
View user's profile Send private message
AllenJB
Veteran
Veteran


Joined: 02 Sep 2005
Posts: 1283
Location: Ashford, Kent

PostPosted: Sun Jan 29, 2006 10:16 am    Post subject: Reply with quote

ednos wrote:
When your USE flags change from build to build (of the same package), changed ones will have an asterisk in front of them, and ones that have been added will be green.


Whatever the new system, I still don't like it.

ecatmur wrote:
Unlikely. More flags, more toggles, mean more work for maintainers; marking new USE flags makes a lot of sense. Is it really that difficult to see a minus sign?


I'm not asking for it to be changed back - I recognise the change was probably made because a group of people wanted it. I'm asking for a toggle. Something like this:
Code:
if (flagIsNew) {
  # color it yellow
} else if (flagIsOn) {
  # color ir green
} else {
  # color it blue
}


In this case, a parameter is added, something like --dontcolournewflags (probably really bad name, but it's just an example) and the code becomes:
Code:
if ((flagIsNew) AND (!paramDontColourNewFlags)) {
  # color it yellow
} else if (flagIsOn) {
  # color ir green
} else {
  # color it blue
}


And for those who want it, they add the parameter to their emerge and we're right back to the old system. Those who like the new system get to keep it.

While it's not impossible to see whether new flags are on or off, it now takes me longer because I actually have to look - on the old system I just recognised it by the color of the flag.

Allen
_________________
http://gentoo-wiki.com :: http://lug.org.uk :: http://www.linux.org/groups/ :: User Blogs
Back to top
View user's profile Send private message
Phlogiston
Veteran
Veteran


Joined: 27 Jan 2004
Posts: 1925
Location: Europe, Swizerland

PostPosted: Sun Jan 29, 2006 1:05 pm    Post subject: Reply with quote

My opinion is to get rid of that very unreadable yellow output.

I'll probably file a bug for it.

Who also thinks that yellow is just bad?
_________________
Workstation: 5.1 SurroundSound, LIRC remote control; Laptop [IBM-T43]: patched sources, s2disk/ram, fingerprint sensor
Back to top
View user's profile Send private message
kmare
l33t
l33t


Joined: 20 Nov 2004
Posts: 619
Location: Thessaloniki, Greece

PostPosted: Sun Jan 29, 2006 1:26 pm    Post subject: Reply with quote

well.. yellow is unreadable for me too... that's cause i use a white background for my terminal (of course on the ttys it's fine..)
_________________
Never argue with an idiot. They will only pull you down to their level, then beat you with experience.
Back to top
View user's profile Send private message
StifflerStealth
l33t
l33t


Joined: 03 Jul 2002
Posts: 955

PostPosted: Sun Jan 29, 2006 3:41 pm    Post subject: Reply with quote

I have a white background too, and yellow is hard to read. My suggestion is to change yellow to purple, which is very readable on white and black. ;)
http://forums.gentoo.org/viewtopic-t-418373-highlight-.html
Check there. If enough people like this idea, maybe a bug report can be written and the color values moved outside this file and into a conf file. :) You do need to change the code each time you reinstall portage. Just find the code for purple and replace the code for yellow with it. Then all things that are yellow are changed, including the 'R' if a package is being rebuilt. ;)

Well, I like the highlighting of new use flags. It's easy for me to see which ones need to be looked at and to see if I need to set them or unset them or leave them alone. It's only temporary that they are like that. Also, the set flags are listed first and the unset ones are last, so it's not that hard to tell which ones are set and not set. They are even in alphabetical order too.

My two cents.
_________________
Nothing to read in this sig. Move along.
Back to top
View user's profile Send private message
AllenJB
Veteran
Veteran


Joined: 02 Sep 2005
Posts: 1283
Location: Ashford, Kent

PostPosted: Sun Jan 29, 2006 4:10 pm    Post subject: Reply with quote

StifflerStealth wrote:
I have a white background too, and yellow is hard to read. My suggestion is to change yellow to purple, which is very readable on white and black. ;)
http://forums.gentoo.org/viewtopic-t-418373-highlight-.html


If you're using something like Konsole, you can usually change the color scheme - for exmaple, I have a light grey background, and I've changed yellow to orange. It's still fugly, but atleast I'm not being blinded anymore.

Allen
_________________
http://gentoo-wiki.com :: http://lug.org.uk :: http://www.linux.org/groups/ :: User Blogs
Back to top
View user's profile Send private message
StifflerStealth
l33t
l33t


Joined: 03 Jul 2002
Posts: 955

PostPosted: Sun Jan 29, 2006 4:49 pm    Post subject: Reply with quote

Yeah, but that only works in Konsole. If you want it changed for the entire system, you need to change the color codes. I like things the same across the system so I can see the color and know what it means without having to think about the environment that I am in. I am peculiar like that. :P
_________________
Nothing to read in this sig. Move along.
Back to top
View user's profile Send private message
Schnacki
Tux's lil' helper
Tux's lil' helper


Joined: 19 Feb 2003
Posts: 105

PostPosted: Mon Jun 12, 2006 10:44 am    Post subject: Reply with quote

Since portage 2.1 is now stable...

There is a portage-wide way to change the colors of the output.

To remove this annoying yellow and turn it into darkyellow you can just create a file "/etc/portage/color.map" and put this into it:

Code:

yellow=darkyellow


The color on the left is the one used normally by portage and will be replaced by the color on the right.

I have not found any documentation of this.
Back to top
View user's profile Send private message
StifflerStealth
l33t
l33t


Joined: 03 Jul 2002
Posts: 955

PostPosted: Tue Jun 20, 2006 9:43 pm    Post subject: Reply with quote

I have:

yellow = 0xAA00AA

Which is purple. That shows up on white and black backgrounds. :) Plus it's the official color of Gentoo and it goes great with my theme. Looks great too. I think all yellow references should be changed to purple. :P

Cheers.
_________________
Nothing to read in this sig. Move along.
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Wed Sep 13, 2006 1:37 pm    Post subject: Reply with quote

yellow=darkyellow is no longer sufficient to change all instances of yellow. Change /etc/portage/color.map to:
Code:
yellow=0xAA5500
WARN=0xAA5500
MERGE_LIST_PROGRESS=0xAA5500
Back to top
View user's profile Send private message
lefsha
Veteran
Veteran


Joined: 30 Aug 2004
Posts: 1012
Location: Sankt-Petersburg, Russia

PostPosted: Wed Sep 13, 2006 5:18 pm    Post subject: Reply with quote

I agree!!!

Yellow is very hard to read for me too.

Please, change the default color to any other color which is well readable
on white and black terminals.
_________________
Lefsha
Back to top
View user's profile Send private message
syouth
Apprentice
Apprentice


Joined: 18 Sep 2004
Posts: 275

PostPosted: Tue Sep 19, 2006 7:40 am    Post subject: Reply with quote

How can I add more colours? I wanted to use this colour code something like HTML code, but it didn't work like that. Any suggestions?

PS: This option is real candy, because I had trouble with white terminal for a long time now.
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Tue Sep 19, 2006 7:53 am    Post subject: Reply with quote

These are BASH colours, not HTML colours.

If you want to change other colours, then look in /usr/lib/portage/pym/output.py for hints to add to /etc/portage/color.map, especially:
Code:
# Colors from /sbin/functions.sh
codes["GOOD"]       = codes["green"]
codes["WARN"]       = codes["yellow"]
codes["BAD"]        = codes["red"]
codes["HILITE"]     = codes["teal"]
codes["BRACKET"]    = codes["blue"]

# Portage functions
codes["INFORM"] = codes["darkgreen"]
codes["UNMERGE_WARN"] = codes["red"]
codes["MERGE_LIST_PROGRESS"] = codes["yellow"]
Back to top
View user's profile Send private message
syouth
Apprentice
Apprentice


Joined: 18 Sep 2004
Posts: 275

PostPosted: Tue Sep 19, 2006 8:00 am    Post subject: Reply with quote

Thanks for hint. I'm not really familiar with bash colours and I will certainly dig that.
Back to top
View user's profile Send private message
lateralus__
Tux's lil' helper
Tux's lil' helper


Joined: 19 May 2006
Posts: 100
Location: Belgium

PostPosted: Tue Sep 19, 2006 7:26 pm    Post subject: Reply with quote

PaulBredbury wrote:

Change /etc/portage/color.map to:
Code:
yellow=0xAA5500
WARN=0xAA5500
MERGE_LIST_PROGRESS=0xAA5500


Thanks for the tip :wink:
_________________
There are a lot of lies going around.... and half of them are true.
-- Winston Churchill
Back to top
View user's profile Send private message
STEDevil
Apprentice
Apprentice


Joined: 24 Apr 2003
Posts: 156

PostPosted: Tue Sep 19, 2006 9:32 pm    Post subject: Reply with quote

StifflerStealth wrote:
If enough people like this idea, maybe a bug report can be written and the color values moved outside this file and into a conf file.


I would actually take it one more step further. Why not simply change the default yellow color to eg default purple. No reason to have a stupid unreadable default when its so simple to fix it once and for all for everybody no matter if u have white or black console background.
Back to top
View user's profile Send private message
wah
Guru
Guru


Joined: 25 Feb 2005
Posts: 453
Location: Raleigh, NC, USA

PostPosted: Wed Sep 20, 2006 12:46 am    Post subject: Reply with quote

lateralus__ wrote:
PaulBredbury wrote:

Change /etc/portage/color.map to:
Code:
yellow=0xAA5500
WARN=0xAA5500
MERGE_LIST_PROGRESS=0xAA5500


Thanks for the tip :wink:

I will super-dooper-double this :)

I like a white Konsole, and that yellow was straight hidious!

Thanks to all for the tips!

Cheers,
W.
_________________
- AMD64 3000+, MSI K8N-SLI, Nvidia Geforce 6600 PCIE, 2GB OCZ Dual-Channel PC3200,2x160GB SATA
- Registered Linux User #418541
Back to top
View user's profile Send private message
Dominique_71
Veteran
Veteran


Joined: 17 Aug 2005
Posts: 1483
Location: Switzerland (Romandie)

PostPosted: Wed Oct 18, 2006 8:04 am    Post subject: Reply with quote

Nice thread,

It was the same problem here, but with a dark term. The blue was almost impossible to read on it. Changed it to purple and it is much better now. :D

EDIT: I try with other color as FF00FF, and get an error from portage:
Code:
'"/etc/portage/color.map", line 44: Undefined: \'FF00FF\''
and it use the default blue color that I cannot read. I see at it is a test about ANSI color in /usr/lib/portage/pym/output.py. Is it possible to make such non ANSI colors to work?
_________________
[[[ To any NSA and FBI agents reading that text: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum