Mercurial > index.cgi > dotfiles
changeset 16:b9896ae0733c
Stole pretty PS1 and xterm title changing from BackTrack 4. Also added a
switch to the dotfile check so we can create a list of hosts for which we
don't want to check against the server, just warn.
author | huston@80426f53-59d1-405d-934b-f07cd76f4a1a |
---|---|
date | Sat, 05 Sep 2009 20:18:20 +0000 |
parents | fe83d9892ee3 |
children | 90ad040b032c |
files | .bash_profile .bashrc |
diffstat | 2 files changed, 22 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/.bash_profile Sun Aug 30 20:37:09 2009 +0000 +++ b/.bash_profile Sat Sep 05 20:18:20 2009 +0000 @@ -55,8 +55,18 @@ [[ ! -f $HOME/.dotfilets || \ `eval $DFSTAT` -lt `eval $MDATE` ]] && { - echo Dotfiles last checked over a month ago, running a status test. - svn st -u && touch $HOME/.dotfilets & + echo -n Dotfiles last checked over a month ago + + # Here we switch for hosts we don't want to check, just warn + case `hostname -s` in + bt) + echo + touch $HOME/.dotfilets + ;; + *) + echo , running a status test. + svn st -u && touch $HOME/.dotfilets & + esac } # Work in progress - toodledo to ~/.todo
--- a/.bashrc Sun Aug 30 20:37:09 2009 +0000 +++ b/.bashrc Sat Sep 05 20:18:20 2009 +0000 @@ -18,12 +18,21 @@ # # Environment variables # -[[ "$PS1" ]] && export PS1='\h:\w\$ ' +[[ "$PS1" ]] && export PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' export PAGER=less export EDITOR=vim export RUBYLIB=$HOME/Installs/rubygems/lib export GEM_HOME=$HOME/Installs/rubygems/gems +# If this is an xterm set the title to user@host:dir +case "$TERM" in +xterm*|rxvt*) + PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD/$HOME/~}\007"' + ;; +*) + ;; +esac + # # Paths #