Created
July 14, 2020 21:21
-
-
Save noghartt/9a5755a7e858cac8b7eba726b4ec0b9f to your computer and use it in GitHub Desktop.
A mini script to fix .zsh_history corrupt file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env zsh | |
mv ~/.zsh_history ~/.zsh_history_bad | |
strings ~/.zsh_history_bad > ~/.zsh_history | |
fc -R ~/.zsh_history | |
rm ~/.zsh_history_bad |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment