export EDITOR=vim
GREEN="$(tput setaf 2)"
RED="$(tput setaf 1)"
REDB="$(tput setab 1)$(tput setaf 0)"
RESET="$(tput sgr0)"

function status {
    S=$?
    if [[ $S = 0 ]]; then
        echo ${GREEN}
    else
        echo ${REDB}
    fi
    return $S
}

PROMPT_COMMAND='history -a'
PS1="\[${RED}\][\u@\h \w]\[\$(status)\](\$?)\$\[${RESET}\] "

alias ls='ls --color=auto'
alias ll='ls -l'
alias s='screen'
