meillo@3: # markus schnalke -- http://marmaro.de meillo@3: # meillo@3: # modified standard bashrc of debian sarge meillo@3: # meillo@3: meillo@9: export LANG=en_US.UTF-8 meillo@3: meillo@1: # ~/.bashrc: executed by bash(1) for non-login shells. meillo@1: # see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) meillo@1: # for examples meillo@1: meillo@1: # If not running interactively, don't do anything: meillo@1: [ -z "$PS1" ] && return meillo@1: meillo@5: meillo@1: # check the window size after each command and, if necessary, meillo@1: # update the values of LINES and COLUMNS. meillo@1: shopt -s checkwinsize meillo@1: meillo@5: meillo@1: # enable colored ls output meillo@1: eval "`dircolors -b $HOME/.dircolorsrc`" meillo@1: meillo@5: meillo@4: # one history for all meillo@4: shopt -s histappend meillo@4: PROMPT_COMMAND='history -a' meillo@5: export HISTCONTROL=ignoredups meillo@5: # larger history meillo@5: export HISTSIZE=100000 meillo@5: export HISTFILESIZE=$HISTSIZE meillo@4: meillo@5: meillo@5: # enable programmable completion features (you don't need to enable meillo@5: # this, if it's already enabled in /etc/bash.bashrc and /etc/profiles meillo@5: # sources /etc/bash.bashrc). meillo@5: if [ -f /etc/bash_completion ]; then meillo@5: . /etc/bash_completion meillo@5: fi meillo@5: meillo@1: meillo@1: # vars meillo@1: meillo@1: export PATH=$PATH:/home/meillo/Prog/Shell/bin meillo@1: meillo@1: export VISUAL=vim meillo@1: export EDITOR=vim meillo@1: meillo@1: export DEBEMAIL=meillo@marmaro.de meillo@1: export DEBFULLNAME="markus schnalke" meillo@1: meillo@1: meillo@1: meillo@5: # functions meillo@5: meillo@5: function ls { meillo@5: command ls -F --color=auto "$@" meillo@5: } meillo@5: function ll { meillo@5: ls -l "$@" meillo@5: } meillo@5: function lh { meillo@5: ls -lh "$@" meillo@5: } meillo@5: function la { meillo@5: ls -A "$@" meillo@5: } meillo@12: function lt { meillo@12: ls -lhtr "$@" meillo@12: } meillo@5: meillo@5: function dh { meillo@5: df -h "$@" meillo@5: } meillo@5: meillo@5: function cal { meillo@5: command cal -m "$@" meillo@5: } meillo@5: function xpdf { meillo@5: command xpdf -z page "$@" & meillo@5: } meillo@5: meillo@10: function dusch { meillo@10: du -sch * meillo@10: } meillo@5: function du1 { meillo@10: if [ "$*" = "" ] ; then meillo@10: du -h --max-depth=1 --exclude=".?*" "`pwd`" meillo@10: else meillo@10: du -h --max-depth=1 --exclude=".?*" "$@" meillo@10: fi meillo@5: } meillo@5: function du2 { meillo@10: if [ "$*" = "" ] ; then meillo@10: du -h --max-depth=2 --exclude=".?*" "`pwd`" meillo@10: else meillo@10: du -h --max-depth=2 --exclude=".?*" "$@" meillo@10: fi meillo@5: } meillo@5: meillo@8: function psgrep { meillo@8: ps -eaf | grep --color=auto -i "$1" meillo@8: } meillo@8: meillo@12: function returncode { meillo@12: returncode=$? meillo@12: if [ $returncode -ne 0 ] ; then meillo@12: echo "$returncode" meillo@12: fi meillo@12: } meillo@12: meillo@5: # aliases meillo@5: meillo@5: #alias fireworks='wine /usr/share/Fireworks4/Fireworks\ 4.exe' meillo@5: #alias stendhal='java -jar /home/meillo/Spiele/Stendhal/stendhal' meillo@5: meillo@12: meillo@12: meillo@12: # If this is an xterm set the title to user@host:dir meillo@12: case "$TERM" in meillo@12: xterm*|rxvt*) meillo@12: PROMPT_COMMAND=$PROMPT_COMMAND' ; echo -ne "\033]0;${HOSTNAME} | ${USER}\007"' meillo@12: ;; meillo@12: *) meillo@12: ;; meillo@12: esac meillo@12: meillo@12: meillo@12: # command prompt meillo@12: PS1='\033[01;31m$(returncode)\033[00m\n\033[01;31m<\033[00m \h \033[01;31m|\033[00m \u \033[01;31m|\033[00m \w \033[01;31m>\033[00m\n \$ '