From 88b6a66708d3c3ccb86a03e7ef4943f5917da3f0 Mon Sep 17 00:00:00 2001 From: pauljako <126326487+pauljako@users.noreply.github.com> Date: Sat, 24 Aug 2024 15:06:01 +0200 Subject: [PATCH] Added History sharing --- .zshrc | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.zshrc b/.zshrc index 66991f3..486263f 100644 --- a/.zshrc +++ b/.zshrc @@ -8,6 +8,10 @@ # OMP_THEME="basic" # +## The max size (in lines) of the .zsh_history file +## Default: 5000 +# +HISTSIZE=5000 # # Code: # @@ -108,5 +112,27 @@ alias la="ls -la" # Enable emacs keybindings bindkey -e # +# The file the History is written to +HISTFILE=~/.zsh_history +# +# The maximum History Size +SAVEHIST=$HISTSIZE +# +# Erease duplicates +HISTDUP=erase +# +# Share History between Sessions +setopt appendhistory +setopt sharehistory +# +# Ignore when Space is in front +setopt hist_ignore_space +# +# Ingore Duplicates +setopt hist_ignore_all_dups +setopt hist_save_no_dups +setopt hist_ignore_dups +setopt hist_find_no_dups +# # Load the zsh completion system autoload -U compinit && compinit