I added a few useful statements from Debian to make these:
Code: Select all
# /etc/bashrc
#
#####################################################################
#
# Basic bash startup files explanation:
#
# /etc/profile ==> System-wide initialization file containing
# global/system environment variables and
# startup programs
#
# /etc/bashrc ==> System-wide aliases and functions, and some
# modifications to /etc/profile (to help
# maintain /etc/profile as original as possible)
#
# ~/.bash_profile ==> Local/Personal environment variables and
# startup programs called only during login
#
# ~/.bashrc ==> Anything local/personal and peculiar to the
# user
#
# Login command programmatically sources /etc/profile and then ONLY
# ~/.bash_profile OR ~/.bash_login OR ~/.profile, in that search
# order
#
# Logout command programmatically sources ~/.bash_logout
#
# Non-login consoles such as xterm/konsole programmatically sources
# ~/.bashrc
#
# /etc/bashrc is not sourced programmatically and must be sourced
# manually
#
# Local setup:
#
# ~/.bash_profile sources ~./bashrc and executes bash_login
# ~/.bashrc sources /etc/bashrc
# ~/.bash_logout executes bash_logout
#
#####################################################################
PS1='[\u@\h \W]\$ '
. /etc/profile.d/bash_completion.sh
. /etc/profile.d/coreutils-dircolors.sh
# Needed to get "man" to work properly in Unicode locales:
alias man='LC_ALL=C man'
# Some more alias to avoid making mistakes:
alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'
# Evaluate terminal size and dynamically resize screen
shopt -s checkwinsize
# Don't put duplicate lines in the history:
export HISTCONTROL=ignoredups
# Colorized grep output and man pages:
export PAGER='most'
export GREP_OPTIONS='--color=auto'
export GREP_COLOR='1;31'
# Set Vi IMproved as the default editor:
export EDITOR='vim'
Code: Select all
# ~/.bashrc
#
# see /etc/bashrc for a complete description how all bash source files
# are related and used on this box
# Source system-wide aliases and functions
if [ -f /etc/bashrc ]; then
source /etc/bashrc
fi
# --- Local/Personal environment variables ---
# define bash prompts, non-X text editors, etc.
unset MAILCHECK
# --- Local aliases ---
# --- Local functions ---
Code: Select all
# ~/.bash_login
#
# see /etc/bashrc for a complete description how all bash source files
# are related and used on this box
# Source Local/Personal aliases and functions
if [ -f $HOME/.bashrc ]; then
source $HOME/.bashrc
fi
# Source /usr/local/bin/bash_login
if [ -x /usr/local/bin/bash_login ]; then
/usr/local/bin/bash_login
fi
# --- Local/Personal startup programs ---
Code: Select all
# ~/.bash_logout
#
# see /etc/bashrc for a complete description how all bash source files
# are related and used on this box
# Source /usr/local/bin/bash_logout
if [ -x /usr/local/bin/bash_logout ]; then
/usr/local/bin/bash_logout
fi
clear