.bashrc -> .bashrc.vahagn
This commit is contained in:
103
config/.bashrc.vahagn
Executable file
103
config/.bashrc.vahagn
Executable file
@@ -0,0 +1,103 @@
|
||||
#!/bin/bash
|
||||
|
||||
# ~/.bashrc skeleton
|
||||
# ~/.bashrc runs ONLY on non-login subshells! (different from ksh)
|
||||
# add lines here very carefully as this may execute when you don't i
|
||||
# expect them to
|
||||
# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|
||||
#echo "BASHRC has run"
|
||||
|
||||
# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|
||||
#
|
||||
# Source global definitions
|
||||
#
|
||||
if [ -f /etc/bashrc ]; then
|
||||
. /etc/bashrc
|
||||
else
|
||||
if ! shopt -q login_shell ; then # We're not a login shell
|
||||
for i in /etc/profile.d/*.sh; do
|
||||
if [ -r "$i" ]; then
|
||||
if [ "$PS1" ]; then
|
||||
. $i
|
||||
else
|
||||
. $i &>/dev/null
|
||||
fi
|
||||
fi
|
||||
done
|
||||
unset i
|
||||
fi
|
||||
fi
|
||||
|
||||
umask 002
|
||||
|
||||
# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|
||||
#
|
||||
# Find out system details.
|
||||
#
|
||||
os=`uname` #GNU/Linux AIX Solaris
|
||||
cpu=`uname -p` #x86_64 powerpc sparc
|
||||
kernel=`uname -s` #Linux AIX SunOS
|
||||
kversion=`uname -v`
|
||||
krelease=`uname -r`
|
||||
hostnm=`hostname`
|
||||
|
||||
# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|
||||
#
|
||||
# Bash history
|
||||
#
|
||||
|
||||
# don't put duplicate lines or lines starting with space in the history.
|
||||
# See bash(1) for more options
|
||||
HISTCONTROL=ignoreboth
|
||||
# append to the history file, don't overwrite it
|
||||
shopt -s histappend
|
||||
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
|
||||
HISTSIZE=1000
|
||||
HISTFILESIZE=5000
|
||||
# check the window size after each command and, if necessary,
|
||||
# update the values of LINES and COLUMNS.
|
||||
shopt -s checkwinsize
|
||||
|
||||
# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|
||||
#
|
||||
# User specific environment and startup programs
|
||||
#
|
||||
|
||||
if [ -e $HOME/bin ]; then
|
||||
export PATH=$HOME/bin:$PATH
|
||||
fi
|
||||
export MYSCRIPTS=$HOME/devel/scripts
|
||||
if [ -e $MYSCRIPTS/bin ]; then
|
||||
export PATH=$MYSCRIPTS/bin:$PATH
|
||||
fi
|
||||
export MYCFG=${MYSCRIPTS}/config
|
||||
|
||||
#
|
||||
# VIM
|
||||
#
|
||||
export EDITOR=vim
|
||||
export LESS=-R
|
||||
|
||||
# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|
||||
# Set command prompt
|
||||
[ -x ${HOME}/.profile.prompt ] && source ${HOME}/.profile.prompt
|
||||
[ -x ${HOME}/.profile.dircolor ] && source ${HOME}/.profile.dircolor
|
||||
[ -x ${HOME}/.profile.completion ] && source ${HOME}/.profile.completion
|
||||
[ -x ${HOME}/.profile.dev ] && source ${HOME}/.profile.dev
|
||||
[ -x ${HOME}/.profile.aliases ] && source ${HOME}/.profile.aliases
|
||||
|
||||
# Haskell
|
||||
if [ -f $HOME/.ghcup/env ]; then
|
||||
export PATH=$HOME/.ghcup/env:$PATH
|
||||
fi
|
||||
|
||||
# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|
||||
#
|
||||
# Run local settings.
|
||||
#
|
||||
[ -x ${HOME}/.bashrc.local ] && . ${HOME}/.bashrc.local
|
||||
|
||||
#
|
||||
# Clean error level.
|
||||
#
|
||||
[ 1 ]
|
||||
Reference in New Issue
Block a user