# ~/.bashrc: executed by bash(1) for non-login shells. # see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) # for examples # If not running interactively, don't do anything [ -z "$PS1" ] && return # don't put duplicate lines in the history. See bash(1) for more options export HISTCONTROL=ignoredups # check the window size after each command and, if necessary, # update the values of LINES and COLUMNS. shopt -s checkwinsize # make less more friendly for non-text input files, see lesspipe(1) [ -x /usr/bin/lesspipe ] && eval "$(lesspipe)" # set variable identifying the chroot you work in (used in the prompt below) if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then debian_chroot=$(cat /etc/debian_chroot) fi # set a fancy prompt (non-color, unless we know we "want" color) case "$TERM" in xterm-color) PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' ;; *) PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' ;; esac # Comment in the above and uncomment this below for a color prompt #PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' # If this is an xterm set the title to user@host:dir case "$TERM" in xterm*|rxvt*) PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD/$HOME/~}\007"' ;; *) ;; esac # Alias definitions. # You may want to put all your additions into a separate file like # ~/.bash_aliases, instead of adding them here directly. # See /usr/share/doc/bash-doc/examples in the bash-doc package. #if [ -f ~/.bash_aliases ]; then # . ~/.bash_aliases #fi # enable color support of ls and also add handy aliases if [ "$TERM" != "dumb" ]; then eval "`dircolors -b`" alias ls='ls --color=auto' #alias dir='ls --color=auto --format=vertical' #alias vdir='ls --color=auto --format=long' fi # some more ls aliases #alias ll='ls -l' #alias la='ls -A' #alias l='ls -CF' # enable programmable completion features (you don't need to enable # this, if it's already enabled in /etc/bash.bashrc and /etc/profile # sources /etc/bash.bashrc). if [ -f /etc/bash_completion ]; then . /etc/bash_completion fi # COULEURS PROMPT red='\e[0;31m' RED='\e[1;31m' blue='\e[0;34m' BLUE='\e[1;34m' cyan='\e[0;36m' CYAN='\e[1;36m' NC='\e[0m' # No Color COLOR2='\[\033[00;37m\]' COLOR9='\[\033[00;100m\]' COLOR10='\[\033[00;94m\]' COLOR8='\[\033[00;37m\]' PS1=\[$COLOR2'\u'$COLOR10'@'$COLOR2'\h'$COLOR8' '$COLOR9'\W'$COLOR8\]' ' #-------------------------------------------------------------------- alias gmplayer="mplayer" alias g="gqview ./" alias e="emacs" alias emacs="emacs -bg gray20 -fg gray75 --geometry 100x70 -fn 8x13" alias ls="ls --color" alias ll="ls -oh" alias l="ls -oh" alias m="make -j 4" alias k="konqueror" alias cal="cal -3 -m" alias grep="grep -i --color=always -n" alias ps="ps -ux" alias lpr="rlpr --printer=lp4200 -Hlp4200.run.montefiore.ulg.ac.be -q -h " alias meeerde='echo "Allons, allons ca va s arranger"' alias mplayer="mplayer -cache 8192 -ao alsa -vo xv" # remettre xv + ~/.mplayer/config alias log='/usr/bin/tail -f /var/log/*.log' alias ssh="ssh -X" alias du="du -h --max-depth=1" alias df="df -h" alias apt="sudo nice -n +19 apt-get " alias synaptic="sudo synaptic " alias gv="gv --watch" alias x="exit" alias lyx="lyx-qt" alias d="display -quiet" alias reboot='sudo reboot' alias shutdown='sudo shutdown' alias poweroff='sudo poweroff' alias swapoff="sudo swapoff -a" alias swapon="sudo swapon -a" alias gros="du -ak | sort -nr |less" #-------------------------------------------------------------------- alias la='ls -Al' # show hidden files alias lx='ls -lXB' # sort by extension alias lk='ls -lSr' # sort by size alias lc='ls -lcr' # sort by change time alias lu='ls -lur' # sort by access time alias lr='ls -lR' # recursive ls alias lt='ls -ltr' # sort by date alias lm='ls -l |more' # pipe through 'more' alias tree='tree -Csu' # nice alternative to 'ls' # Erreurs -------------------------------------------- alias moer='more' alias mkae='make' alias xeit='exit' alias xit='exit' alias eit='exit' alias amke='make' alias xs='cd' alias vf='cd' alias meacs='emacs' alias mapleyr='mplayer' alias maplery='mplayer' alias mokayer='mplayer' alias CD='cd' alias MAKE='make' alias LS='ls' alias EMACS='emacs' alias EXIT='exit' alias GQVIEW='gqview' alias DU='du' alias DF='df' alias MPLAYER='mplayer' alias GREP='grep' alias PS='ps' alias SSH='ssh' # ssh -------------------------------------------- alias cinema="echo ; ssh cinema.montefiore.ulg.ac.be" alias anechoique="echo ; ssh 139.165.12.76" alias com05="echo ; ssh com05.montefiore.ulg.ac.be" alias com03="echo ; ssh com03.montefiore.ulg.ac.be" alias com02="echo ; ssh com02.montefiore.ulg.ac.be" alias netcam1="echo ; ssh netcam1.montefiore.ulg.ac.be" alias gaston="echo ; ssh dardenne@gaston.montefiore.ulg.ac.be" # -------------------------------------------- alias src="source ~/.bashrc" alias xosview='xosview -load -net -ints -page -disk -font 9x15 -captions -xrm "xosview*cpuFreeColor: gray69" -xrm "xosview*memFreeColor: gray69" -xrm "xosview*swapFreeColor: gray69" -geometry 400x200 -xrm "xosview*background: gray99" -xrm "xosview*foreground: gray29" -xrm "xosview*usedLabelColor:gray29"' # Viewer/Editeur par défaut -------------------------------------------- export VISUAL=emacs export EDITOR=emacs # -------------------------------------------- export LS_COLORS="di=97" export LS_COLORS="no=00:fi=00:di=01;34:ln=01;36:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.gz=01;31:*.bz2=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.mpg=01;35:*.mpeg=01;35:*.avi=01;35:*.fli=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.ogg=01;35:*.mp3=01;35:*.wav=01;35:*.c=01;35:" # Pour les langues -------------------------------------------- #export LANG=fr.ISO-8859-15@euro #export LC_ALL=fr_BE # OPTIONS BASH -------------------------------------------- export HISTIGNORE="&:bg:fg:ll:h" export HOSTFILE=$HOME/.hosts # Put a list of remote hosts in ~/.hosts shopt -s cdspell # corrige les petites erreurs shopt -s hostcomplete # completion apres le '@' shopt -s histappend # appends history entries rather than overwriting them. shopt -s cmdhist # multi-line commands appended to history as single-line shopt -s nocaseglob # ??? shopt -s extglob # necessary bind 'set show-all-if-ambiguous on' # Tab once for complete bind 'set completion-ignore-case on' # performs filename matching and completion in a case-insensitive fashion set +o nounset # otherwise some completions will fail xset b off alias update=' apt update ; apt dist-upgrade'