Skip to content

Instantly share code, notes, and snippets.

@voxpelli
Created August 13, 2021 13:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save voxpelli/dc1ebf058b69c98130f7a5367e7c1007 to your computer and use it in GitHub Desktop.
Save voxpelli/dc1ebf058b69c98130f7a5367e7c1007 to your computer and use it in GitHub Desktop.
My history setup in zsh
# **** History setup ****
setopt EXTENDED_HISTORY
# share history across multiple zsh sessions
setopt SHARE_HISTORY
# append to history
setopt APPEND_HISTORY
# adds commands as they are typed, not at shell exit
setopt INC_APPEND_HISTORY
# expire duplicates first
setopt HIST_EXPIRE_DUPS_FIRST
# do not store duplications
setopt HIST_IGNORE_DUPS
#ignore duplicates when searching
setopt HIST_FIND_NO_DUPS
# removes blank lines from history
setopt HIST_REDUCE_BLANKS
export HISTFILE=${ZDOTDIR:-$HOME}/.zsh_history
export SAVEHIST=5000
export HISTSIZE=2000
# **** End of history setup ****
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment