Skip to content

Instantly share code, notes, and snippets.

@atondwal
Created November 4, 2013 17:51
Show Gist options
  • Save atondwal/7306531 to your computer and use it in GitHub Desktop.
Save atondwal/7306531 to your computer and use it in GitHub Desktop.
if [[ "$TERM" != emacs ]]; then
[[ -z "$terminfo[kdch1]" ]] || bindkey -M emacs "$terminfo[kdch1]" delete-char
[[ -z "$terminfo[khome]" ]] || bindkey -M emacs "$terminfo[khome]" beginning-of-line
[[ -z "$terminfo[kend]" ]] || bindkey -M emacs "$terminfo[kend]" end-of-line
[[ -z "$terminfo[kich1]" ]] || bindkey -M emacs "$terminfo[kich1]" overwrite-mode
[[ -z "$terminfo[kdch1]" ]] || bindkey -M vicmd "$terminfo[kdch1]" vi-delete-char
[[ -z "$terminfo[khome]" ]] || bindkey -M vicmd "$terminfo[khome]" vi-beginning-of-line
[[ -z "$terminfo[kend]" ]] || bindkey -M vicmd "$terminfo[kend]" vi-end-of-line
[[ -z "$terminfo[kich1]" ]] || bindkey -M vicmd "$terminfo[kich1]" overwrite-mode
[[ -z "$terminfo[cuu1]" ]] || bindkey -M viins "$terminfo[cuu1]" vi-up-line-or-history
[[ -z "$terminfo[cuf1]" ]] || bindkey -M viins "$terminfo[cuf1]" vi-forward-char
[[ -z "$terminfo[kcuu1]" ]] || bindkey -M viins "$terminfo[kcuu1]" vi-up-line-or-history
[[ -z "$terminfo[kcud1]" ]] || bindkey -M viins "$terminfo[kcud1]" vi-down-line-or-history
[[ -z "$terminfo[kcuf1]" ]] || bindkey -M viins "$terminfo[kcuf1]" vi-forward-char
[[ -z "$terminfo[kcub1]" ]] || bindkey -M viins "$terminfo[kcub1]" vi-backward-char
[[ -z "$terminfo[khome]" ]] || bindkey -M viins "$terminfo[khome]" vi-beginning-of-line
[[ -z "$terminfo[kend]" ]] || bindkey -M viins "$terminfo[kend]" vi-end-of-line
# ncurses fogyatekos
[[ "$terminfo[kcuu1]" == "^[O"* ]] && bindkey -M viins "${terminfo[kcuu1]/O/[}" vi-up-line-or-history
[[ "$terminfo[kcud1]" == "^[O"* ]] && bindkey -M viins "${terminfo[kcud1]/O/[}" vi-down-line-or-history
[[ "$terminfo[kcuf1]" == "^[O"* ]] && bindkey -M viins "${terminfo[kcuf1]/O/[}" vi-forward-char
[[ "$terminfo[kcub1]" == "^[O"* ]] && bindkey -M viins "${terminfo[kcub1]/O/[}" vi-backward-char
[[ "$terminfo[khome]" == "^[O"* ]] && bindkey -M viins "${terminfo[khome]/O/[}" beginning-of-line
[[ "$terminfo[kend]" == "^[O"* ]] && bindkey -M viins "${terminfo[kend]/O/[}" end-of-line
[[ "$terminfo[khome]" == "^[O"* ]] && bindkey -M emacs "${terminfo[khome]/O/[}" beginning-of-line
[[ "$terminfo[kend]" == "^[O"* ]] && bindkey -M emacs "${terminfo[kend]/O/[}" end-of-line
fi
bindkey "^?" backward-delete-char
bindkey '^r' history-incremental-search-backward
# Path to your oh-my-zsh configuration.
export ZSH=$HOME/.oh-my-zsh
# Set to the name theme to load.
# Look in ~/.oh-my-zsh/themes/
export ZSH_THEME="powerline"
export POWERLINE_RIGHT_A="mixed"
export POWERLINE_HIDE_USER_NAME="true"
export POWERLINE_NO_BLANK_LINE="true"
export POWERLINE_DETECT_SSH="true"
# Set to this to use case-sensitive completion
export CASE_SENSITIVE="true"
# Comment this out to disable weekly auto-update checks
export DISABLE_AUTO_UPDATE="true"
# Uncomment following line if you want to disable colors in ls
# export DISABLE_LS_COLORS="true"
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
# Example format: plugins=(rails git textmate ruby lighthouse)
plugins=(git)
source $ZSH/oh-my-zsh.sh
# Customize to your needs...
export PATH=/home/atondwal/.cabal/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin/core_perl:/home/atondwal/bin:/home/atondwal/Downloads/android-ndk-r8d/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin:/home/atondwal/.gem/ruby/2.0.0/bin
export EDITOR=vim
bindkey -v
stty stop undef
stty start undef
alias math="rlwrap math"
alias pacman=aura
alias -s tex=vim
alias -s c=vim
alias -s pdf=evince
export LESS_TERMCAP_mb=$'\E[01;31m'
export LESS_TERMCAP_md=$'\E[01;31m'
export LESS_TERMCAP_me=$'\E[0m'
export LESS_TERMCAP_se=$'\E[0m'
export LESS_TERMCAP_so=$'\E[01;44;33m'
export LESS_TERMCAP_ue=$'\E[0m'
export LESS_TERMCAP_us=$'\E[01;32m'
clyde() {
case $1 in
(-Ss | -Si | -Q* | -T | -G)
/usr/bin/clyde "$@" ;;
(-S* | -R* | -U | *)
sudo /usr/bin/clyde "$@";;
esac
}
setopt histignorespace
setopt nocorrectall
setopt correct
PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for scripting
export ANDRIOD_NDK=/home/atondwal/Downloads/android-ndk-r8d
alias ndk_setup=" mkdir -p /tmp/ndk-andrewhsieh/build/toolchain/prefix && ln -s $ANDROID_NDK/platforms/android-9/arch-arm /tmp/ndk-andrewhsieh/build/toolchain/prefix/sysroot"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment