Sometimes, when starting a new shell, you

zsh: corrupt history file /home/myusername/.zsh_history

Restore corrupted history file:

cd ~
mv .zsh_history .zsh_history_bad
strings .zsh_history_bad > .zsh_history

Then reload the history:

fc -r .zsh_history

References


This post on: Medium