Index of /zsh

      Name                    Last modified       Size  Description

[DIR] Parent Directory 09-Jun-2008 14:03 - [CMP] zshrc-v0.130.gz 12-Jun-2008 12:00 10k zshrc [TXT] zshrc-v0.130.asc 12-Jun-2008 12:00 1k gpg signature [TXT] screenrc 31-Mar-2008 20:13 1k ~/.screenrc [TXT] screenrc.asc 31-Mar-2008 20:13 1k gpg signature [CMP] bat-mon-v0.103.gz 14-Dec-2007 00:34 1k battery monitor [TXT] bat-mon-v0.103.asc 14-Dec-2007 00:34 1k gpg signature [IMG] zsh-prompt-TZ.png 14-Dec-2007 00:32 10k time zones [IMG] zsh-prompt-root.png 16-Nov-2007 00:37 8k root prompt [IMG] zsh-prompt-load.png 15-Nov-2007 03:12 25k load average screenshot [IMG] zsh-prompt-cd-color.png 01-Nov-2007 22:48 3k change PWD color [IMG] zsh-prompt-exit.png 24-Oct-2007 11:49 5k exit status screenshot [IMG] zsh-prompt-battery.png 24-Oct-2007 11:49 4k battery status

zsh-prompt-TZ.png : displaying time zones using the name of the city. as 
of v0.118 it will default to UTC if a nonsensical TZ is used, such as 
TZ=foo/bar.

zsh-prompt-battery.png : shows the color-coding of the battery status. 
if the computer is running on battery power the display shows the 
estimated time and percentage of charge remaining.

zsh-prompt-load.png : shows the color coding of the load averages. note 
that this system is only AC powered, so there's no battery status. also 
this system has 2 CPUs, so a load <2 is green; >4 is red; between 2-4 is 
yellow. the zshrc file counts CPUs when it is started and uses this to 
colorize the load averages.

zsh-prompt-exit.png : shows the exit status "1" after trying to `cat` a 
non-existent file. the first invocation of `sleep 300` is killed with 
"^C" and it shows that it was killed with an INT (interrupt) signal. the 
second invocation is killed (from another shell) with a TERM signal. the 
third invocation is killed (from another shell) with a KILL (-9) signal. 
you get the idea: if the previous command died an unnatural death, 
display the signal that killed it. in any case, display the return 
status if it's not zero.

zsh-prompt-cd-color.png : when changing directories show the $PWD in a 
brighter color. this supports 256 colors, if available. there are a few 
easter-eggs built into this...

zsh-prompt-root.png : using the same zshrc file, i like to have the root 
prompt obviously different, but not obtrusively so.

there's a lot going on in here and most of it doesn't even make good 
screenshots. the files should have enough comments to follow along.

note that the bat-mon script is zsh-centric and FreeBSD-centric. if you 
want this functionality on another OS, feel free to use the script as a 
guide. nothing will break if you don't use bat-mon.

this works best with zsh 4.3.4. older versions that i've tested on 
mostly work; on older versions of zsh some things may not work, some 
things may even break.

if you spot a bug please let me know.

enjoy!