#
# History options
#

setopt extendedhistory      # add a timestamp and the duration of each command
setopt sharehistory         # _all_ zsh sessions share the same history files
setopt histignorealldups    # ignores duplications

HISTDIR="${ZSHDOTDIR}/history"
if [ ! -d "$HISTDIR" ]; then
    mkdir -p "$HISTDIR"
fi

HISTFILE="$HISTDIR/history"

HISTSIZE=1000000
SAVEHIST=1000000

export HISTFILE HISTSIZE SAVEHIST
unset HISTDIR
