history.zsh 596 B

123456789101112131415161718192021222324
  1. ## Command history configuration
  2. if [ -z "$HISTFILE" ]; then
  3. HISTFILE=$HOME/.zsh_history
  4. fi
  5. HISTSIZE=10000
  6. SAVEHIST=10000
  7. # Show history
  8. case $HIST_STAMPS in
  9. "mm/dd/yyyy") alias history='fc -fl 1' ;;
  10. "dd.mm.yyyy") alias history='fc -El 1' ;;
  11. "yyyy-mm-dd") alias history='fc -il 1' ;;
  12. *) alias history='fc -l 1' ;;
  13. esac
  14. setopt append_history
  15. setopt extended_history
  16. setopt hist_expire_dups_first
  17. setopt hist_ignore_dups # ignore duplication command history list
  18. setopt hist_ignore_space
  19. setopt hist_verify
  20. setopt inc_append_history
  21. setopt share_history # share command history data