#########################################################################
# This file is sourced by all *interactive* bash shells on startup,
# including some apparently interactive shells such as scp and rcp
# that can't tolerate any output.  So make sure this doesn't display
# anything or bad things will happen !
#########################################################################
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Test for an interactive shell.  There is no need to set anything
# past this point for scp and rcp, and it's important to refrain from
# outputting anything in those cases.
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
if [[ $- != *i* ]] ; then
	# Shell is non-interactive.  Be done now!
	return
fi
# - - - - - - - - - - - - - - - - -
# source other necessary stuff
# - - - - - - - - - - - - - - - - -
if [ -f /etc/bashrc ]; then source /etc/bashrc; fi # fedora
if [ -f /etc/bash/bashrc ]; then source /etc/bash/bashrc; fi # gentoo
if [ -f /etc/bash.bashrc ]; then source /etc/bash.bashrc; fi # ubuntu
if [ -d ~/.bash_completion.d ]; then source ~/.bash_completion.d/*; fi # bash completion ftw
if [ -f ~/.bash/colors ]; then source ~/.bash/colors; fi
if [ -f ~/.bash/functions ]; then source ~/.bash/functions; fi
if [ -f ~/.bash/aliases ]; then . ~/.bash/aliases; fi
if [ -f ~/.bash/`hostname` ]; then source ~/.bash/`hostname`; fi
if [ -f ~/.bash/prompt ]; then source ~/.bash/prompt; fi
if [ -f ~/.bash/env ]; then source ~/.bash/env; fi
# Midnight Commander chdir enhancement
if [ -f /usr/share/mc/mc.gentoo ]; then . /usr/share/mc/mc.gentoo; fi
# - - - - - - - - - - - - - - - - -
# Enable colors for ls, etc.
# Prefer ~/.dir_colors #64489
# - - - - - - - - - - - - - - - - -
if [ -f ~/.dir_colors ]; then
	eval `dircolors -b ~/.dir_colors`
elif [ -f /etc/DIR_COLORS ]; then
	eval `dircolors -b /etc/DIR_COLORS`
else
	eval `dircolors -b`
fi
# - - - - - - - - - - - - - - - - - - -
# don't duplicate lines in history
# - - - - - - - - - - - - - - - - - - -
export HISTCONTROL=ignoredups

set noclobber
# - - - - - - - - - - - - - - -
# http://caliban.org/bash/
# - - - - - - - - - - - - - - -
shopt -s checkwinsize
shopt -s cdspell
shopt -s extglob
