Last active
October 10, 2015 00:48
-
-
Save codeb2cc/3606144 to your computer and use it in GitHub Desktop.
PS1 on server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Reset | |
Color_Off='\e[0m' # Text Reset | |
# Regular Colors | |
Black='\e[0;30m' # Black | |
Red='\e[0;31m' # Red | |
Green='\e[0;32m' # Green | |
Yellow='\e[0;33m' # Yellow | |
Blue='\e[0;34m' # Blue | |
Purple='\e[0;35m' # Purple | |
Cyan='\e[0;36m' # Cyan | |
White='\e[0;37m' # White | |
# Bold | |
BBlack='\e[1;30m' # Black | |
BRed='\e[1;31m' # Red | |
BGreen='\e[1;32m' # Green | |
BYellow='\e[1;33m' # Yellow | |
BBlue='\e[1;34m' # Blue | |
BPurple='\e[1;35m' # Purple | |
BCyan='\e[1;36m' # Cyan | |
BWhite='\e[1;37m' # White | |
PS1="${Green}[\u@`/sbin/ifconfig eth0 | sed -n '0,/^\s\+inet addr:\([0-9]\+[.][0-9]\+[.][0-9]\+[.][0-9]\+\).*$/s//\1/p'` \W]${Cyan} #\#> ${Color_Off}" | |
export PS1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment