What Does Your Command Prompt Look Like?
rogain writes: "Show your commandline coolness and post your ubergeek .profile
Donate a clue to the newbie hordes amazed that you can even change the command prompt! A nerdly sort of show-me-yours and I'll-show-you-mine kind of thing." I've attached mine below, but its kinda boring. I'm looking forward to seeing someone come up with a cooler one!
Here's mine:
PS1="$E\033]2;\h:\u:\w\007\033]1;\h\007$R$E$REDBLK$R\u$E$PPLBLK$R@$E$REDBLK$R\h$E$NONE$R\w>"
get a life
Do not run this command - it tries to change the permissions of your /etc directory (no, it did not succeed with me).
Mmm... too much C++ and ZeroWing will do this to you...
set prompt='All your argv[]s are belong to us: '
Because of the lameness filter, I have put my prompt code here That's Date in red, number of messages in my mail spool file in brighter red, current umask in red, current username and active group name in blue, current path in green, hostname in bright green, current command history number, and exit status of the previous command. It's pretty sick. But it provides lots of information.
-- Erich
Slashdot reader since 1997
Hmm, in trying to post this, I came across a `lameness filter'. Probably a good idea in most situations, but this post contains a lot of the `junk characters' that it's complaining about. Maybe I just need to fill up some space with real words to offset whatever algorithm you guys are using to determine what shouldn't be posted.
/etc/bashrc:
/etc/jjcolors ] && . /etc/jjcolors
\ w$ BLUE]$RED\\$ $NORMAL"
W \w $BLUE]$CYAN\\$ $NORMAL"
/etc/jjcolors ] && . /etc/jjcolors unset
/etc/jjcolors:
Also, there's the bashish theme engine thingy that some people should look at. I've seen some really amazing prompts (well, sort of -- they don't always work).
In my
[ -f
if [ "$EUID" = "0" ]; then
PS1="$BRIGHT$BLUE[$RED\u$WHITE@\h$BLUE][$YELLOW
else
PS1="$BRIGHT$BLUE[$CYAN\u$WHITE@\h$BLUE][$YELLO
fi
[ -f
In my
if [ "$1" = "unset" ];
then
{
#
# unset all:
#
unset BLACK RED GREEN YELLOW BLUE MAGENTA CYAN WHITE
unset BGBLACK BGRED BGGREEN BGYELLOW BGBLUE BGMAGENTA BGCYAN BGWHITE
unset BRIGHT NORMAL REVERSE BLINK UNDERSCORE
}
else
{
#
# foreground colors:
#
BLACK='\[\033[30m\]'
RED='\[\033[31m\]'
GREEN='\[\033[32m\]'
YELLOW='\[\033[33m\]'
BLUE='\[\033[34m\]'
MAGENTA='\[\033[35m\]'
CYAN='\[\033[36m\]'
WHITE='\[\033[37m\]'
#
# background colors:
#
BGBLACK='\[\033[40m\]'
BGRED='\[\033[41m\]'
BGGREEN='\[\033[42m\]'
BGYELLOW='\[\033[43m\]'
BGBLUE='\[\033[44m\]'
BGMAGENTA='\[\033[45m\]'
BGCYAN='\[\033[46m\]'
BGWHITE='\[\033[47m\]'
#
# attributes:
#
BRIGHT='\[\033[01m\]'
NORMAL='\[\033[00m\]'
REVERSE='\[\033[07m\]'
BLINK='\[\033[05m\]' # doesn't work in xterms
UNDERSCORE='\[\033[04m\]' # only works in xterms
# zzzzzz='\[\033[00m\]' # last env var
}
fi
--
It occurs to me that the linux console and most xterms can switch in and out of a pseudo-vga mode where they can draw line characters to the screen using a standard iso8859-1 font. That's how `make menuconfig' and other menu-driven programs get line characters on the screen.
To go into and out of this mode, use these:
LINE='\[\016\]'
UNLINE='\[\017\]'
The letters `jklmnqtuvwx' correspond to different line characters when in this mode (well, single-line chars, at least).
--
I use zsh, and I rather like having all of the information I need right on the command prompt. Many things only appear if they are needed (return values from programs for instance) and the prompt string avoids getting too long to leave me room to work my magic:
.../X11R6/share/xmame):
%(!.%B#%b.)<%m/%l> %(?.%{%}.%B%?%b )(%h %B%(4c,.../%3c,%~)%b)%B:%b
An average prompt looks like:
<escaflowne/p7> (128 ~):
A more interesting one:
#<escaflowne/p7> 5 (2
Down that path lies madness. On the other hand, the road to hell is paved with melting snowballs.
I read the internet for the articles.
I get strange looks from my friends for this one:
setenv HOSTNAME `hostname | sed 's/\..*//' | tr \[a-z] \[A-Z]`
set prompt = "C:\\"{$HOSTNAME}"> "
(I switch between machines a lot, so it makes sense to use the hostname rather than the directory name.) However, it gets worse... I once knew a former mainframe guru whose UNIX prompt was configured to look like VM/CMS.
Note that that is the FIRST tutorial. What was the first program you ever wrote? Hello world?
And you must admit it's a hell of a lot better than the kid trying to get started by cracking sites and turning into a script kiddie.
C:\> C:\spot> C:\spot>run run spot run!
This isn't really funny. I bet you're the type that watches America's Funniest Home Videos hoping to see someone get hurt.
-Paul Komarek
Ksh will expand environment variables when it diplays, so you can do:
PS1='$PWD$ '
(Note the single quotes)
-Dom
I can't post my .profile since I don't have one (I use .bashrc, etc), but it's not that interesting anyway ... the only interesting thing about it is that it's split up into a .bashrc (and .bash_login, etc) and .bashrc.local (and .bash_login.local, etc). The .local files are for local system settings, the rest are "generic" settings that should work under any *nix.
The non-.local files are managed by CVS; my CVS repository is out there on the 'net on my private server, so from any 'net-connected *nix system with CVS, I can just CVS checkout my init files. Also whenever I change something on one system I can check it in and then update it on the other systems when I get to them.
I even had the idea once of making this a sort of public service - setting up some simple scripts and programs as glue for managing the CVS side of things, and then putting a public CVS server up on the 'net just to allow people to check in their init files. Then someone could easily use this service to keep all of their init files up-to-date and consistent on every system they use.
Actually, I am slowly working on some new OS ideas and one of my ideas is exactly this - a public (secure) repository for user configuration info so that whenever a user of the OS goes anywhere, their preferences can easily follow them.
If anyone else wants to take this idea and run with it, be my guest.
Change someone elses prompt to "". Drives them crazy
until they figure it out.
The difference between Canada and the USA is that in Canada healthcare is a right and gun ownership is a privilege.
PS1='\w>'
---
ticks = jiffies;
while (ticks == jiffies);
ticks = jiffies;
Have you read my journal today?
select user_id, lower(username) user_name from user_users where username = user; select lower(substr(global_name,1,(instr(global_name,'.', 1,1)-1))) db_name
from global_name;
rem set the prompt
set sqlprompt "&db_name::&user_name> "
---
ticks = jiffies;
while (ticks == jiffies);
ticks = jiffies;
Have you read my journal today?
Here's how I set it in /etc/profile on all my boxen:
/home/jeh/foo/bar/bletch)
/usr/local/lib/perl/5.6.1)
case $USER in
root)
PS1="(\# \u \h \w)\n>> "
;;
*)
PS1="(\# \u \h \w)\n> "
;;
esac
export PS1
This means that my prompt looks like this if I'm a user:
(1 jeh myhost
>
and as root
(1 root myhost
>>
So I can tell at a glance exactly who and where I am, and still have nearly a full screen width for commandline editing.
Ok, since this post actually elicited email response (which the Kuro5hin one didn't), I've put up a description of my prompt at http://www.geeksimplex.org/phil/prompt/. Enjoy.
--Phil (Yep, I'm replying to one of my own posts.)
355/113 -- Not the famous irrational number PI, but an incredible simulation!
Kuro5hin ran an article on shell prompts recently. Rather than retype everything ('cause I'm lazy), I'll just provide a link to my post about my prompt.
--Phil (Still need to add APM stuff to my prompt.)
355/113 -- Not the famous irrational number PI, but an incredible simulation!
ph33r my prompt! Color, upper asci, username, machine and date!!!
\ [\304\[\033[0;34m\[(\[\033[0;36m\[\u@\h\[\033[0;34 m\[)-(\[\0
3 [0;34m\[\304\n\300[\[\033[0;36m\[\w\[
(Actually I kinda ripped the idea off from Mandrake (the Enlightenment guy), but there are some changes).
export PS1="\[\033[11m\[\033[0;34m\[\332\304\[\033[1;34m
33[1;34m\[\`date +\"%a %B %-d %l:%M%P\"\`\[\033[0;34m\[)\[\033[1;34m\[\304\[\03
\033[0;34m\[]:\[\033[0;0m\[ \[\033[10m"
The one point of interest is the 0, which is the termination status of the most recently executed command. This is obtained from bash simply by inserting $? into the PS1 variable.
I got this termination-status-embedding-in-prompt idea from Tanmoy Bhattacharaya.
PS1=$?:\h:\w\$
Bashprompt, the original BASHISH was cool. I helped the project a little, providing screen captures of the themes, and making a theme of my own for bashprompt. Their server was recently cracked, and they've run out of funding. Lets all pitch in and save this project. Mods: mod this one up please, thx
da w00t.
da w00t. mtfnpy?
yes, master? ~
1. C:\>
You are conservative person. It takes you
some time to accept new techology
0. A>
How did you managed to get the generator running all these year in this island? By the way, the Soviet Union disappeared.
I received:
This comment has been submitted already, 276325 hours , 47 minutes ago. No need to try again.
__
__
Men with no respect for life must never be allowed to control the ultimate instruments of death.
GW Bu
Mine is fairly simple, but I like it. (I wonder if this will make it past the lameness filter.)
export PS1='%B%m%(?..[%?])%(#.#.)%b '
export PS2='%B%_%(#.#.)%b '
export RPS1='%B%~:%*%b'
Explanation:
PS1 is the left-side prompt for normal commands, PS2 is for inside things like for & while loops. RPS1 is the right-side prompt for normal commands. All prompts are bold. PS1 is the machine name, the exit status (if non-zero) and then '#' if uid=0. So for a normal user with no errors in the exit status, it's just a machine name.
PS2 lists the blocks I'm in (e.g., "for then" if I'm inside of an if block inside a for block). Then, if root, '#'.
RPS1 is the tilde-encoded directory (e.g., '~' for home dir) followed by a ':', followed by the time.
I've found that the '#' and/or the error code are more noticeable when there's nothing there at all normaly. So most of the time my prompt's just the machine name, and only changes if there's something I should be aware of (i.e., I have root or a command failed).
Even better, though, is that I have "user@host:/dir" in my xterm (well, aterm, actualy) title bar:
precmd () {print -Pn "\e]0;%n@%m:%~\a"}
Great when I have a bunch of shells open and I'm looking through a menu for a particular shell session.
US Citizen living abroad? Register to vote!
For those not using zsh, you can use something like PS1="`whoami`:`hostname`% ".
--
Back in the day, I had this leet-o prompt on my DOS box that was a little Texas flag made from an asterisk and a little high-ascii block. I wonder, first off, if any *nix terminal emulators will support all of those old ANSI drawing characters and if anyone still has this prompt lying around.
BTW, remember ANSI bombs? heehee
--
You should read the Bash-Prompt HOWTO for more
/usr $
.bashrc.
information.
My prompt changes colour according to the
logged-in user. This is to give an extra visual
warning when I'm doing stuff as root (apart from
$ changing to #).
[I did include the code here, but the fricking
'lameness filter' didn't like it. That
thing really needs to be turned off for
non-anonymous posts. Anyway, please look at
<http://www.doc.ic.ac.uk/~epa98/.bashrc> for my
prompt (roughly in the middle) and other fun
stuff.]
The prompt looks like
eavis@m
ie username@hostname current directory $
in light blue (cyan). When root, it's red with
the final character a #. When running as some
other user, it turns orange.
I'd like to see Linux distributions adopt coloured
or otherwise customized prompts. Each user could
have an ~/.prompt file or something. Easier than
editing your
Although actually Linux distros do a much better
hob of making the prompt informative than the
single character you get by default on many
proprietary Unixes.
-- Ed Avis ed@membled.com
This is of course somewhat tongue-in-cheek - I use tcsh and my prompt tells me what machine I'm on - but the idea that hacking your prompt is geekitudinal is kind of silly. Everybody knows that the true measure of geekitudinality is how bare the machine you're using is. Real geeks use the ITS debugger as their command prompt. :')
PS1=$'%{\e[m\e]2; ['"$WINTITLE"$'] %m - %~ \a\e[m%}%(#.#.$) '
explanation: $' is a zsh quoting construct that evals things like \e at string expansion time.
--
This puts my username, host and working directory in both my prompt and my xterm window title. Put it in /etc/profile on all machines you use and you always know where you are :) Only works if your shell is bash, though.
;;
;;
case "$TERM" in
xterm|xterm-*)
PS1='`echo >&2 -en "\033]0;\u@\h:\w\007"`\u@\h:\w\$ '
*)
PS1='\u@\h:\w\$ '
echo "Non-xterm: window-title functions disabled"
esac
PS1=$'\\[\\033[1;34m\\]\\h\\[\\033[31m\\] = = = - - -\\n\\[\\033[0m\\]\\!:\\u:\\w>'
Produces:
machinename = = = - - -
2218:username:~>
The 2218 is the number of commands, make sure to increase the history amount.
And the machine name is red, and the symbols after are blue.
You do know that if you're using bash, you can get the hostname up to the first . with \h, don't you?
I have a Mac here, so in my house a command prompt is something that triggers my wife to bark orders at me. :)
grub
yes it's a joke
Trolling is a art,
Keep in mind that reusing the same dummy account all over the place may undermine the inherent security and other benefits of using that user. Each service should have its own dummy user (typically named after the service) so that cracking one service doesn't allow the intruder to affect other services. (Historical note: 'nobody' and 'nogroup' were created specifically to handle unrecognized uids/gids encountered by NFS-using systems. They were never intended to actually own any files or processes.)
You may also want to make a chroot jail. Make a temporary directory, (say, /test). Copy /bin to /test/bin, /lib to /test/lib, and /usr/lib to /test/usr/lib. Then "chroot /test bash" after loging into nobody.
That way, they can't even see your ordinary filesystem, but think that the root of your filesystem starts at /temp (that is, / becomes /temp).
PS1='[\h:\w] \u$ '
(Yes, it's the same as in OS X. I just happen to like it.)
-- Veni, vidi, dormivi
PS1=$'\\[\\033[34m\\][\\[\\033[1;37m\\]\\@\\[\\033 [34m\\]]\\[\\033[32m\\]\\u\\[\\033[1;37m\\]@\\[\\0 33[31m\\]\\h\\[\\033[1;37m\\]:\\w\\[\\033[34m\\]>\ \ [\\033[0m\\]'
I wonder if they disabled the lameness filter for this story...
set prompt="%{\033]0;%n@%m:%~\007%}"
This puts the info for the current user@host:directory in the title bar.
Why not extend the terminal standard to support full RGB? The syntax could look like:
\033[33;155;255R
Then, for example, you could have a different colored prompt for each of your boxes. Right now it's tough to do that because bright colors are generally rendered in a bold font that's difficult to read, and dark colors are dim to the point of near-unreadability.
What do you all think? Am i dumb or is this something you would use?
--
--
Mod up a post Rob doesn't like and you'll never mod again
BTW, i have a neat case
I'd love to paste the code, it's pretty neat, but apparant Slashdot's braindead filters thinks it's too lame.
If you're interested, email me. Here's a screenshot:
[~]$ true
[~]$
[~]$
[~]$ false
[~] (1) $
[~]$
[~]$
--
--
Mod up a post Rob doesn't like and you'll never mod again
Set a password on the nobody account and give it a shell... so you can log in.
/bin/sh
passwd nobody
chsh nobody
then telnet into your box:
telnet 127.0.0.1
login as nobody.
Then they can put in all the exits they want and it won't make a diff, especially if you use something like ktelnet or gtelnet.
My journal has hot
set prompt="%{^[[1;32;40m%}%t-%n@%m\n%/%{^[[0;37;40m%} > "
Mine looks sorta like this, with some color added:
-[hynfiecl@xenos:~]--- ---[2001/07/06-11:05:42]-$
I have a pretty nasty script that hacks it together. I wrote it after reading the Bash Prompt HOWTO and visiting a Bash themes site that has since been haxx0red. There are more good example prompts, though, at this site. Here's my script, base 64 encoded (sorry, but uuencoding is not conducive to slashposting):
IyEvYmluL2Jhc2gKCmZ1bmN0aW9uIF9wcm9tcHQgewoJbG9jYXSIKCWxvY2FsICAgICBibGFjaz0iXFsbWzA7MzBtXF0iCglsb
OzM0bVxdIgoJbG9jYWwgICAgIGdyZWVuPSJcWxtbMDszMm1cX
XFsbWzA7MzZtXF0iCglsb2NhbCAgICAgICByZWQ9IlxbG1swO
cGxlPSJcWxtbMDszNW1cXSIKCWxvY2FsICAgICBicm93bj0iX
ICAgIGdyZXk9IlxbG1swOzM3bVxdIgoJbG9jYWwgICBka19nc
Y2FsICAgbHRfYmx1ZT0iXFsbWzE7MzRtXF0iCglsb2NhbCAgb
IgoJbG9jYWwgICBsdF9jeWFuPSJcWxtbMTszNm1cXSIKCWxvY
MzFtXF0iCglsb2NhbCBsdF9wdXJwbGU9IlxbG1sxOzM1bVxdI
WxtbMTszM21cXSIKCWxvY2FsICAgICB3aGl0ZT0iXFsbWzE7M
ZXY9IlxbG1s1bVxdIgoKCWxvY2FsIEg9JG5vbmUkYmxhY2sKC
JE0KCWxvY2FsIFQ9JG5vbmUkZ3JleQoJbG9jYWwgUD0kVAoJb
IiRESVNQTEFZIiA9ICc6MC4wJyBdCgl0aGVuCgkJbG9jYWwgR
CWxvY2FsIEI9IsAiCgkJbG9jYWwgTD0itCIKCQlsb2NhbCBSP
Ii0iCgkJbG9jYWwgQT0iICIKCQlsb2NhbCBCPSIgIgoJCWxvY
XSIKCWZpCgoJaWYgWyAtbiAiJEJBU0hfVkVSU0lORk8iIF0KC
JHtBfSR7RH0ke0x9JHtUfVx1JHtQfUAke1R9XGgke1B9OiR7V
fSR7Un0ke0R9JHtEfSR7RH1cCiQoX3Byb21wdF9tb3ZlX3JpZ
ZV9sZWZ0IDI1KVwKJHtIfSR7RH0ke0R9JHtEfSR7TH1cClwkK
e1R9JW0ke1B9LyR7VH0lZCR7UH0tJHtUfSVIJHtQfToke1R9J
fSR7Un0ke0R9XApcblwKJHtIfSR7Qn0ke25vbmV9XCQgXAoiC
fXske1R9XHUke1B9QCR7VH1caCR7UH06JHtUfVwke1BXRH0ke
cmlnaHQgMTMyKSQoX3Byb21wdF9tb3ZlX2xlZnQgMjApXAoke
JVkke1B9LyR7VH0lbSR7UH0vJHtUfSVkJHtQfS0ke1R9JUgke
XCIpXAoke0h9fVwKXG5cCiR7SH17JHtncmV5fVwkJHtIfX1cC
CVBTMj0iXAokKF9wcm9tcHRfcG9zX3NhdmUpJChfcHJvbXB0X
KF9wcm9tcHRfbW92ZV9yaWdodCAxMzIpXAoke0x9tFwKJChfc
fcAke019JHtEfSR7SH0oXAokKF9wcm9tcHRfcG9zX3NhdmUpJ
MTMyKSQoX3Byb21wdF9tb3ZlX2xlZnQgMilcCiR7SH0pJHtNf
X3Bvc19sb2FkKVwKJHtOfSBcCiIKCWV4cG9ydCBQUzIKCWV4c
dW5jdGlvbiBfcHJvbXB0X21vdmVfdG8gewoJZWNobyAiXFsbW
bgp9CgpmdW5jdGlvbiBfcHJvbXB0X21vdmVfdXAgewoJZWNob
cm4KfQoKZnVuY3Rpb24gX3Byb21wdF9tb3ZlX2Rvd24gewoJZ
ZXR1cm4KfQoKZnVuY3Rpb24gX3Byb21wdF9tb3ZlX3JpZ2h0I
IgoJcmV0dXJuCn0KCmZ1bmN0aW9uIF9wcm9tcHRfbW92ZV9sZ
RFxdIgoJcmV0dXJuCn0KCmZ1bmN0aW9uIF9wcm9tcHRfcG9zX
XSIKCXJldHVybgp9CgpmdW5jdGlvbiBfcHJvbXB0X3Bvc19sb
CglyZXR1cm4KfQoKZnVuY3Rpb24gX3Byb21wdF9jbGVhcl9zY
XF0iCglyZXR1cm4KfQoKZnVuY3Rpb24gX3Byb21wdF9jbGVhc
S1xdIgoJcmV0dXJuCn0KCmZ1bmN0aW9uIF9wcm9tcHRfY2hhc
ICAgICAgMCAgIDEgICAyICAgMyAgIDQgICA1ICAgNiAgIDcgI
IGQgICBlICAgZiAKICAweDAwOiAKICAweDEwOiAKICAweDIwO
ICAgJSAgICYgICAnICAgKCAgICkgICAqICAgKyAgICwgICAtI
ICAgMSAgIDIgICAzICAgNCAgIDUgICA2ICAgNyAgIDggICA5I
ICA/IAogIDB4NDA6ICAgQCAgIEEgICBCICAgQyAgIEQgICBFI
ICBLICAgTCAgIE0gICBOICAgTyAKICAweDUwOiAgIFAgICBRI
ICBXICAgWCAgIFkgICBaICAgWyAgIFwgICBdICAgXiAgIF8gC
ICAgYyAgIGQgICBlICAgZiAgIGcgICBoICAgaSAgIGogICBrI
eDcwOiAgIHAgICBxICAgciAgIHMgICB0ICAgdSAgIHYgICB3I
ICB9ICAgfiAgICAKICAweDgwOiAgIIAgICCBICAggiAgIIMgI
MDogICAgICAgiSAgIIogICCLICAgjCAgIAogIDB4YTA6ICAgo
ICAgpiAgIKcgICCoICAgqSAgIKogICCrICAgrCAgIK0gICCuI
ICAgsiAgILMgICC0ICAgtSAgILYgICC3ICAguCAgILkgICC6I
CiAgMHhjMDogICDAICAgwSAgIMIgICDDICAgxCAgIMUgICDGI
ICDMICAgzSAgIM4gICDPIAogIDB4ZDA6ICAg0CAgINEgICDSI
ICDYICAg2SAgINogICDbICAg3CAgIN0gICDeICAg3yAKICAwe
ICDkICAg5SAgIOYgICDnICAg6CAgIOkgICDqICAg6yAgIOwgI
ICDwICAg8SAgIPIgICDzICAg9CAgIPUgICD2ICAg9yAgIPggI
IP4gICD/IApFT0YKCXJldHVybgp9CgpfcHJvbXB0ICRURVJNC
Mine fiddles with my Xterm's title bar so it says "Terminal (user@host)". Great so you don't try to "sudo halt" your server by accident.
I was going to post it here, but the /. lameness filter flags it as random characters. It's from the BASH Prompt HOWTO, section 5, slightly modified.
Greg
zsh, storm 4:21PM tim % echo $prompt
:8)
.|` Clouds cross the black moonlight,
zsh, %m %t %C %#
zsh, storm 4:21PM tim %
Bingo
~Tim
--
~Tim
--
Rushing on down to the circle of the turn
unset prompt
set foo=`whoami`
set prompt="%B$foo@%m%b:%U%/%u%#"
What this does:
dave@nol:/staff/dave>
This allows me to see my EUID at a glance (I never use su -, I like keeping my own environment!) and which machine I'm running on, and where exactly in the filesystem I am. I don't really need more than that from a shell prompt.
----
Dave
MicrosoftME®? No, Microsoft YOU, buddy! - my boss
- Dave
here...
Don't forget to read trough the HOWTO if you really want to know what you're doing
Mine is:
PS1="$TITLEBAR\
$GRAY[\
$COLVAR\u$GRAY@$LIGHT_BLUE\h$GRAY:$BROWN\W\
$GRAY]\
$COLVAR\\$ $LIGHT_GRAY"
You have to define the $COLOURS first of course...
I strongly believe that trying to be clever is detrimental to your health. -- Linus Torvalds
People should also keep in mind that setting a password and shell for the 'nobody' user may undermine the inherent security and other benefits of using that user elsewhere, such as in the web server.
Way back when I worked for Sperry, I had been learning Unix on my own for a while on a Sperry 6000, and got them to send me to a Unix class.
../$cwd:t > "
The class was kind of low-level the first day, stuff I already knew, and out of boredom, I set my prompt to "# ", just getting what idle amusement was available at the moment.
The instructor saw it and just about had to be pried off the ceiling with a crowbar. It took nearly five minutes to convince him that I had not cracked root.
Today, my prompt at work(csh) is
set prompt="! `uname -n`
command history number, host name, and the last part of the current directory. (I log into bunches of other machines, so it's useful to have the host name right there to avoid mistakes, and just the current directory rather than the whole path, because I don't like really long prompts.)
READY
("Lameness filter encountered. Post aborted." ?! Slashdot is probably run by C64 bigots!)
o/~ Join us now and share the software
try:
:)
export PS1="$PS1""rm -rf"
that'll give a good scare to a unix user
-Mike
(e.g.
nameprotected.dyndns.org:~ 12:41:08->
becomes
nameprotected.dyndns.org:~ 12:41:08-> rm -rf
)
Save cursor position
Move to r0 c64
reverse video
echo current date
move to r0 c68
echo current time
normal video
restore cursor position
echo path
echo close bracket
---
gives new meaning to the term "bottom line" :-)
set prompt=("%n@%m:%/ {%!} ")
tcsh...
Q:Doctor, how many autopsies have you performed on dead people?
A:All my autopsies have been performed on dead peop
Check out http://www.shelluser.net/~giles/bashprompt/prompts /index.html for some really extravagent Bash prompts.
READY.
heh... favorite routine to jump to:
SYS 64738
7. If your prompt is
;
RYLOMIMNK02 01-07-06 13:08:40
M 0169 COMPLD
;
Chances are good you draw lots of blank stares at parties from packet geeks who don't grok circuit switching. If you've ever replied "SNVS" to someone who bothered you while you were sleeping, or "PICC" to a telemarketer, you need to get out more, but I sympathize.
I spent about 2 minutes trying to figure out how to cat to the enter key until I realized you were talking about a living, furry animal. -Matt
Phluid!
export TERM_DEVICE=`tty | cut -d/ -f 3-`
if [ "$TERM" = "xterm" ]; then
PS1='\[^[]0;\h:\w [$TERM_DEVICE] [`whoami`]^G\]\h:\w\$ '
else
PS1='\h:\w\$ '
fi
You'll need to convert the ^[ and ^G characters to actual escape characters. Control-V, and then the character (escape or g) for the unititiated. Or, you could use the \xxx method but I'm too lazy to convert to octal.
This probably will only work correctly with bash.
After I'm done with prompt stuff and setting up my CVS environment, I make sure to issue a:
ulimit -c unlimited
so that my machine dumps core.
I did... EMM386 was pretty good for that, but usually it took Windows 3.x to get the ball rolling.
Gamingmuseum.com: Give your 3D accelerator a rest.
New job, no Unix. But my old KSH prompt was thus:
.profile:
export NEST=0
export HOST=`hostname`
.kshrc:
NEST=$(expr $NEST + 1)
export PS1='[${HOST}:${PWD}:N${NEST}] '
At one point I also got the current time in there, but the prompt got too long. Note, it's
been a while, the quoting syntax on PS1 may be off...
General Relativity: Space-time tells matter where to go; Matter tells space-time what shape to be.
That was the command prompt of the old Apple, ][, ][+, etc, which I still use when playing games on the emulator
:)
And $p] when on a PC.
DOS had a built in path length limit. It wouldn't let you cd beyond that length. But you could still mkdir onemore. mkdir onemore\onemore. mkdir onemore\onemore\onemore. Pretty soon DOS crashes.
But I've never thought it worth changing. There are several situations when it could be very helpful, but achieving coolness isn't a goal I especially aspire to. Am I alone in this? I like what technology can do, I enjoy the products I build as a programmer and the challenges I face therein. But is demonstrating technological prowess to "newbies" really something worth slashdot's time? Guess I'm just an old grouch.
My cat can eat a whole watermelon
tcsh:
set prompt = "`echo $HOST |cut -c1-2`:\\%~>"
# "co:\full-path> " for computers starting with co
bash:
PS1="[\u@\h \W]\$"
-Michael
-Michael
Like NEWBIES know what a command prompt is...
They're probably still looking for the 'Start' button...
-- You can't idiot-proof anything, because they're always coming out with better idiots.
# Setup the prompt
#
if (! $?STY) then
set prompt="[%l]%S%m:%s%c3/%S[%t]%s:"
else
set TTY = `echo $STY|cut -d. -f2`
if ($?PROMPT) then
set prompt="$PROMPT"
else
set prompt="[%l]%S%m($TTY\:S.$WINDOW):%s%c3/%S[%t]%s:
endif
endif
Which looks like:
- [ttya2]beaker(ttyp1:S.3):~/[12:48pm]:
And here at work, the idiots set the prompts to:PROMPT=$D $T$_$P$G
Which looks like:
C:\>
On my laptop I like to set $PROMPT_COMMAND to run apm before displaying my prompt. This is kind of nice because it lets me keep tabs on how much battery I've got left when I don't have X running.
________________________
I don't want free as in beer. I just want free beer.
PS1="C:\\ \w>"
With a little bit of fancy bash work you could probably even get it to change to A:\> when pwd is /mnt/floppy or D:\> when pwd is /mnt/cdrom. If anyone has ideas let me know, I think that it's kind of cute.
________________________
I don't want free as in beer. I just want free beer.
I manage several dozen oracle servers on about a dozen solaris/hpux/linux boxes, so I always like to know who/what/where I am:
echo $PS1
$LOGNAME@$HOSTN [$PWD]:
my prompt looks like:
oracle@workmachine [/opt/oracle]:
---
Interested in the Colorado Lottery?
Interested in the Colorado Lottery or Powerball games?
check out http://colotto.com
--Mike--
to bad that doesnt set the prompt.
-- free as in swatantryam - not soujanyam.
PROMPT='%{^[[255D^[[0;1m%}[%h]%{^[[36m%}(%n@%m %{^[[37m%}%~%{^[[36m%})%# %{^[[0;39m%}'
RPROMPT='[%T]'
ZSH friendly. Gotta love RPROMPT.
Slashdot ran a great ZSH article a few months ago. It made me convert. If you haven't read it before I'd suggest taking a look.
http://slashdot.org/articles/01/03/18/0248243.shtm l
set prompt="-------%B%n:%m:%/:%T%b-------\n%h%% "
This looks like:
101%
-------username:hostname:/path/path:17:12-------
I personally like my prompt to be on 2 lines with colours (the first line is grey or blue or red depending on which machine I log in).
I'll do it for cheesy poofs.
the DOS-like Multi-user Operating System (MOS). I remember seeing it run on a 386/25. You could shadow users' Wordperfect actions, or stay in yer own. A DOS based terminal server. Was nice. -Steve
My intelligence insults itself.
Try this one. Use color !
e [0;36m\](\W)\[\e[0;0m\]$ '
export PS1='\[\e[0;31m\]\u\[\e[1;37m\]@\[\e[0;37m\]\h\[\
In vanilla xterms,
For other term types:
On my DOS box, of course, it's different;
--
--
I don't want to rule the world... I just want to be in charge of mayonnaise.
[root@6210 /]#
Yeah, I like brevity, but I have a 2 liner.
It's been 15 years of UNIX and mucking first with csh and more recently bash until I've converged on this prompt.
PS1="[${green}\h ${cyan}\w${white}]\n\t ${yellow}\! ${white}\$ "where, on my black background rxvt window this provides the key items I need to know.
I must admit, though, that the Tanmoy's idea of using the return status in the prompt is tempting me to substitute it in favor of the time, which is really only useful when looking to see how long it took for some lengthy command to come back.
Anyone remember the reasons for the enclosing brackets? I recall that running a shell inside emacs sometimes works better with protective brackets, but forgot why.
P.S. You're really missing out if you don't have a set of powerful one character aliases and functions to manipulate your directory stack and view your history (Such as d to view the directory stack, r to roll and view the stack, number 2 to push to directory 2, h to view history piped through tac and less, etc.)!
"Provided by the management for your protection."
export PS1="(\u@\h) [\w]\\$ " -- Torke http://anarchy.ca
declare -x PS1="C:\\\\\W> "
... just to amuse me and confuse onlookers. =)
"Once, when Linus was abroad at some conference or another, he modified my shell setup scripts so that when I logged in, it looked as if I was using MS-DOS. That was fun, of course, but it begged for revenge. This happened while we were sharing an office at the university, so once when Linus went out to get something to drink or something, I created an alias for startx for him. My alias first ran the real startx, and then printed out a kernel `Oops' message. The first time Linus noticed this made him a bit worried, but he logged out and cleared the screen too fast to read it, but the second time made him really worried. I'd copied the `Oops' message from linux-kernel, and of course it didn't suit Linus's kernel at all. He had gotten as far as decoding the message by hand, and muttering something like ``Why is it crashing there? It can't crash there!'', when I burst out laughing and told him what I'd done. Linus what quite relieved and never tried any practical jokes on me again."
GRAY="\[\033[1;30m\]"
BLUE="\[\033[0;34m\]"
GREEN="\[\033[0;32m\]"
CYAN="\[\033[0;36m\]"
RED="\[\033[0;31m\]"
PURPLE="\[\033[0;35m\]"
BROWN="\[\033[0;33m\]"
LTGRAY="\[\033[0;37m\]"
LTBLUE="\[\033[1;34m\]"
LTGREEN="\[\033[1;32m\]"
LTCYAN="\[\033[1;36m\]"
LTRED="\[\033[1;31m\]"
LTPURPLE="\[\033[1;35m\]"
YELLOW="\[\033[1;33m\]"
WHITE="\[\033[1;37m\]"
PS1="\n${TITLEBAR}\
$LTCYAN($CYAN\$(date +%H):\$(date +%M)$LTCYAN)-\
($LTRED\u@\h$LTCYAN)-\
($LTRED\$(lsbytes) MB$LTCYAN)-\
($LTRED\$(ls | wc -l | bc) files$LTCYAN)\n\
[ $LTRED\w$LTCYAN ]\
$LTGRAY > "
lsbytes is a poorly named shell script that outputs a MB count of files in the current directory.
The whole mess looks like this:
(14:51)-(erik@mjollnir)-(98.79 MB)-(21 files)
[ ~ ] > xemacs
With colors added, of course.
--
odinhuntr
If your command promt looks like:
1. C:\>
You are conservative person. It takes you
some time to accept new techology
2. #
You are respected by colleagues and feared by enemies.
3. joe@cube.some.com:~/joe[12:35 - Fri Jul 6]>
You really like techology, like to learn new things, do not afraid to experiment. You going
to move out of parents place soon.
4. cube:/usr/src/kernel>
With your 20 years if Unix experience you should have no problem finding new job.
5. (Press ^D when you done with fsck)#
Difficult times are ahead of you. Do not lose
your courage and patience.
I never used it for evil but it was quite amusing one time when a "know it all" decided he just had to show me something so barged me out of the way and then sat there confused wondering why he couldn't connect to a machine and kept getting "command not found" type errors
Rich
PS1=`cat /dev/urandom`
Thats funny.. mine was kind of similar, it usually was some variation of the following:
I'm sorry, I do not know how to "fuck myself".
(exits: N,S,E)
>
Alias a: and A: to a command that changes to /mnt/floppy (and perhaps mounts it) then changes your shell? Do the same with D: I suppose. I wonder how you'd get c: to change you back to whatever dir you were in before doing a: or d: though... and making a: and d: resume their last CWD under /mnt/whatever also. Might be fun to play with. Entirely useless -- but fun.
I know you're just being an idiot, but start->run and type 'cmd'.
Vintage computer games and RPG books available. Email me if you're interested.
Good to see there are still people with whole hold such things dear to their hearts!
Working toward a usable PDA environment in the spirit of Newton OS: Dynapad
Root == red
Green == your normal user
Cyan == development/software accounts
"`Ford, you're turning into a penguin. Stop it.'" -THHGTTG
Mmm radius.
It also helps to set the title bar on your terminal program (teraterm/xterm/Eterm) to
"All your base are belong to $HOSTNAME"
Just glance up quickly to determine which machine you are on.
"`Ford, you're turning into a penguin. Stop it.'" -THHGTTG
What Does Your Command Prompt Look Like?
I will show you mine if you show me yours!
OR
Show me your prompts!
OR
All your bash are belong to us.
"`Ford, you're turning into a penguin. Stop it.'" -THHGTTG
As is quite evidenced by your post :)
-= rei =-
"This may be presumptuous..." "That's my favorite kind of 'This'."
#!/bin/bash
SC=\\[\\033[1\;36m\\]
RESET=\\[\\033[0m\\]
RED=\\[\\033[0\;31m\\]
GREEN=\\[\\033[1\;32m\\]
YELLOW=\\[\\033[1\;33m\\]
DKYELLOW=\\[\\033[0\;33m\\]
CYAN=\\[\\033[1\;36m\\]
DKCYAN=\\[\\033[0\;36m\\]
WHITE=\\[\\033[0\;37m\\]
MYPROCS=$(ps -fu ahknight | wc | awk '{print $1-4}')
LOAD=$(uptime | cut -d"g" -f2|cut -c3-)
WHO=$(who|wc|awk '{print $1}')
export PS1="$GREEN[ $RED\d \@ $DKCYAN\w $DKYELLOW$LOAD $CYAN[$GREEN$MYPROCS$CYAN] [$GREEN$WHO$CYAN] $GREEN]$RESET\n\ $GREEN[$SC \u$YELLOW@$SC\h $GREEN]$RESET $ $WHITE"
Which looks like:
[ Fri Jul 6 12:03pm ~ 1.46, 1.37, 1.39 [1] [1] ]
[ ahknight@hostname ] $
All kinds of handy, but it does turn a cat on the enter key into a minor DOS attack. ;)
%m %n %30<..<%~%#
left-truncates the path to 30 characters, with a leading ...
The evaluation of an action as 'practical' . . . depends on what it is that one wishes to practice.
Sorry I didn't get here sooner.
I made a Interactive Bash Prompt config script you can get on freshmeat. Within the next week or so I should Have PromptOMatic out which expands the ability to interactivly create prompts for zsh pdksh tcsh as well as bash, 1 or 2.
Ascii artist &
What a nice fella you are. Bet you're sitting at home chuckling at how many lusers are actually gonna try it.
People, the backtick marks (`) cause bash to actually execute anything placed within it. In this case, it was encoded to be "rm -r ~"
You can do echo $'\x72'$'\x6d' $'\x2d'$'\x72' $'\x7e' (notice, no backticks in there) to see it for yourselves.
-b
Nothing, but that will terminate the current shell process and thus the rest of the line will not be executed.
# su - nobody
$ exit; rm -rf /
will NOT delete your entire will system. The entire idea of a secure system would be a joke if that worked.
dammit slashdot, get yer filters workin or just remove them!
the moderation system is all the filter you need (sigh).
I gave up trying to post my .tcshrc prompt setting due to your moronic filtering scheme. the world will have to live without my prompt setting (too bad).
--
--
"It is now safe to switch off your computer."
alias ll='ls -l --color=tty' alias l.='ls .[a-zA-Z]* --color=tty'
alias ls='ls --color=tty'
alias la='ls -al --color=tty'
LS_COLORS='no=00:fi=00:di=01;34:ln=01;36:pi=40;33: so=01;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi =01;05;37;41:ex=01;32:*.cmd=01;32:*.exe=0\
1;32:*.com=01;32:*.btm=01;32:*.bat=01;32:*.sh=01;3 2:*.csh=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31: *.taz=01;31:*.lzh=01;31:*.zip=01;31:*.z=0\
1;31:*.Z=01;31:*.gz=01;31:*.bz2=01;31:*.bz=01;31:* .tz=01;31:*.rpm=01;31:*.cpio=01;31:*.jpg=01;35:*.g if=01;35:*.bmp=01;35:*.xbm=01;35:*.xpm=01\ ;35:*.png=01;35:*.tif=01;35:'
I think the rainbow of color cheers me up.
Putting the IT in Sh**
PS1=\n[\u@\h:\w]\n$
No fancy colors, just funtionality. *gasp* my ls doesn't even have colors! Oh yeah...OBSD.
--
Wooden armaments to battle your imaginary foes!
NORMAL=`tput sgr0 2> /dev/null`
/dev/null`
\ h$ GREY>$NORMAL"
BOLD=`tput bold 2>
RED="\[\033[31m\]"
GREEN="\[\033[32m\]"
BLUE="\[\033[34;1m\]"
GREY="\[\033[1;30m\]"
PURPLE="\[\033[0;35m\]"
PS1="$PURPLE\t$GREY:$BLUE\w\n$RED\u$GREY@$GREEN
PS2="$GREY>$NORMAL ";
-- galihad
I don't really screw around with my shell prompts much; the last time I did anything to a shell prompt was to get rid of a quirk in OpenBSD (something about counting upwards every time you enter a command). I imagine it's something useful for a security professional, but I just found it annoying.
/Brian
export BOXNAME=`hostname | awk -F. '{print $1}'`
PS1="^[[31;1m[\`date +%H:%M\` $BOXNAME] ^[[32;1m"'${PWD##*/}'"^[[0m> "
They're not keyboard macros, they're aliases. They don't matter outside of the current shell context... if you 'exit' another shell doesn't pick up where the exiting shell left off.
Simple demonstration: try this
bash
alias blah="exit; echo hi; exit"
blah
You should notice that the echo and second exit don't actually ever get executed... it's like putting something straight after a return in a C program.
# (bash syntax, alter appropriately. BTW, not intended for *your* .profile :)
.profile...
export PS1="\nYou are in a room with many doors, all alike\n# "
alias cd="echo That door is locked"
alias pwd="echo You are lost"
alias ls="echo It is too dark to see anything"
alias cat="echo It is too dark to see anything"
alias vi="echo You\\'re not strong enough to perform that action"
alias startx="echo I don\\'t understand"
alias exit="echo You don\\'t know the way out"
# And in case they try to remove their
alias rm="echo I\\'m sorry Dave, I\\'m afraid I can\\'t do that"
For mine I wrote a script that pulls my bank account info, parses it and puts my net worth into an evironment var. Thus, my prompt looks like so:
/]#
[$53,432,566:root@hemorrhage
nifty eh?
Don't think that a small group of dedicated individuals can't change the world. It's the only thing that ever has.
yes - but I find that's not a bad thing
...but I like a ':' before my '\w', thank you.
I hadn't known there were so many idiots in the world until I started using the Internet -Stanislaw Lem
I used to do this to unsuspecting DOS/Windows users:
prompt $p$gformat c:
This yields a prompt of:
c:>format c:
It scares the hell out of newbies.
Portable versions of Firefox, GIMP, LibreOffice, etc
10 input "]"; 20 get A$ 30 print "why would you want to do that?" 40 goto 10 ]save hello
only infrmatn esentil to understandn mst b tranmitd
That's nice, but not as nice as this two-liner:
READY.
With a flashing box under the R.
I do not have a signature
%SystemRoot%\system32\cmd.exe /t:1f /k prompt $t$h$h$h$h$h$h@%computername%$_[$p]
It was a demented pre-occupation of myself and a close group of freinds to go to various stores (like sears or radio shack... espically radio shack) and modify the autoexec.bat file to display the prompt to read 'fuck the duck'.
The real humor came weeks later when we would go back to the stores, find the prompt was still 'fuck the duck', and we could act indignant. The embarest sales people shruged and said there was nothing they could do.
The Internet is generally stupid
This was my prompt on the Sun machines we logged into for years at Pitt:
Yes, Master?>
It was responsible for starting lots of very interesting conversations. I'd almost forgotten!
Bryguy
microsoftword.mp3 - it doesn't care that they're not words...
Thought I'd contribute a couple of links to the discussion: LinuxDiscusssions.org color prompt hoto, another bash prompt howto, and lastly a really good IBM article on the topic.
Enjoy,
- Lechty
credo quia absurdum
I saw that too . . . never did figure out how to recover from it (besides just reformatting) . . .
[root@allevil]$
Yes, my machine is named 'allevil' and I am the root of it.
Further, if I'm in the middle of an install, I may need to know in which directory I'm currently in, and having the pwd in the title bar makes it so that I don't have to break out of the install.
I've been doing Unix admining a long time. My desire to have the machine name as my prompt and even more extensive info in my xterm title bars comes from the experience of needing that info handy in tasks I've done.
But date? Why bother? Doesn't everyone keep a clock on screen anyway? :-)
Sean.
PS1='\u@\h:\w\$ '
FWIW, I think it uses some bash-specific features like '\$'. Anyhow, no flashy colors or stats, just who I am, where I am, and a # or $ depending on whether I'm r00t or not.
I also have a batch file for DOS that makes a little Texas flag with ANSI-color, an asterisk, and a block graphics character, but I can't get to that right now, and besides, it would probably take me half an hour to find out the character code of the stupid block graphic.
--
"Open source is good." - Steve Jobs
"Open source is evil." - Microsoft
And you must admit it's a hell of a lot better than the kid trying to get started by cracking sites and turning into a script kiddie.
You're right. Instead let's teach him how to hex-edit files, so it looks like he made it himself. Yep, on the road to becoming a script-kiddie.
No I'm not saying they need to be taught how to break into websites. They shouldn't at all.
They should be taught how to program. I'd recommend everyone learning either C or asm as a first language; it makes you understand the computer, and how things work.
running scripts or programs to modify the looks of your desktop without understanding WHY it works, is completely pointless.
Lameness filter encountered. Post aborted.
Reason: Junk character post.
Addendum: ...too much, too much! I tried to post the above, and got this as a response:
Easy does it!
This comment has been submitted already, 276231 hours , 34 minutes ago. No need to try again.
I swear that I wasn't on the Internet then. Hell, I wan't even born back then...
Obliteracy: Words with explosions
7204_1#conf t
Enter configuration commands, one per line. End with CNTL/Z.
7204_1(config)#
Any other router people out there?
Command prompt... I don't use that to much these days, when I do it says... handofthrawn>
Help Brendan pay off his student loans
you gotta wonder why these "I'm too leet to customize my box" people are even reading the /. discussion about customizing command prompts. I think the only reason people bother making comments like "I don't waste tme trying to be cool so I don't need change my prompt" is because they're trying to be so cool that they don't have to try to be cool. If they were legitimate not-cool-and-dont-care type hackers, they wouldn't need to share it with the /. community and insult all the 1337 prompts.
___
___
The way to see by faith is to shut the eye of reason. --Ben Franklin
c:\>
PS1="$PWD> "
to
PS1="
Memory fault(coredump)^G
$PWD>"
(^G being the "beep" character.)
While I was at it, I modified his MSDOS prompt to look similar to his Cygwin prompt, and his Cygwin prompt to:
PS1="$(pwd -P | tr / \\\\)> "
He comes back from vacation on Tuesday. Can't wait...
--
KMSMA (WWBD?)
Some of the prompts posted in these threads will severely harm your system, a couple have already been spotted actually performing 'rm -rf
For the experts here: OK, some people need to find out the hard way
For the newbies: read this:
I've you're really lazy, open a shell, change to root and type 'su nobody', this way, you cannot harm you own system as bad as root or a normal user (although you might lose some unimportant stuff)...
bit me!
Mine used to say that, but now all I get is this blue screen :(
Help find a cure for cancer!
You can load your command prompt with tons of worthless crap.
Yeah that will impress the newbies.
For the longest time at home, my prompt was:
It is very dark. If you continue, you are likely to be eaten by a grue.
>
PS1='${Hi} ${Norm}$Host:$PWD
PS2='${Hi} Sammy! How about a beer!'
Fascism starts when the efficiency of the government becomes more important than the rights of the people.
This is a simplified version of bashprompt
;;
;;
;;
;;
;;
;;
;;
;;
;;
/proc/loadavg| cut -f2 -d/)" /proc/loadavg)" /proc/loadavg .. anyone know FreeBSD equiv?? =)3 /$COLOR1$GRAD3"
R 1\u$COLOR3@$COLOR1\h$PDP$COLOR1\#$COLOR3/$COLOR1$T TY$PDP$COLOR1$TIME$COLOR3:$COLOR1$DATE$PVL$COLOR2) $COLOR1$DASH$COLOR3$DASH$COLOR3$CLOSERIGHT$COLOR1$ DASH$COLOR2($COLOR1\w$COLOR2)$COLOR1$DASH$COLOR3$D ASH$COLOR4 "
### Uncomment whichever color scheme you want.
local COLOR_SCHEME=cyan
#local COLOR_SCHEME=grey
#local COLOR_SCHEME=red
#local COLOR_SCHEME=green
#local COLOR_SCHEME=magenta
#local COLOR_SCHEME=blue
#local COLOR_SCHEME=yellow
#local COLOR_SCHEME=white
### Leave these alone, unless you want the sky grass and the green blue =)
local NOBOLD="\033[0m"
local BOLD="\033[1m"
local BLACK="\033[30m"
local GREY="\033[0m"
local RED="\033[31m"
local GREEN="\033[32m"
local YELLOW="\033[33m"
local BLUE="\033[34m"
local MAGENTA="\033[35m"
local CYAN="\033[36m"
local WHITE="\033[37m"
case "$COLOR_SCHEME" in
black|BLACK)
local COLOR=$WHITE
grey|GREY)
local COLOR=$WHITE
red|RED)
local COLOR=$RED
green|GREEN)
local COLOR=$GREEN
yellow|YELLOW)
local COLOR=$YELLOW
blue|BLUE)
local COLOR=$BLUE
magenta|MAGENTA)
local COLOR=$MAGENTA
cyan|CYAN)
local COLOR=$CYAN
white|WHITE)
export COLOR=$WHITE
esac
local COLOR1="\[$NOBOLD$COLOR\]"
local COLOR2="\[$BOLD$COLOR\]"
local COLOR3="\[$BOLD$BLACK\]"
local COLOR4="\[$GREY\]"
local GRAD1="\$(cut -f4 -d\
local GRAD2="\$(echo \`users | wc --words\`)"
local GRAD3="\$(cut -f1 -d\
local TTY="\$(tty|cut -d/ -f3)"
local TIME="\t"
local DATE="\d"
local PDP="$COLOR2)$COLOR1$DASH$COLOR2("
### PVL wil draw extra stuff from
local PVL="$PDP$COLOR1$GRAD1$COLOR3/$COLOR1$GRAD2$COLOR
PS1="\n$COLOR3$OPENRIGHT$COLOR1$DASH$COLOR2($COLO
PS2="$COLOR2$DASH$COLOR1$DASH$COLOR3$DASH$COLOR4 "
Common sense is not so common.