Sponsored Content
Full Discussion: Using color in scripts
Operating Systems Linux Ubuntu Using color in scripts Post 303033723 by wisecracker on Wednesday 10th of April 2019 04:02:14 PM
Old 04-10-2019
Hi drew77...
Code:
GREEN='\033[0;32m'
RED='\033[0;31m'
WHITE='\033[0;37m'
RESET='\033[0m'

These 2 Users Gave Thanks to wisecracker For This Post:
 

2 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to change the background color in the init 3 mode(not line color)

Hello, I am using RHEL 6.1 on VMware I am searching for a way to change background color (not line by line color wich one can using tput command) basically changing the color of the whole screen to white instead of the default black and changing font color to black and alos would like to... (2 Replies)
Discussion started by: Dexobox
2 Replies

2. UNIX for Beginners Questions & Answers

Text color in Linux scripts via putty

hi Folks, Can anyone help with changing the color of the words in a linux shell script? I get how to change default background etc in putty, but for some reason the text in the script has different colors for different parts of the cript. Is there a way to have one color in a linux shell... (5 Replies)
Discussion started by: jonnyd
5 Replies
colormake(1)						      General Commands Manual						      colormake(1)

NAME
colormake - color wrapper for make(1) SYNOPSIS
colormake [ --short ] ... DESCRIPTION
colormake acts as a wrapper around make(1) to ease reading the output by colorizing it. OPTIONS
The --short option instructs colormake to truncate lines so they do not wrap. All other options will be passed unmodified to make(1). USAGE
To change a makefile to use colormake, you may change the path at the top which normally reads #!/usr/bin/make to #!/usr/bin/colormake. Alternately, you may type colormake whenever you would normally type make when compiling programs. Colormake is also available using the alternate names which enable piping through less (clmake), truncated output so lines do not wrap (colormake-short), or both (clmake-short). FILES
The configuration files are Perl scripts included by colormake.pl. The defaults values are (from colormake.pl itself): # Some useful color codes, see end of file for more. # $col_black = "33[30m"; $col_red = "33[31m"; $col_green = "33[32m"; $col_yellow = "33[33m"; $col_blue = "33[34m"; $col_magenta = "33[35m"; $col_cyan = "33[36m"; $col_ltgray = "33[37m"; $col_norm = "33[00m"; $col_background = "33[07m"; $col_brighten = "33[01m"; $col_underline = "33[04m"; $col_blink = "33[05m"; # Customize colors here... # $col_default = $col_ltgray; $col_gcc = $col_magenta . $col_brighten; $col_make = $col_cyan; $col_filename = $col_yellow; $col_linenum = $col_cyan; $col_trace = $col_yellow; $col_warning = $col_green; $tag_error = ""; $col_error = $tag_error . $col_yellow . $col_brighten; $error_highlight = $col_brighten; For use with gnome-terminal I have the following configuration in my $HOME/.colormakerc file: $col_default = $col_black; $col_gcc = $col_magenta; $col_filename = $col_blue; $col_linenum = $col_cyan; $col_error = $tag_error . $col_red . $col_brighten; /usr/share/colormake/colormake.rc System-wide configuration file for colormake. $HOME/.colormakerc Personal configuration file for colormake. HISTORY
/usr/bin/colormake was formerly named /usr/bin/cmake but had to be renamed because of a name clash. AUTHORS
Bjarni R. Einarsson is the author of colormake. This manual page was written for the Debian GNU/Linux distribution because the original program does not have a manual page. This manual page was written by Joe Wreschnig <piman@sacredchao.net> and updated by Ludovic Rousseau <rousseau@debian.org>, for the Debian GNU/Linux system (but may be used by others). SEE ALSO
make(1), clmake(1) July 2nd, 2001 colormake(1)
All times are GMT -4. The time now is 01:00 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy