Created
February 26, 2014 15:56
-
-
Save bougui505/9232302 to your computer and use it in GitHub Desktop.
.zshrc for ishikawa
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ishikawa | |
# Path to your oh-my-zsh configuration. | |
ZSH=$HOME/.oh-my-zsh | |
module () | |
{ | |
eval `/usr/bin/modulecmd bash $*` | |
} | |
module load git/1.7.6 | |
module load ruby/1.9.3-p125 | |
# Set name of the theme to load. | |
# Look in ~/.oh-my-zsh/themes/ | |
# Optionally, if you set this to "random", it'll load a random theme each | |
# time that oh-my-zsh is loaded. | |
ZSH_THEME="kphoen" | |
eval $(dircolors ~/.dircolors) # dircolors -p > ~/.dircolors | |
# Example aliases | |
# alias zshconfig="mate ~/.zshrc" | |
# alias ohmyzsh="mate ~/.oh-my-zsh" | |
# Set to this to use case-sensitive completion | |
# CASE_SENSITIVE="true" | |
# Comment this out to disable weekly auto-update checks | |
# DISABLE_AUTO_UPDATE="true" | |
# Uncomment following line if you want to disable colors in ls | |
# DISABLE_LS_COLORS="true" | |
# Uncomment following line if you want to disable autosetting terminal title. | |
# DISABLE_AUTO_TITLE="true" | |
# Uncomment following line if you want red dots to be displayed while waiting for completion | |
COMPLETION_WAITING_DOTS="true" | |
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) | |
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ | |
# Example format: plugins=(rails git textmate ruby lighthouse) | |
plugins=(git vi-mode trash bgjobsPrompt per-directory-history history-substring-search dateprompt colorize) | |
source $ZSH/oh-my-zsh.sh | |
# Customize to your needs... | |
#export PATH=/c5/shared/git/1.7.6/bin:/Bis/home/bougui/.autojump/bin:/c5/SGE/bin/lx26-amd64:/c5/SGE/bin/lx26-amd64:/Bis/home/bougui/.autojump/bin:/c5/shared/Python/2.7.3-shared/bin:/c5/SGE/bin/lx26-amd64:/c5/shared/zsh/4.3.17/bin:/usr/lib64/qt-3.3/bin:/usr/kerberos/bin:/c5/SGE/bin/lx26-amd64:/c5/shared/vmd/vmd-1.9.1:/c5/shared/xournal/0.4.5//bin:/c5/shared/seamonkey/2.13.1/:/c5/shared/R/2.15.1/bin:/c5/shared/povray/3.6.1/bin/:/c5/shared/openbabel/2.3.1/bin:/c5/shared/ncbi_tools/20090809/ncbi/bin:/c5/shared/Wolfram/Mathematica/7.0/Executables:/c5/shared/matlab/7.15/bin/:/usr/lib/jvm/jre-sun/bin:/c5/shared/JabRef/2.5:/c5/shared/modeller/9v8/bin/:/c5/shared/icm/3.7-2a:/c5/shared/apbs/1.2.1/bin/:/usr/share/pvm3/bin/LINUX64:/usr/share/pvm3/lib/LINUX64:/usr/share/pvm3/lib:/c5/shared/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/NX/bin:/Bis/home/bougui/bin:/usr/NX/bin:/Bis/home/bougui/bin:/usr/NX/bin:/usr/NX/bin:/Bis/home/bougui/bin | |
# typing the beginning of a previous command then | |
# PgUp/PgDw cycles trough history only for matching entries | |
bindkey "\e[5~" history-search-backward # Previous | |
bindkey "\e[6~" history-search-forward # Next | |
bindkey "^[[1~" beginning-of-line | |
bindkey "^[[4~" end-of-line | |
autoload -z history-beginning-search-menu; zle -N history-beginning-search-menu-space-end history-beginning-search-menu | |
bindkey "^h" history-beginning-search-menu-space-end | |
#autoload -U promptinit; promptinit; prompt bart | |
autoload -U compinit; compinit | |
autoload -U edit-command-line | |
zle -N edit-command-line | |
bindkey '^e' edit-command-line | |
zstyle ':completion:*:default' list-colors ${(s.:.)LS_COLORS} | |
zstyle ':completion:*' menu select | |
#################### From: http://unix.stackexchange.com/questions/5229/add-arguments-from-previous-command-to-zsh-completion | |
# adds the arguments from the last commadn to the autocomplete list | |
# I wasn't able to get this to work standalone and still print out both regular | |
# completion plus the last args, but this works well enough. | |
_complete_plus_last_command_args() { | |
last_command=$history[$[HISTCMD-1]] | |
last_command_array=("${(s/ /)last_command}") | |
_sep_parts last_command_array | |
_complete | |
} | |
_force_rehash() { | |
(( CURRENT == 1 )) && rehash | |
return 1 # Because we didn't really complete anything | |
} | |
zstyle ':completion:::::' completer _force_rehash _complete_plus_last_command_args _approximate | |
#################### From: http://unix.stackexchange.com/questions/5229/add-arguments-from-previous-command-to-zsh-completion | |
zmodload zsh/mathfunc | |
setopt BANG_HIST | |
setopt APPEND_HISTORY | |
setopt EXTENDED_HISTORY | |
setopt INC_APPEND_HISTORY | |
setopt SHARE_HISTORY | |
setopt HIST_IGNORE_ALL_DUPS | |
setopt HIST_REDUCE_BLANKS | |
setopt HIST_FCNTL_LOCK | |
setopt HIST_IGNORE_SPACE | |
HISTFILE=~/.zsh_history | |
HISTSIZE=100000 | |
SAVEHIST=100000 | |
REPORTTIME=1 # print elapsed time when more than 1 seconds | |
EDITOR=vim | |
module load python/2.7.4-shared | |
# Correction des commandes | |
setopt correctall | |
alias ls='ls --color=auto' | |
alias grep='grep --color=auto' | |
alias fgrep='fgrep --color=auto' | |
alias egrep='egrep --color=auto' | |
alias ll='ls -lh' | |
alias lt='ls -thor' | |
alias tmux='tmux -2' | |
alias mail='mail -c guillaume.bouvier@pasteur.fr' | |
rm () {trash put $*} | |
alias clean='trash cempty' | |
alias lst='trash clist' | |
alias rmf='/bin/rm' | |
alias go='gnome-open' | |
alias mv='mv -i' | |
alias cp='cp -i' | |
alias ruler='echo 12345678901234567890123456789012345678901234567890123456789012345678901234567890;echo " 1 2 3 4 5 6 7 8";' | |
alias h='per-directory-history-toggle-history' | |
#alias ipython='ipython --pylab --pprint' | |
alias ssh-x='ssh -c arcfour,blowfish-cbc -XC' | |
alias t='date +%Y%m%d' | |
alias cdt='j $(t)' | |
alias updatedb_home='updatedb --output ~/mlocate.db --database-root /Bis/home/bougui --add-prunepaths ~/.zfs -l 0 --verbose' | |
alias locate_home='locate -d ~/mlocate.db' | |
alias updatedb_Scratch='updatedb --output /Bis/Scratch/bougui/mlocate.db --database-root /Bis/Scratch/bougui --add-prunepaths ~/.zfs -l 0 --verbose' | |
alias locate_Scratch='locate -d /Bis/Scratch/bougui/mlocate.db' | |
alias x='xargs -x -L1 -Ix' | |
alias bc='bc -l' | |
alias isearch='rash isearch' | |
lastf () {ls -rt $* | tail -n1} | |
alias -s pdf='evince ' | |
alias -s tex='vim' | |
alias -s png='eog' | |
alias -s svg='inkscape' | |
imv() { | |
local src dst | |
for src; do | |
[[ -e $src ]] || { print -u2 "$src does not exist"; continue } | |
dst=$src | |
vared dst | |
[[ $src != $dst ]] && mkdir -p $dst:h && mv $src $dst | |
done | |
} | |
cless() { | |
colorize $1 | less | |
} | |
source ~/.autojump/etc/profile.d/autojump.zsh | |
source ~/bin/ZSH_syntax_highlighting/zsh-users-zsh-syntax-highlighting-732b7d6/zsh-syntax-highlighting.zsh | |
#source ~/bin/ZSH-history-substring-search/zsh-users-zsh-history-substring-search-04c2eca/zsh-history-substring-search.zsh | |
PATH=$PATH:$HOME/bin | |
PYTHONPATH=$PYTHONPATH:/Bis/home/bougui/lib/python2.7/site-packages | |
export SOM=~/bin/SOM | |
export KEYTIMEOUT=1 # Kill The Lag for vi-mode from: http://dougblack.io/words/zsh-vi-mode.html | |
eval "$(rash init)" | |
#rash index --check-duplicate | |
#start tmux | |
#if [ $TERM != "screen-256color" ] && [ $TERM != "screen" ]; then | |
# tmux attach || tmux new; exit | |
#fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment