Add new, better prompt.
This commit is contained in:
parent
bbf54dd05f
commit
2e218bdc0a
3 changed files with 55 additions and 18 deletions
26
bash/colorize.sh
Normal file
26
bash/colorize.sh
Normal file
|
@ -0,0 +1,26 @@
|
|||
function colorize() {
|
||||
local TEXT=$2
|
||||
local NO_COLOR="\033[0m"
|
||||
case "$1" in
|
||||
red)
|
||||
local COLOR="\033[31m"
|
||||
;;
|
||||
green)
|
||||
local COLOR="\033[32m"
|
||||
;;
|
||||
yellow)
|
||||
local COLOR="\033[33m"
|
||||
;;
|
||||
blue)
|
||||
local COLOR="\033[34m"
|
||||
;;
|
||||
magenta)
|
||||
local COLOR="\033[35m"
|
||||
;;
|
||||
cyan)
|
||||
local COLOR="\033[36m"
|
||||
;;
|
||||
esac
|
||||
|
||||
echo -e "${COLOR}${TEXT}${NO_COLOR}"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue