Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have been doing a lot of compiling and kinda sick of looking at the white on black when compiling source. I was just wondering if there is a way to change all the code that is running across the screen when doing ./configure && make?
I have been doing a lot of compiling and kinda sick of looking at the white on black when compiling source. I was just wondering if there is a way to change all the code that is running across the screen when doing ./configure && make?
I don't know if this will work, but you can colourize your konsole with this command: export CLICOLOR="yes". To make it permenant just add it to your ~.bashrc file.
In KDE, when using the console, go to Settings - Schema and choose a different color scheme. I'd guess that gnome has something similar. I don't know about other desktop environments.
I wrote a little perl script that wrap around standard make for creating colorful make. I do not know if there any other available tools that do this, but if you find mine is what you are looking for, you can use it:
Code:
#!/usr/bin/perl -w
use strict;
use Term::ANSIColor qw(:constants);
use IO::File;
my $cmd = "/usr/bin/make";
BEGIN:
{
my $cmdargs = "";
foreach my $opt (@ARGV){
$cmdargs .= " " . $opt;
}
my $fh = new IO::File "$cmd $cmdargs |";
while( <$fh> ){
my $line = $_;
chomp($line);
ColorPrint($line);
}
$fh->close();
}
sub ColorPrint
{
my $line = shift;
my @data = split(/\s/, $line);
foreach my $elem (@data){
if( length($elem) == 0 ){
next;
}
if ( $elem =~ /\.[c|h]/i ){
print BOLD GREEN $elem, RESET;
} elsif ( $elem =~ /\.[o|a]/i ){
print BOLD RED $elem, RESET;
} elsif ( $elem =~ /^\-/ ){
print BOLD BLUE $elem, RESET;
} elsif( ($elem) =~ /g?cc/i || $elem =~ /cp/i ||
$elem =~ /rm/i || $elem =~ /install/i ||
$elem =~ /make/ || $elem =~ /ld/i ||
$elem =~ /ar/ ){
print BOLD CYAN $elem, RESET;
} else {
print $elem;
}
print " ";
}
print "\n";
return;
}
You need to install Term::ANSIColor if your perl does not have this module.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.