多个终端开启了zsh时,zsh的history可能会被覆盖。具体原因没有深究
推荐的配置如下:
HISTFILE=/specify/a/fixed/and/different/location/.history
HISTSIZE=500000
SAVEHIST=500000
setopt appendhistory
setopt INC_APPEND_HISTORY
setopt SHARE_HISTORY
参考:
https://unix.stackexchange.com/questions/568907/why-do-i-lose-my-zsh-history