added history sets. kludge, plz fix
This commit is contained in:
parent
3f5b114ef2
commit
48acb97b90
1 changed files with 30 additions and 2 deletions
32
.zshrc
32
.zshrc
|
@ -1,14 +1,42 @@
|
|||
# Set ZSH_CACHE_DIR to the path where cache files should be created
|
||||
# or else we will use the default cache/
|
||||
if [[ -z "$ZSH_CACHE_DIR" ]]; then
|
||||
ZSH_CACHE_DIR="$ZSH/cache"
|
||||
fi
|
||||
|
||||
export TERM="xterm-256color"
|
||||
#zsh options
|
||||
setopt auto_cd
|
||||
setopt complete_aliases
|
||||
setopt extended_glob
|
||||
#setopt hist_ignore_all_dups
|
||||
setopt share_history
|
||||
setopt list_types
|
||||
setopt mark_dirs
|
||||
setopt path_dirs
|
||||
|
||||
#History settings
|
||||
if [ -z "$HISTFILE" ]; then
|
||||
HISTFILE=$HOME/.zsh_history
|
||||
fi
|
||||
|
||||
HISTSIZE=10000
|
||||
SAVEHIST=10000
|
||||
|
||||
# Show history
|
||||
case $HIST_STAMPS in
|
||||
"mm/dd/yyyy") alias history='fc -fl 1' ;;
|
||||
"dd.mm.yyyy") alias history='fc -El 1' ;;
|
||||
"yyyy-mm-dd") alias history='fc -il 1' ;;
|
||||
*) alias history='fc -l 1' ;;
|
||||
esac
|
||||
|
||||
setopt append_history
|
||||
setopt extended_history
|
||||
setopt hist_expire_dups_first
|
||||
setopt hist_ignore_dups # ignore duplication command history list
|
||||
setopt hist_ignore_space
|
||||
setopt hist_verify
|
||||
setopt inc_append_history
|
||||
setopt share_history # share command history data
|
||||
#alias/prefs
|
||||
export VISUAL="/usr/bin/vim"
|
||||
export EDITOR="$VISUAL"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue