shopt -s cdspell shopt -s checkwinsize shopt -s cmdhist shopt -s dotglob shopt -s expand_aliases shopt -s extglob shopt -s histappend shopt -s hostcomplete # shopt -s nocaseglob # never! lost a file cause of this shit export HISTFILE=$XDG_CACHE_HOME/bash_history export HISTSIZE=10000 export HISTFILESIZE=${HISTSIZE} export HISTCONTROL=ignoreboth # ex - archive extractor # usage: ex ex () { if [ -f $1 ] ; then case $1 in *.tar.bz2) tar xjf $1 ;; *.tar.gz) tar xzf $1 ;; *.tar.xz) tar -x --xz -f $1 ;; *.bz2) bunzip2 $1 ;; *.rar) unrar x $1 ;; *.gz) gunzip $1 ;; *.tar) tar xf $1 ;; *.tbz2) tar xjf $1 ;; *.tgz) tar xzf $1 ;; *.zip) unzip $1 ;; *.Z) uncompress $1 ;; *.7z) 7z x $1 ;; *) echo "'$1' cannot be extracted via ex()" ;; esac else echo "'$1' is not a valid file" fi } # vim stuff export EDITOR=vim export VISUAL=vim # default prompt PS1='[\u@\h \W]\$ ' # Stuff from ubuntu # make less more friendly for non-text input files, see lesspipe(1) [ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)" # Alias definitions. [[ -f ~/.aliases ]] && . ~/.aliases # set PATH so it includes user's private bin if it exists [[ -d "$HOME/bin" ]] && PATH="$HOME/bin:$PATH"